修改一些警告;

main
“wangbo” 5 months ago
parent 6cea8fd4ce
commit b389ca4d6b

@ -76,7 +76,7 @@ int32_t stringToChar(QString str, char *buf, uint32_t len)
QByteArray ba = str.toLatin1(); QByteArray ba = str.toLatin1();
if (ba.length() <= 0 if (ba.length() <= 0
|| ba.length() >= len) || ba.length() >= static_cast<int>(len))
{ {
return -2; return -2;
} }

@ -33,8 +33,8 @@
* *
******************************************************************************/ ******************************************************************************/
#ifndef __COMMON_H_ #ifndef COMMON_H_
#define __COMMON_H_ #define COMMON_H_
/* Includes ------------------------------------------------------------------*/ /* Includes ------------------------------------------------------------------*/
#include <stdint.h> #include <stdint.h>

@ -17,7 +17,7 @@
</size> </size>
</property> </property>
<property name="windowTitle"> <property name="windowTitle">
<string>Form</string> <string>CableTool</string>
</property> </property>
<layout class="QVBoxLayout" name="verticalLayout"> <layout class="QVBoxLayout" name="verticalLayout">
<item> <item>
@ -413,7 +413,7 @@
</font> </font>
</property> </property>
<property name="currentIndex"> <property name="currentIndex">
<number>8</number> <number>0</number>
</property> </property>
<widget class="QWidget" name="infoTab"> <widget class="QWidget" name="infoTab">
<attribute name="title"> <attribute name="title">
@ -6046,6 +6046,9 @@
</layout> </layout>
</widget> </widget>
<widget class="QWidget" name="frequencyTab"> <widget class="QWidget" name="frequencyTab">
<property name="enabled">
<bool>true</bool>
</property>
<attribute name="title"> <attribute name="title">
<string>工频数据</string> <string>工频数据</string>
</attribute> </attribute>

@ -2443,6 +2443,7 @@ void Widget::closeEvent(QCloseEvent* ev)
worker->Stop();//终止工作函数 worker->Stop();//终止工作函数
m_thread->exit();//线程退出事件循环 m_thread->exit();//线程退出事件循环
m_thread->wait();//等待线程退出 m_thread->wait();//等待线程退出
QWidget::closeEvent(ev);
qDebug()<<"线程退出了"; qDebug()<<"线程退出了";
} }

Loading…
Cancel
Save