1 Star 0 Fork 0

qinxude/rk3568ui

加入 Gitee
与超过 1200万 开发者一起发现、参与优秀开源项目,私有仓库也完全免费 :)
免费加入
文件
该仓库未声明开源许可证文件(LICENSE),使用请关注具体项目描述及其代码上游依赖。
克隆/下载
dateclocksetting.h 1.79 KB
一键复制 编辑 原始数据 按行查看 历史
qinxude 提交于 2024-09-03 09:38 . 3568ui base
#ifndef DATECLOCKSETTING_H
#define DATECLOCKSETTING_H
#include <QWidget>
#include <QTimer>
#include <QRadioButton>
#include <QDebug>
#include "clock.h"
#include "datadictionary.h"
namespace Ui {
class DateClockSetting;
}
#include <QString>
#include <QVector>
#include <QObject>
#include <QDateTime>
#include <QtNetwork/QUdpSocket>
class webTimeGetter : public QObject
{
Q_OBJECT
public:
webTimeGetter();
virtual ~webTimeGetter();
public slots:
void readingData();
void connectSucess();
void tryGet();
private:
QVector<QString> hostList;
QUdpSocket* udpsocket;
QDateTime time;
};
class DateClockSetting : public QWidget
{
Q_OBJECT
public:
explicit DateClockSetting(QWidget *parent = nullptr);
~DateClockSetting();
typedef enum {
CAR_BUTTON_RED = 0,
CAR_BUTTON_WHITE,
CAR_BUTTON_GREEN,
}Color_t;
protected:
void showEvent(QShowEvent *event);
void hideEvent(QHideEvent *event);
private slots:
void ShowTime();
void on_Ok_clicked();
void on_Cancel_clicked();
void on_ModifyDate_clicked();
void on_NetWorkGetTime_clicked();
void on_BBGetTime_clicked();
void on_MenuSetTime_clicked();
void DevParamDataChange(DevParamDataIndex_t Index);
private:
void ShowCurrentDateTime();
void ShowCurrentClock();
void SetQRadioButtonStyleSheet(QRadioButton *button,Color_t C);
void SetQRadioButtonStyleSheet();
void ModifyDateTime();
void NoModifyDateTime();
void SelectButtonEnable(bool s);
void SelectButtonClicked(QRadioButton *b);
void SetClockTypeButton(uint32_t s);
private:
Ui::DateClockSetting *ui;
QTimer *m_Timer;
QTimer *m_WebTimer;
Clock *m_Clock;
bool m_ModifySta;
webTimeGetter *m_webTimeGetter;
};
#endif // DATECLOCKSETTING_H
Loading...
马建仓 AI 助手
尝试更多
代码解读
代码找茬
代码优化
C++
1
https://gitee.com/qinxude/rk3568ui.git
[email protected]:qinxude/rk3568ui.git
qinxude
rk3568ui
rk3568ui
master

搜索帮助