qt/LedOK/program/progeditorwin.h
2023-04-18 14:14:46 +08:00

35 lines
761 B
C++

#ifndef PROGEDITORWIN_H
#define PROGEDITORWIN_H
#include "basewin.h"
#include "program/pageeditor.h"
#include <QListWidget>
class ProgPanel;
class ProgItem;
class ProgEditorWin : public BaseWin {
Q_OBJECT
public:
explicit ProgEditorWin(ProgItem *progItem, QWidget *parent = nullptr);
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;
ProgItem *mProgItem;
int mNewEleX = 0;
int mNewEleY = 0;
};
#endif // PROGEDITORWIN_H