2022-08-25 18:37:24 +08:00
|
|
|
#ifndef PROGEDITORWIN_H
|
|
|
|
#define PROGEDITORWIN_H
|
|
|
|
#include "basewin.h"
|
|
|
|
#include "wProgramManager/pageeditor.h"
|
|
|
|
#include <QListWidget>
|
|
|
|
|
2022-10-27 15:07:45 +08:00
|
|
|
class ProgPanel;
|
|
|
|
class ProgItem;
|
2022-08-25 18:37:24 +08:00
|
|
|
class ProgEditorWin : public BaseWin {
|
|
|
|
Q_OBJECT
|
|
|
|
public:
|
2022-10-27 15:07:45 +08:00
|
|
|
explicit ProgEditorWin(ProgItem *progItem, QWidget *parent = nullptr);
|
2022-08-25 18:37:24 +08:00
|
|
|
|
|
|
|
public slots:
|
|
|
|
void onSave();
|
|
|
|
void onAddPage();
|
|
|
|
protected:
|
|
|
|
void closeEvent(QCloseEvent *event) override;
|
|
|
|
private:
|
|
|
|
bool isProgChanged();
|
|
|
|
void save();
|
|
|
|
void UdpSendJson(QJsonObject json);
|
|
|
|
|
|
|
|
QListWidget *listPage;
|
|
|
|
PageListItem *mPageItem = nullptr;
|
|
|
|
PageEditor *progEditorMid;
|
|
|
|
QTabWidget *mTabsAttr;
|
|
|
|
QList<QJsonObject> mPageJsons;
|
2022-10-27 15:07:45 +08:00
|
|
|
ProgItem *mProgItem;
|
2022-08-25 18:37:24 +08:00
|
|
|
int mNewEleX = 0;
|
|
|
|
int mNewEleY = 0;
|
|
|
|
};
|
|
|
|
|
|
|
|
#endif // PROGEDITORWIN_H
|