202 lines
5.9 KiB
C++
202 lines
5.9 KiB
C++
#ifndef SETTINGUI_H
|
||
#define SETTINGUI_H
|
||
|
||
#include <QWidget>
|
||
#include <QPushButton>
|
||
#include <QLabel>
|
||
#include <QStackedWidget>
|
||
#include <QString>
|
||
#include <QDialog>
|
||
#include <QLineEdit>
|
||
#include <QStack>
|
||
|
||
#include "UiTools.h"
|
||
#include "LineEditWithKeyboard.h"
|
||
#include "BackstageInterfaceForUi.h"
|
||
#include "UiConfig.h"
|
||
|
||
#include "settingUIProjectSet.h"
|
||
#include "settingUiInfo.h"
|
||
#include "settingUiDevMng.h"
|
||
#include "settingUiFaceMng.h"
|
||
#include "settingUiAccMng.h"
|
||
#include "settingUiRecoSet.h"
|
||
#include "settingUiSysMng.h"
|
||
#include "settingUiDevTest.h"
|
||
#include "settingUiFastCfg.h"
|
||
|
||
|
||
class settingUiTop : public MyWidgetWithMainStyleColor
|
||
{
|
||
Q_OBJECT
|
||
public:
|
||
explicit settingUiTop(QWidget *parent = nullptr);
|
||
~settingUiTop();
|
||
|
||
void update_Ip(const QString& str);
|
||
void setRightSideBtn(bool isShow, const QString btnName = "");
|
||
signals:
|
||
void signalReturnBtnClicked();
|
||
void signalRightSideBtnClicked();
|
||
|
||
public slots:
|
||
void slotShowPageMsg(const QString&);
|
||
|
||
private:
|
||
QLabel* m_label_ip;
|
||
QLabel* m_label_time;
|
||
QPushButton* m_btn_back;
|
||
QLabel* m_label_pageMsg;
|
||
QPushButton* m_btn_rightSide;
|
||
|
||
TimerUpdate* _timerUpdate;
|
||
};
|
||
|
||
class settingUi : public WidgetWithBackstageInterface
|
||
{
|
||
Q_OBJECT
|
||
|
||
public:
|
||
enum enPageIndex {
|
||
PAGE_PROJECT = 0,
|
||
|
||
PAGE_INFO,
|
||
PAGE_DEV_MNG,
|
||
PAGE_FACE_MNG,
|
||
PAGE_ACCESS_MNG,
|
||
PAGE_RECO,
|
||
PAGE_SYS_MNG,
|
||
PAGE_FAST_CFG_WIRE_NET,
|
||
PAGE_DEV_MNG_NETWORK,
|
||
|
||
PAGE_DEV_TEST, //hidden page
|
||
|
||
//subPage
|
||
PAGE_DEV_MNG_TIME,
|
||
PAGE_DEV_MNG_NET_WIRE,
|
||
PAGE_DEV_MNG_NET_WIFI,
|
||
PAGE_DEV_MNG_NET_WIFI_ACC_POINT,
|
||
PAGE_DEV_MNG_NET_4G,
|
||
PAGE_DEV_MNG_BT,
|
||
PAGE_DEV_MNG_BT_SPK,
|
||
PAGE_DEV_MNG_BT_SPK_ACC_POINT,
|
||
PAGE_DEV_MNG_BT_LOCK,
|
||
PAGE_DEV_MNG_BT_LOCK_ACC_POINT,
|
||
|
||
PAGE_FACE_MNG_FACE,
|
||
PAGE_FACE_MNG_ACCESS_RECORD,
|
||
PAGE_FACE_MNG_ADD_PERSON,
|
||
PAGE_FACE_MNG_MODIFY_PERSON,
|
||
PAGE_FACE_MNG_SNAP_FACE,
|
||
|
||
PAGE_FAST_CFG_PARK,
|
||
PAGE_FAST_CFG_QRCODE,
|
||
|
||
PAGE_MAX
|
||
};
|
||
|
||
public:
|
||
settingUi(QWidget *parent = nullptr);
|
||
~settingUi();
|
||
void reset();
|
||
void setBackstageUiinterface(BackstageInterfaceForUi* interface);
|
||
void update_IpBar();
|
||
QString operator [] (unsigned index) const;
|
||
//void showDevTestPage();
|
||
|
||
signals:
|
||
void signalShowRecoPage();
|
||
void signalShowPageMsg(const QString&);
|
||
void signalSetRecoUiForeheadWidgetVisable(const bool);
|
||
void signalChangeRecoUiMode(); //底下的页面开关二维码模式信号
|
||
void signalUpdateRecoUiIpDisplay(const bool); //增加识别界面ip显示开关,更新信号
|
||
|
||
public slots:
|
||
void slotShowPage(int, const QString title);
|
||
void slotReturnClicked();
|
||
void slotRightSideBtnClicked();//m_ctlBar 右侧按钮按下
|
||
void slotShowAddFacePage();
|
||
void slotRestoreFactory();
|
||
void slotShowShadowPage(bool show);
|
||
void slotShowDevTestPage();
|
||
void slotJumpPage(int pageIndex);
|
||
void slotExitSettingUi();
|
||
|
||
private:
|
||
const QVector<QString> SetPageName = {tr("操作"),
|
||
tr("信息查看"),
|
||
tr("设备管理"),
|
||
tr("人脸管理"),
|
||
tr("门禁管理"),
|
||
tr("识别设置"),
|
||
tr("系统管理"),
|
||
tr("快速配置"),
|
||
tr("网络设置"),
|
||
tr("设备检测"),
|
||
tr("时间设置"),
|
||
tr("有线网络"),
|
||
tr("无线网络"),
|
||
tr("无线网络接入"),
|
||
tr("4G网络"),
|
||
tr("蓝牙"),
|
||
tr("蓝牙音箱"),
|
||
tr("已配对蓝牙设置"),
|
||
tr("蓝牙门锁"),
|
||
tr("蓝牙门锁操作"),
|
||
tr("人脸库"),
|
||
tr("通行记录"),
|
||
tr("添加人员"),
|
||
tr("编辑人员"),
|
||
tr("拍照"),
|
||
tr("设备信息"),
|
||
tr("")};
|
||
|
||
QMap<int, QString> m_map_rightBtnName;
|
||
settingUiTop* m_ctlBar;
|
||
QStackedWidget* m_stack_setPage;
|
||
|
||
settingUIProjectSet* m_pProjectSetPage;
|
||
settingUiInfo* m_infoPage;
|
||
settingUiDevMng* m_devMngPage;
|
||
settingUiFaceMng* m_faceMngPage;
|
||
settingUiAccMng* m_accMngPage;
|
||
settingUiRecoSet* m_recoSetPage;
|
||
settingUiSysMng* m_sysMngPage;
|
||
settingUiFastCfgWireNet* m_fastCfgWireNet;
|
||
|
||
settingUiDevTest* m_devTestPage;
|
||
|
||
settingUiDevMngTime* m_devMngTimePage;
|
||
settingUiDevMngNetwork* m_devMngNetworkPage;
|
||
settingUiDevMngNetWire* m_devMngNetWirePage;
|
||
settingUiDevMngNetWifi* m_devMngNetWifiPage;
|
||
settingUiDevMngNetWifiAccPoint* m_devMngNetWifiAccPointPage;
|
||
settingUiDevMngNet4G* m_devMngNet4GPage;
|
||
settingUiDevMngBt* m_devMngBtPage;
|
||
settingUiDevMngBtSpk* m_devMngBtSpkPage;
|
||
settingUiDevMngBtSpkAccPoint* m_devMngBtSpkAccPointPage;
|
||
settingUiDevMngBtLock* m_devMngBtLockPage;
|
||
settingUiDevMngBtLockAccPoint* m_devMngBtLockAccPointPage;
|
||
|
||
FaceDbPage* m_faceMngFacePage;
|
||
AccessRecordPage* m_faceMngAccRedPage;
|
||
AddPersonPage *m_addPersonPage;
|
||
ModifyPersonPage *m_modifyPersonPage;
|
||
SnapFacePage *m_snapFacePage;
|
||
|
||
settingUiFastCfgPark* m_fastCfgPark;
|
||
SettingUiQrcode* m_fastCfgQrcode;
|
||
|
||
PureColorPage *m_shadowPage;
|
||
|
||
//是否在设置索引页面,是的话返回便退出设置页面
|
||
bool m_onIndexPage;
|
||
QStack<int> m_pageIndex;
|
||
bool m_syncFlag;
|
||
|
||
void showPage(int nIndex, const QString& title);
|
||
};
|
||
|
||
|
||
#endif // SETTINGUI_H
|