diff --git a/runner17/Enchanter.exe b/runner17/Enchanter.exe new file mode 100644 index 0000000..2416ac1 Binary files /dev/null and b/runner17/Enchanter.exe differ diff --git a/runner17/QUserInfo.dll b/runner17/QUserInfo.dll new file mode 100644 index 0000000..fa02146 Binary files /dev/null and b/runner17/QUserInfo.dll differ diff --git a/runner17/Reportd.exe b/runner17/Reportd.exe deleted file mode 100644 index dfcb965..0000000 Binary files a/runner17/Reportd.exe and /dev/null differ diff --git a/runner17/language/English/lpmain_en.qm b/runner17/language/English/lpmain_en.qm new file mode 100644 index 0000000..eaad2f5 Binary files /dev/null and b/runner17/language/English/lpmain_en.qm differ diff --git a/runner17/lpCoreCtrl.dll b/runner17/lpCoreCtrl.dll new file mode 100644 index 0000000..dc89c80 Binary files /dev/null and b/runner17/lpCoreCtrl.dll differ diff --git a/runner17/tpCam_100.dll b/runner17/tpCam_100.dll new file mode 100644 index 0000000..871a661 Binary files /dev/null and b/runner17/tpCam_100.dll differ diff --git a/runner17/tpCam_120.dll b/runner17/tpCam_120.dll new file mode 100644 index 0000000..811f96d Binary files /dev/null and b/runner17/tpCam_120.dll differ diff --git a/runner17/tpCam_120d.dll b/runner17/tpCam_120d.dll new file mode 100644 index 0000000..bbc7d30 Binary files /dev/null and b/runner17/tpCam_120d.dll differ diff --git a/runner17/tpCam_140.dll b/runner17/tpCam_140.dll new file mode 100644 index 0000000..1ce9256 Binary files /dev/null and b/runner17/tpCam_140.dll differ diff --git a/runner17/tpCam_140d.dll b/runner17/tpCam_140d.dll new file mode 100644 index 0000000..8ff97d5 Binary files /dev/null and b/runner17/tpCam_140d.dll differ diff --git a/runner17/tpCam_160.dll b/runner17/tpCam_160.dll new file mode 100644 index 0000000..92166fa Binary files /dev/null and b/runner17/tpCam_160.dll differ diff --git a/runner17/tpCam_160d.dll b/runner17/tpCam_160d.dll new file mode 100644 index 0000000..4ffb7cd Binary files /dev/null and b/runner17/tpCam_160d.dll differ diff --git a/tpvs17/tpAlgorithmQt/tpAlgorithmQt.vcxproj b/tpvs17/tpAlgorithmQt/tpAlgorithmQt.vcxproj index 462a12c..06f54f1 100644 --- a/tpvs17/tpAlgorithmQt/tpAlgorithmQt.vcxproj +++ b/tpvs17/tpAlgorithmQt/tpAlgorithmQt.vcxproj @@ -82,10 +82,10 @@ Windows - $(SolutionDir)..\runner13\$(TargetName)$(TargetExt) - $(QTDIR)\lib;..\..\..\lpOpenCV\openCV2.4.9\build\x86\vc12\lib;$(OutDir);%(AdditionalLibraryDirectories) + $(SolutionDir)..\runner17\$(TargetName)$(TargetExt) + $(QTDIR)\lib;$(OutDir);..\..\3part\opencv3.4.1\x64\vc15\lib;..\..\3part\Cyclops\lib;..\..\3part\edcircle\lib;%(AdditionalLibraryDirectories) true - qtmain.lib;Qt5Core.lib;Qt5Gui.lib;opencv_core249.lib;opencv_imgproc249.lib;opencv_highgui249.lib;opencv_features2d249.lib;Cyclops.lib;luffy.lib;opencv_calib3d249.lib;%(AdditionalDependencies) + qtmain.lib;Qt5Core.lib;Qt5Gui.lib;Cyclops.lib;luffy.lib;opencv_world341.lib;EDCircle.lib;%(AdditionalDependencies) true diff --git a/tpvs17/tpMain/QSystemSettingDlg.cpp b/tpvs17/tpMain/QSystemSettingDlg.cpp index 418e004..a3e97fe 100644 --- a/tpvs17/tpMain/QSystemSettingDlg.cpp +++ b/tpvs17/tpMain/QSystemSettingDlg.cpp @@ -940,6 +940,8 @@ Q_SLOT void QSystemSettingDlg::oncurrentChanged(const QString &str) { QString strObjName = sender()->objectName(); if ("m_Language" == strObjName) { + + emit sgChangeLanguage(str); //emit(sgGenalData("languageSeting", str)); } } diff --git a/tpvs17/tpMain/QSystemSettingDlg.h b/tpvs17/tpMain/QSystemSettingDlg.h index ba12496..10d1781 100644 --- a/tpvs17/tpMain/QSystemSettingDlg.h +++ b/tpvs17/tpMain/QSystemSettingDlg.h @@ -1,4 +1,4 @@ -#ifndef _H_QSYSTEMSETTINGUI_H_ +#ifndef _H_QSYSTEMSETTINGUI_H_ #define _H_QSYSTEMSETTINGUI_H_ #include @@ -17,6 +17,8 @@ public: ~QSystemSettingDlg(); void onShowWidget(int level); +signals: + void sgChangeLanguage(QString strLanguage); private: bool InitTreeWidget(QTreeWidget* pTreewidget); void addComRoot(class QTreeWidget *pTreewidget, QString strName /*= QString()*/); diff --git a/tpvs17/tpMain/QTimeMgrDlg.h b/tpvs17/tpMain/QTimeMgrDlg.h index 9437f4b..2f3c934 100644 --- a/tpvs17/tpMain/QTimeMgrDlg.h +++ b/tpvs17/tpMain/QTimeMgrDlg.h @@ -1,4 +1,4 @@ -#ifndef _H_QTIMEMGRDLG_H_ +#ifndef _H_QTIMEMGRDLG_H_ #define _H_QTIMEMGRDLG_H_ #include @@ -6,7 +6,7 @@ #include "InfoFile.h" #include "IWheelCtrl.h" class TimeMgrCtrl; -/*ιҳ*/ +/*班次管理窗口页面*/ class QTimeMgrDlg : public QDialog { Q_OBJECT diff --git a/tpvs17/tpMain/lpMainWin.cpp b/tpvs17/tpMain/lpMainWin.cpp index 8b03bf7..d46e34c 100644 --- a/tpvs17/tpMain/lpMainWin.cpp +++ b/tpvs17/tpMain/lpMainWin.cpp @@ -78,8 +78,8 @@ lpMainWin::lpMainWin(QWidget *parent) } {//加载语言设置 QSettings languageSetting("hubdetect.ini", QSettings::IniFormat); - QString strLangeage = languageSetting.value("language", "Chinese").toString(); - SetLanguage(strLangeage); + QString strLanguage = languageSetting.value("language", "Chinese").toString(); + SetLanguage(strLanguage); } { m_pLbCurrentTime = new QLabel(tr("系统时间")); @@ -138,6 +138,7 @@ lpMainWin::lpMainWin(QWidget *parent) m_pSystemSettingDlg = new QSystemSettingDlg();//系统设置 m_CamSettingDlg = new QCamSettingDlg(); m_CamSettingDlg->setCoreCtrlPtr(m_pCoreCtrl); + connect(m_pSystemSettingDlg, SIGNAL(sgChangeLanguage(QString)), this, SLOT(onLanguageChange(QString))); m_pixMapList = new QPixmapListBar(ui.tp_main_tabWidget); ui.tp_main_tabWidget->insertTab(0, m_pixMapList, tr("历史")); @@ -1240,6 +1241,13 @@ void lpMainWin::onInitAbout() //m_lightBox->setLayout(lbLayout); } +Q_SLOT void lpMainWin::onLanguageChange(QString strLanguage) +{ + QSettings languageSetting("hubdetect.ini", QSettings::IniFormat); + languageSetting.setValue("language", strLanguage); + SetLanguage(strLanguage); +} + void lpMainWin::onShowResult(Result2Ui* pRlt) { if (!pRlt) diff --git a/tpvs17/tpMain/lpMainWin.h b/tpvs17/tpMain/lpMainWin.h index 800812a..a3cdfda 100644 --- a/tpvs17/tpMain/lpMainWin.h +++ b/tpvs17/tpMain/lpMainWin.h @@ -1,4 +1,4 @@ -#ifndef _H_LPMAINWIN_H_ +#ifndef _H_LPMAINWIN_H_ #define _H_LPMAINWIN_H_ #include @@ -30,11 +30,11 @@ public: lpMainWin(QWidget *parent = Q_NULLPTR); ~lpMainWin(); - //ͼص + //接收图像回调函数 void INewCameraImage(const QString& camKey, QImage img); - //㷨ص + //接收算法检测结果回调函数 void IVariantMapToUI(const QString& camKey, const QVariantMap& vMap); - //㷨ص + //传输算法参数回调函数 QVariant IGetVariantById(int id); signals: void sgTaskSendModels(int nIndex, QString strModel, double dDiameter, double dHeight); @@ -69,9 +69,9 @@ private: protected: bool onInitCoreCtrl(); - void loadUserModel();//ûģ + void loadUserModel();//加载用户管理模块 - //ʻ + //国际化 void SearchQmFile(const QString & strDir); void SetTranslator(const QString strPath); void SetLanguage(QString strLangage); @@ -80,7 +80,7 @@ protected: void SendTickTskFun(); void onSetModel(); - Q_SLOT void onUpdateDefect();//ѡ ½ʾ + Q_SLOT void onUpdateDefect();//勾选 更新界面显示窗口 //net slot Q_SLOT void onTcpConnet(QString str, bool bConnect); Q_SLOT void onClientConnect(QString addr, bool bConnect); @@ -108,8 +108,10 @@ protected: Q_SLOT void onTriggerCam(); void onInitAbout(); + + Q_SLOT void onLanguageChange(QString strLanguage); private: - void onShowResult(Result2Ui* pRlt);//չʾʶ + void onShowResult(Result2Ui* pRlt);//展示识别结果 void SendResultBee(emTypeBee m_Type, int num); void SendResultStr2PLC(Result2Ui* m_Res); @@ -131,12 +133,12 @@ private: class QLabel* main_showWorkLabel{ nullptr }; class ModelsView *m_pTableCheck{ nullptr }; - RoiImgViewer *m_ImgViewer{ nullptr };//չʾͼ -/*status ״̬*/ - class QLabel* m_pLbCurrentTime{ nullptr };//ʾϵͳʱ - class QLabel* m_pLbBanci{ nullptr };//ʾ - class QLabel* m_pLbDetectState{ nullptr };//ʾ״̬ - class QLabel *m_pLbUser{ nullptr };//ʾ½ûϢ + RoiImgViewer *m_ImgViewer{ nullptr };//展示检测图像 +/*status 状态栏*/ + class QLabel* m_pLbCurrentTime{ nullptr };//显示系统时间 + class QLabel* m_pLbBanci{ nullptr };//显示班次 + class QLabel* m_pLbDetectState{ nullptr };//显示检测状态 + class QLabel *m_pLbUser{ nullptr };//显示登陆用户信息 private: CDllCoreCtrl* m_pDllCoreCtrl{ nullptr }; ICoreCtrl* m_pCoreCtrl{ nullptr }; @@ -158,27 +160,27 @@ private: QThread *pTickThread{ nullptr }; int m_nWfThress{ 0 }; - int m_TimerID{ 0 };//ʱ ڼ¼ʱ + int m_TimerID{ 0 };//心跳包定时器 用于记录超时 int m_TimerOutCount{ 0 }; int m_RestartServerCount{ 0 }; QStringList forDefectList; - int m_nDiffTrigNum{ 0 };// жǷ + int m_nDiffTrigNum{ 0 };//触发次数 用于判断相机是否正常打开 - //ģҳ + //模板管理页面 QModelMgrDlg *m_pModelMgrDlg{ nullptr }; QDebugDlg* m_pDebugDlg{ nullptr }; - QWidget m_aboutDlg;// + QWidget m_aboutDlg;//关于 QTimeMgrDlg* m_pTimerMgrDlg{ nullptr }; - QPixmapListBar* m_pixMapList{ nullptr };//չʾʷ + QPixmapListBar* m_pixMapList{ nullptr };//展示历史检测结果 QSystemSettingDlg* m_pSystemSettingDlg{ nullptr }; QCamSettingDlg* m_CamSettingDlg{ nullptr }; private: - IUserCtrl *m_pUserCtrl{ nullptr };//ûģ + IUserCtrl *m_pUserCtrl{ nullptr };//用户管理模块 - QVector m_VecTranPtr;//ʻ԰ + QVector m_VecTranPtr;//国际化语言包管理 - int m_timerID{ 0 };//ʱ ״̬Ϣ + int m_timerID{ 0 };//定时器 更新状态栏信息 }; #endif diff --git a/tpvs17/tpMain/tpMain.vcxproj b/tpvs17/tpMain/tpMain.vcxproj index 4b986d5..6cbff70 100644 --- a/tpvs17/tpMain/tpMain.vcxproj +++ b/tpvs17/tpMain/tpMain.vcxproj @@ -1358,7 +1358,7 @@ Console - $(SolutionDir)..\runner13\$(TargetName)$(TargetExt) + $(SolutionDir)..\runner17\$(TargetName)$(TargetExt) $(QTDIR)\lib;$(OutDir);..\..\3part\opencv3.4.1\x64\vc15\lib;..\..\3part\Cyclops\lib;..\..\3part\libzkq\lib;%(AdditionalLibraryDirectories) true qtmain.lib;Qt5Core.lib;Qt5Gui.lib;Qt5Widgets.lib;Qt5AxContainer.lib;Qt5AxBase.lib;Qt5Sql.lib;Qt5PrintSupport.lib;Qt5Network.lib;Qt5SerialPort.lib;libzkq.lib;luffy.lib;Cyclops.lib;opencv_world341.lib;%(AdditionalDependencies)