QetElementEditor : Use elementData class

This commit is contained in:
joshua
2021-02-13 21:38:36 +01:00
parent ffe3d98279
commit 8f85cacb06
15 changed files with 354 additions and 335 deletions

View File

@@ -19,6 +19,7 @@
#define ELEMENTPROPERTIESEDITORWIDGET_H
#include "../../diagramcontext.h"
#include "../../properties/elementdata.h"
#include <QAbstractButton>
#include <QDialog>
@@ -38,12 +39,13 @@ class ElementPropertiesEditorWidget : public QDialog
//METHODS
public:
explicit ElementPropertiesEditorWidget(QString &basic_type, DiagramContext &kind_info, DiagramContext &elmt_info, QWidget *parent = nullptr);
explicit ElementPropertiesEditorWidget(ElementData data, QWidget *parent = nullptr);
~ElementPropertiesEditorWidget() override;
void upDateInterface();
ElementData editedData() {return m_data;}
private:
void upDateInterface();
void setUpInterface();
void updateTree();
void populateTree();
@@ -56,9 +58,7 @@ class ElementPropertiesEditorWidget : public QDialog
//ATTRIBUTES
private:
Ui::ElementPropertiesEditorWidget *ui;
QString &m_basic_type;
DiagramContext &m_kind_info,
&m_elmt_info;
ElementData m_data;
};
#endif // ELEMENTPROPERTIESEDITORWIDGET_H