diff --git a/ip_sacaner/debug/ip_sacaner.exe b/ip_sacaner/debug/ip_sacaner.exe index 249dea7..5e35649 100644 Binary files a/ip_sacaner/debug/ip_sacaner.exe and b/ip_sacaner/debug/ip_sacaner.exe differ diff --git a/ip_sacaner/debug/ip_sacaner.ilk b/ip_sacaner/debug/ip_sacaner.ilk index f801d9f..25ecfbd 100644 Binary files a/ip_sacaner/debug/ip_sacaner.ilk and b/ip_sacaner/debug/ip_sacaner.ilk differ diff --git a/ip_sacaner/debug/ip_sacaner.log b/ip_sacaner/debug/ip_sacaner.log index 02bdf72..ae2cd71 100644 --- a/ip_sacaner/debug/ip_sacaner.log +++ b/ip_sacaner/debug/ip_sacaner.log @@ -1,51 +1,2 @@ - widget.cpp -C:\Users\wuwen\Desktop\tcp_ip_scan\ip_sacaner\widget.cpp(1,1): warning C4828: 文件包含在偏移 0x750 处开始的字符,该字符在当前源字符集中无效(代码页 65001)。 -C:\Users\wuwen\Desktop\tcp_ip_scan\ip_sacaner\widget.cpp(1,1): warning C4828: 文件包含在偏移 0x752 处开始的字符,该字符在当前源字符集中无效(代码页 65001)。 -C:\Users\wuwen\Desktop\tcp_ip_scan\ip_sacaner\widget.cpp(1,1): warning C4828: 文件包含在偏移 0x754 处开始的字符,该字符在当前源字符集中无效(代码页 65001)。 -C:\Users\wuwen\Desktop\tcp_ip_scan\ip_sacaner\widget.cpp(1,1): warning C4828: 文件包含在偏移 0x756 处开始的字符,该字符在当前源字符集中无效(代码页 65001)。 -C:\Users\wuwen\Desktop\tcp_ip_scan\ip_sacaner\widget.cpp(1,1): warning C4828: 文件包含在偏移 0x759 处开始的字符,该字符在当前源字符集中无效(代码页 65001)。 -C:\Users\wuwen\Desktop\tcp_ip_scan\ip_sacaner\widget.cpp(1,1): warning C4828: 文件包含在偏移 0x7a9 处开始的字符,该字符在当前源字符集中无效(代码页 65001)。 -C:\Users\wuwen\Desktop\tcp_ip_scan\ip_sacaner\widget.cpp(1,1): warning C4828: 文件包含在偏移 0x7ab 处开始的字符,该字符在当前源字符集中无效(代码页 65001)。 -C:\Users\wuwen\Desktop\tcp_ip_scan\ip_sacaner\widget.cpp(1,1): warning C4828: 文件包含在偏移 0x7ad 处开始的字符,该字符在当前源字符集中无效(代码页 65001)。 -C:\Users\wuwen\Desktop\tcp_ip_scan\ip_sacaner\widget.cpp(1,1): warning C4828: 文件包含在偏移 0x7b2 处开始的字符,该字符在当前源字符集中无效(代码页 65001)。 -C:\Users\wuwen\Desktop\tcp_ip_scan\ip_sacaner\widget.cpp(1,1): warning C4828: 文件包含在偏移 0x907 处开始的字符,该字符在当前源字符集中无效(代码页 65001)。 -C:\Users\wuwen\Desktop\tcp_ip_scan\ip_sacaner\widget.cpp(1,1): warning C4828: 文件包含在偏移 0x908 处开始的字符,该字符在当前源字符集中无效(代码页 65001)。 -C:\Users\wuwen\Desktop\tcp_ip_scan\ip_sacaner\widget.cpp(1,1): warning C4828: 文件包含在偏移 0x90a 处开始的字符,该字符在当前源字符集中无效(代码页 65001)。 -C:\Users\wuwen\Desktop\tcp_ip_scan\ip_sacaner\widget.cpp(1,1): warning C4828: 文件包含在偏移 0x9a0 处开始的字符,该字符在当前源字符集中无效(代码页 65001)。 -C:\Users\wuwen\Desktop\tcp_ip_scan\ip_sacaner\widget.cpp(1,1): warning C4828: 文件包含在偏移 0x9a1 处开始的字符,该字符在当前源字符集中无效(代码页 65001)。 -C:\Users\wuwen\Desktop\tcp_ip_scan\ip_sacaner\widget.cpp(1,1): warning C4828: 文件包含在偏移 0x9a5 处开始的字符,该字符在当前源字符集中无效(代码页 65001)。 -C:\Users\wuwen\Desktop\tcp_ip_scan\ip_sacaner\widget.cpp(1,1): warning C4828: 文件包含在偏移 0x9a6 处开始的字符,该字符在当前源字符集中无效(代码页 65001)。 -C:\Users\wuwen\Desktop\tcp_ip_scan\ip_sacaner\widget.cpp(1,1): warning C4828: 文件包含在偏移 0x9a7 处开始的字符,该字符在当前源字符集中无效(代码页 65001)。 -C:\Users\wuwen\Desktop\tcp_ip_scan\ip_sacaner\widget.cpp(1,1): warning C4828: 文件包含在偏移 0xa36 处开始的字符,该字符在当前源字符集中无效(代码页 65001)。 -C:\Users\wuwen\Desktop\tcp_ip_scan\ip_sacaner\widget.cpp(1,1): warning C4828: 文件包含在偏移 0xa37 处开始的字符,该字符在当前源字符集中无效(代码页 65001)。 -C:\Users\wuwen\Desktop\tcp_ip_scan\ip_sacaner\widget.cpp(1,1): warning C4828: 文件包含在偏移 0xa39 处开始的字符,该字符在当前源字符集中无效(代码页 65001)。 -C:\Users\wuwen\Desktop\tcp_ip_scan\ip_sacaner\widget.cpp(1,1): warning C4828: 文件包含在偏移 0xa3c 处开始的字符,该字符在当前源字符集中无效(代码页 65001)。 -C:\Users\wuwen\Desktop\tcp_ip_scan\ip_sacaner\widget.cpp(1,1): warning C4828: 文件包含在偏移 0xa3d 处开始的字符,该字符在当前源字符集中无效(代码页 65001)。 -C:\Users\wuwen\Desktop\tcp_ip_scan\ip_sacaner\widget.cpp(1,1): warning C4828: 文件包含在偏移 0xaff 处开始的字符,该字符在当前源字符集中无效(代码页 65001)。 -C:\Users\wuwen\Desktop\tcp_ip_scan\ip_sacaner\widget.cpp(1,1): warning C4828: 文件包含在偏移 0xb04 处开始的字符,该字符在当前源字符集中无效(代码页 65001)。 -C:\Users\wuwen\Desktop\tcp_ip_scan\ip_sacaner\widget.cpp(1,1): warning C4828: 文件包含在偏移 0xb06 处开始的字符,该字符在当前源字符集中无效(代码页 65001)。 -C:\Users\wuwen\Desktop\tcp_ip_scan\ip_sacaner\widget.cpp(1,1): warning C4828: 文件包含在偏移 0xc84 处开始的字符,该字符在当前源字符集中无效(代码页 65001)。 -C:\Users\wuwen\Desktop\tcp_ip_scan\ip_sacaner\widget.cpp(1,1): warning C4828: 文件包含在偏移 0xc85 处开始的字符,该字符在当前源字符集中无效(代码页 65001)。 -C:\Users\wuwen\Desktop\tcp_ip_scan\ip_sacaner\widget.cpp(1,1): warning C4828: 文件包含在偏移 0xc86 处开始的字符,该字符在当前源字符集中无效(代码页 65001)。 -C:\Users\wuwen\Desktop\tcp_ip_scan\ip_sacaner\widget.cpp(1,1): warning C4828: 文件包含在偏移 0xc89 处开始的字符,该字符在当前源字符集中无效(代码页 65001)。 -C:\Users\wuwen\Desktop\tcp_ip_scan\ip_sacaner\widget.cpp(1,1): warning C4828: 文件包含在偏移 0xc8b 处开始的字符,该字符在当前源字符集中无效(代码页 65001)。 -C:\Users\wuwen\Desktop\tcp_ip_scan\ip_sacaner\widget.cpp(1,1): warning C4828: 文件包含在偏移 0xd58 处开始的字符,该字符在当前源字符集中无效(代码页 65001)。 -C:\Users\wuwen\Desktop\tcp_ip_scan\ip_sacaner\widget.cpp(1,1): warning C4828: 文件包含在偏移 0xd59 处开始的字符,该字符在当前源字符集中无效(代码页 65001)。 -C:\Users\wuwen\Desktop\tcp_ip_scan\ip_sacaner\widget.cpp(1,1): warning C4828: 文件包含在偏移 0xd5c 处开始的字符,该字符在当前源字符集中无效(代码页 65001)。 -C:\Users\wuwen\Desktop\tcp_ip_scan\ip_sacaner\widget.cpp(1,1): warning C4828: 文件包含在偏移 0xd5d 处开始的字符,该字符在当前源字符集中无效(代码页 65001)。 -C:\Users\wuwen\Desktop\tcp_ip_scan\ip_sacaner\widget.cpp(1,1): warning C4828: 文件包含在偏移 0xd61 处开始的字符,该字符在当前源字符集中无效(代码页 65001)。 -C:\Users\wuwen\Desktop\tcp_ip_scan\ip_sacaner\widget.cpp(1,1): warning C4828: 文件包含在偏移 0xdab 处开始的字符,该字符在当前源字符集中无效(代码页 65001)。 -C:\Users\wuwen\Desktop\tcp_ip_scan\ip_sacaner\widget.cpp(1,1): warning C4828: 文件包含在偏移 0xdac 处开始的字符,该字符在当前源字符集中无效(代码页 65001)。 -C:\Users\wuwen\Desktop\tcp_ip_scan\ip_sacaner\widget.cpp(1,1): warning C4828: 文件包含在偏移 0xdae 处开始的字符,该字符在当前源字符集中无效(代码页 65001)。 -C:\Users\wuwen\Desktop\tcp_ip_scan\ip_sacaner\widget.cpp(1,1): warning C4828: 文件包含在偏移 0xdb1 处开始的字符,该字符在当前源字符集中无效(代码页 65001)。 -C:\Users\wuwen\Desktop\tcp_ip_scan\ip_sacaner\widget.cpp(1,1): warning C4828: 文件包含在偏移 0xdb2 处开始的字符,该字符在当前源字符集中无效(代码页 65001)。 -C:\Users\wuwen\Desktop\tcp_ip_scan\ip_sacaner\widget.cpp(1,1): warning C4828: 文件包含在偏移 0xe60 处开始的字符,该字符在当前源字符集中无效(代码页 65001)。 -C:\Users\wuwen\Desktop\tcp_ip_scan\ip_sacaner\widget.cpp(1,1): warning C4828: 文件包含在偏移 0xe65 处开始的字符,该字符在当前源字符集中无效(代码页 65001)。 -C:\Users\wuwen\Desktop\tcp_ip_scan\ip_sacaner\widget.cpp(1,1): warning C4828: 文件包含在偏移 0xe67 处开始的字符,该字符在当前源字符集中无效(代码页 65001)。 -C:\Users\wuwen\Desktop\tcp_ip_scan\ip_sacaner\widget.cpp(1,1): warning C4828: 文件包含在偏移 0xfc4 处开始的字符,该字符在当前源字符集中无效(代码页 65001)。 -C:\Users\wuwen\Desktop\tcp_ip_scan\ip_sacaner\widget.cpp(1,1): warning C4828: 文件包含在偏移 0xfc5 处开始的字符,该字符在当前源字符集中无效(代码页 65001)。 -C:\Users\wuwen\Desktop\tcp_ip_scan\ip_sacaner\widget.cpp(1,1): warning C4828: 文件包含在偏移 0xfc6 处开始的字符,该字符在当前源字符集中无效(代码页 65001)。 -C:\Users\wuwen\Desktop\tcp_ip_scan\ip_sacaner\widget.cpp(1,1): warning C4828: 文件包含在偏移 0xfc9 处开始的字符,该字符在当前源字符集中无效(代码页 65001)。 -C:\Users\wuwen\Desktop\tcp_ip_scan\ip_sacaner\widget.cpp(1,1): warning C4828: 文件包含在偏移 0xfcb 处开始的字符,该字符在当前源字符集中无效(代码页 65001)。 -C:\Users\wuwen\Desktop\tcp_ip_scan\ip_sacaner\widget.cpp(72,17): warning C4189: “m_socket”: 局部变量已初始化但不引用 + scan_run.cpp ip_sacaner.vcxproj -> C:\Users\wuwen\Desktop\tcp_ip_scan\ip_sacaner\debug\ip_sacaner.exe diff --git a/ip_sacaner/debug/ip_sacaner.pdb b/ip_sacaner/debug/ip_sacaner.pdb index feb54ff..318f755 100644 Binary files a/ip_sacaner/debug/ip_sacaner.pdb and b/ip_sacaner/debug/ip_sacaner.pdb differ diff --git a/ip_sacaner/debug/ip_sacaner.tlog/CL.command.1.tlog b/ip_sacaner/debug/ip_sacaner.tlog/CL.command.1.tlog index 9f639cd..7eabd25 100644 Binary files a/ip_sacaner/debug/ip_sacaner.tlog/CL.command.1.tlog and b/ip_sacaner/debug/ip_sacaner.tlog/CL.command.1.tlog differ diff --git a/ip_sacaner/debug/ip_sacaner.tlog/CL.read.1.tlog b/ip_sacaner/debug/ip_sacaner.tlog/CL.read.1.tlog index 266f152..e08de86 100644 Binary files a/ip_sacaner/debug/ip_sacaner.tlog/CL.read.1.tlog and b/ip_sacaner/debug/ip_sacaner.tlog/CL.read.1.tlog differ diff --git a/ip_sacaner/debug/ip_sacaner.tlog/CL.write.1.tlog b/ip_sacaner/debug/ip_sacaner.tlog/CL.write.1.tlog index 07a0c52..7861791 100644 Binary files a/ip_sacaner/debug/ip_sacaner.tlog/CL.write.1.tlog and b/ip_sacaner/debug/ip_sacaner.tlog/CL.write.1.tlog differ diff --git a/ip_sacaner/debug/ip_sacaner.tlog/ip_sacaner.write.1u.tlog b/ip_sacaner/debug/ip_sacaner.tlog/ip_sacaner.write.1u.tlog index edf44c6..8911fb5 100644 Binary files a/ip_sacaner/debug/ip_sacaner.tlog/ip_sacaner.write.1u.tlog and b/ip_sacaner/debug/ip_sacaner.tlog/ip_sacaner.write.1u.tlog differ diff --git a/ip_sacaner/debug/ip_sacaner.tlog/link.command.1.tlog b/ip_sacaner/debug/ip_sacaner.tlog/link.command.1.tlog index b7ec6b3..f8746ba 100644 Binary files a/ip_sacaner/debug/ip_sacaner.tlog/link.command.1.tlog and b/ip_sacaner/debug/ip_sacaner.tlog/link.command.1.tlog differ diff --git a/ip_sacaner/debug/ip_sacaner.tlog/link.read.1.tlog b/ip_sacaner/debug/ip_sacaner.tlog/link.read.1.tlog index 5c952ad..480779b 100644 Binary files a/ip_sacaner/debug/ip_sacaner.tlog/link.read.1.tlog and b/ip_sacaner/debug/ip_sacaner.tlog/link.read.1.tlog differ diff --git a/ip_sacaner/debug/ip_sacaner.tlog/link.write.1.tlog b/ip_sacaner/debug/ip_sacaner.tlog/link.write.1.tlog index 4e1aa65..75b1d0b 100644 Binary files a/ip_sacaner/debug/ip_sacaner.tlog/link.write.1.tlog and b/ip_sacaner/debug/ip_sacaner.tlog/link.write.1.tlog differ diff --git a/ip_sacaner/debug/main.obj b/ip_sacaner/debug/main.obj index 24ea750..bdcbbfa 100644 Binary files a/ip_sacaner/debug/main.obj and b/ip_sacaner/debug/main.obj differ diff --git a/ip_sacaner/debug/moc_widget.obj b/ip_sacaner/debug/moc_widget.obj index ecc4d3d..4594bd5 100644 Binary files a/ip_sacaner/debug/moc_widget.obj and b/ip_sacaner/debug/moc_widget.obj differ diff --git a/ip_sacaner/debug/qmake/temp/E4D3F595-9CE6-39DE-ADBA-848B14D35E3F.ip_sacaner.designtime.idx b/ip_sacaner/debug/qmake/temp/E4D3F595-9CE6-39DE-ADBA-848B14D35E3F.ip_sacaner.designtime.idx deleted file mode 100644 index 10254da..0000000 --- a/ip_sacaner/debug/qmake/temp/E4D3F595-9CE6-39DE-ADBA-848B14D35E3F.ip_sacaner.designtime.idx +++ /dev/null @@ -1 +0,0 @@ -C:\Users\wuwen\AppData\Local\Temp\5cpt1zud.gx4.designtime.props diff --git a/ip_sacaner/debug/qt_work.log b/ip_sacaner/debug/qt_work.log index 374e2fe..22f6290 100644 Binary files a/ip_sacaner/debug/qt_work.log and b/ip_sacaner/debug/qt_work.log differ diff --git a/ip_sacaner/debug/scan_run.obj b/ip_sacaner/debug/scan_run.obj new file mode 100644 index 0000000..25e5b16 Binary files /dev/null and b/ip_sacaner/debug/scan_run.obj differ diff --git a/ip_sacaner/debug/vc143.pdb b/ip_sacaner/debug/vc143.pdb index ee6bede..f93a960 100644 Binary files a/ip_sacaner/debug/vc143.pdb and b/ip_sacaner/debug/vc143.pdb differ diff --git a/ip_sacaner/debug/widget.obj b/ip_sacaner/debug/widget.obj index fa88cdf..24043da 100644 Binary files a/ip_sacaner/debug/widget.obj and b/ip_sacaner/debug/widget.obj differ diff --git a/ip_sacaner/ip_sacaner.pro b/ip_sacaner/ip_sacaner.pro index f035037..1f9b062 100644 --- a/ip_sacaner/ip_sacaner.pro +++ b/ip_sacaner/ip_sacaner.pro @@ -10,9 +10,11 @@ CONFIG += c++11 SOURCES += \ main.cpp \ + scan_run.cpp \ widget.cpp HEADERS += \ + scan_run.h \ widget.h FORMS += \ diff --git a/ip_sacaner/ip_sacaner.pro.user b/ip_sacaner/ip_sacaner.pro.user index 0105546..3228039 100644 --- a/ip_sacaner/ip_sacaner.pro.user +++ b/ip_sacaner/ip_sacaner.pro.user @@ -1,6 +1,6 @@ - + EnvironmentId diff --git a/ip_sacaner/ip_sacaner.vcxproj b/ip_sacaner/ip_sacaner.vcxproj index a504b59..7f5d184 100644 --- a/ip_sacaner/ip_sacaner.vcxproj +++ b/ip_sacaner/ip_sacaner.vcxproj @@ -16,7 +16,8 @@ QtVS_v304 10.0.19041.0 10.0.19041.0 - $(MSBuildProjectDirectory)\QtMsBuild + $(MSBuildProjectDirectory)\QtMsBuild + v143 @@ -36,7 +37,10 @@ debug\ ip_sacaner - + + + + @@ -44,8 +48,34 @@ - debug\debug\ip_sacanertruerelease\release\ip_sacanertruefalse6.2.2_msvc2019_64core;network;gui;widgets6.2.2_msvc2019_64core;network;gui;widgets - + + + + + + debug\ + debug\ + ip_sacaner + true + + + release\ + release\ + ip_sacaner + true + false + + + 6.2.2_msvc2019_64 + core;network;gui;widgets + + + 6.2.2_msvc2019_64 + core;network;gui;widgets + + + + .;release;/include;%(AdditionalIncludeDirectories) @@ -60,12 +90,14 @@ MaxSpeed _WINDOWS;UNICODE;_UNICODE;WIN32;_ENABLE_EXTENDED_ALIGNED_STORAGE;WIN64;NDEBUG;QT_NO_DEBUG;%(PreprocessorDefinitions) false - + + MultiThreadedDLL true true Level3 - true + true + $(QTDIR)\lib\Qt6Widgets.lib;$(QTDIR)\lib\Qt6Gui.lib;$(QTDIR)\lib\Qt6Network.lib;$(QTDIR)\lib\Qt6Core.lib;$(QTDIR)\lib\Qt6EntryPoint.lib;shell32.lib;%(AdditionalDependencies) %(AdditionalLibraryDirectories) @@ -89,7 +121,20 @@ _WINDOWS;UNICODE;_UNICODE;WIN32;_ENABLE_EXTENDED_ALIGNED_STORAGE;WIN64;NDEBUG;QT_NO_DEBUG;QT_WIDGETS_LIB;QT_GUI_LIB;QT_NETWORK_LIB;QT_CORE_LIB;%(PreprocessorDefinitions) - msvc./$(Configuration)/moc_predefs.hMoc'ing %(Identity)...output$(Configuration)moc_%(Filename).cppUic'ing %(Identity)...$(ProjectDir)ui_%(Filename).h + + msvc + ./$(Configuration)/moc_predefs.h + Moc'ing %(Identity)... + output + $(Configuration) + moc_%(Filename).cpp + + + Uic'ing %(Identity)... + $(ProjectDir) + ui_%(Filename).h + + .;debug;/include;%(AdditionalIncludeDirectories) @@ -108,7 +153,8 @@ true true Level3 - true + true + $(QTDIR)\lib\Qt6Widgetsd.lib;$(QTDIR)\lib\Qt6Guid.lib;$(QTDIR)\lib\Qt6Networkd.lib;$(QTDIR)\lib\Qt6Cored.lib;$(QTDIR)\lib\Qt6EntryPointd.lib;shell32.lib;%(AdditionalDependencies) %(AdditionalLibraryDirectories) @@ -129,21 +175,27 @@ _WINDOWS;UNICODE;_UNICODE;WIN32;_ENABLE_EXTENDED_ALIGNED_STORAGE;WIN64;QT_WIDGETS_LIB;QT_GUI_LIB;QT_NETWORK_LIB;QT_CORE_LIB;_DEBUG;%(PreprocessorDefinitions) - msvc./$(Configuration)/moc_predefs.hMoc'ing %(Identity)...output$(Configuration)moc_%(Filename).cppUic'ing %(Identity)...$(ProjectDir)ui_%(Filename).h + + msvc + ./$(Configuration)/moc_predefs.h + Moc'ing %(Identity)... + output + $(Configuration) + moc_%(Filename).cpp + + + Uic'ing %(Identity)... + $(ProjectDir) + ui_%(Filename).h + + + - - - - - - - - @@ -163,23 +215,17 @@ release\moc_predefs.h;%(Outputs) true - - - - - - - - - - - - - + + + + + + + \ No newline at end of file diff --git a/ip_sacaner/ip_sacaner.vcxproj.filters b/ip_sacaner/ip_sacaner.vcxproj.filters index 7708ba5..cfc0597 100644 --- a/ip_sacaner/ip_sacaner.vcxproj.filters +++ b/ip_sacaner/ip_sacaner.vcxproj.filters @@ -43,6 +43,9 @@ Source Files + + Source Files + @@ -56,13 +59,15 @@ Generated Files - - - Form Files + + + Header Files + + \ No newline at end of file diff --git a/ip_sacaner/scan_run.cpp b/ip_sacaner/scan_run.cpp new file mode 100644 index 0000000..ac5ec43 --- /dev/null +++ b/ip_sacaner/scan_run.cpp @@ -0,0 +1,13 @@ +#include "scan_run.h" +#include "widget.h" +#include "ui_widget.h" +#include + + + +void scan_run::run() +{ + //Widget::tray_scan(); + //ui->outputlist->append("1"); + //Widget::test(); +} diff --git a/ip_sacaner/scan_run.h b/ip_sacaner/scan_run.h new file mode 100644 index 0000000..c9f0378 --- /dev/null +++ b/ip_sacaner/scan_run.h @@ -0,0 +1,15 @@ +#ifndef SCAN_RUN_H +#define SCAN_RUN_H + +#include + + +class scan_run : public QThread +{ +public: + +protected: + void run(); +}; + +#endif // SCAN_RUN_H diff --git a/ip_sacaner/widget.cpp b/ip_sacaner/widget.cpp index d1edcc0..2aa8833 100644 --- a/ip_sacaner/widget.cpp +++ b/ip_sacaner/widget.cpp @@ -2,6 +2,8 @@ #include "ui_widget.h" #include #include //socket +#include "scan_run.h" + void Widget::tcp_connected() { @@ -143,7 +145,11 @@ void Widget::auto_edit() //qDebug("%d",rand()); } - +void Widget::test() +{ + qDebug() << "Test"; + Widget::tray_scan(); +} Widget::Widget(QWidget *parent) : QWidget(parent) @@ -152,8 +158,9 @@ Widget::Widget(QWidget *parent) ui->setupUi(this); //qDebug("hello world"); + scan_run *scan_thread=new scan_run; - connect(ui->stard_scan,&QPushButton::pressed,this, &Widget::tray_scan);//'scan button pass' + connect(ui->stard_scan, &QPushButton::pressed, [=]() {scan_thread->start(); });//'scan button pass' connect(ui->IP_list,&QTextEdit::textChanged,this, &Widget::auto_edit); diff --git a/ip_sacaner/widget.h b/ip_sacaner/widget.h index 21935bc..8fcba72 100644 --- a/ip_sacaner/widget.h +++ b/ip_sacaner/widget.h @@ -16,9 +16,12 @@ public: ~Widget(); void tray_scan(); + void ip_scan(const QString& ipstr, quint32 ipint); void auto_edit(); void tcp_connected(); - void ip_scan(const QString& ipstr, quint32 ipint); + + void test(); + private: Ui::Widget *ui;