#ifndef MPROGRAMMANAGER_H #define MPROGRAMMANAGER_H #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include "loappconfig.h" #include #include #include #include #include "wProgramManager/wprogramitem.h" namespace Ui { class mProgramManager; } class mProgramManager : public QWidget { Q_OBJECT public: explicit mProgramManager(QWidget *parent = nullptr); ~mProgramManager(); public: virtual void paintEvent(QPaintEvent *); void refreshLable(); QTreeWidgetItem *m_headerItem=nullptr; protected: bool checkIfNameRepeated(const QString &name, QTreeWidgetItem *skip = nullptr); protected slots: void onCheckStateChanged(int f); void onNewClicked(bool f); void onEditClicked(bool f); void onDeleteClicked(bool f); void onImportClicked(bool f); void onExportClicked(bool f); void onRestoreProgram(const QJsonDocument &pro); void onCreateNewProgram(QString name, QSize res, QString remarks); void onCreateNewProgramOnOpenEditProgramWidget(QString name, QSize res, QString remarks); void onEditHead(const QString &name, QSize res, const QString &remarks); // void onDeleteProgram(QString strImportDir,QString strTip1); void onImportProgram(QString strImportDir,QString strTip1); void onExportProgram(QString strImportDir,QString strTip1); void FilterProgram(const QString &strtemp); signals: void sigCheckAll(bool); private slots: void OnClickColumn(int iColumn); private: Ui::mProgramManager *ui; QString m_strProgramItemPath; QList m_pwPorgramItemList; void readSettings(); void writeSettings(); }; #endif // MPROGRAMMANAGER_H