diff --git a/sources/editor/arceditor.cpp b/sources/editor/arceditor.cpp index 113b43c9c..374d12669 100644 --- a/sources/editor/arceditor.cpp +++ b/sources/editor/arceditor.cpp @@ -210,7 +210,7 @@ void ArcEditor::updateArcA() @brief ArcEditor::updateForm Update the value of the widgets */ -void ArcEditor::updateForm() +void ArcEditor::updateFormPriv() { if (!m_part) return; activeConnections(false); diff --git a/sources/editor/arceditor.h b/sources/editor/arceditor.h index 91ac204bc..b37a71dc0 100644 --- a/sources/editor/arceditor.h +++ b/sources/editor/arceditor.h @@ -59,7 +59,7 @@ class ArcEditor : public ElementItemEditor public slots: void updateArcS(); void updateArcA(); - void updateForm() override; + void updateFormPriv() override; void updateRect(); private: diff --git a/sources/editor/elementitemeditor.cpp b/sources/editor/elementitemeditor.cpp index 540e57f7a..288d2152f 100644 --- a/sources/editor/elementitemeditor.cpp +++ b/sources/editor/elementitemeditor.cpp @@ -42,6 +42,11 @@ ElementScene *ElementItemEditor::elementScene() const return(element_editor -> elementScene()); } +void ElementItemEditor::updateForm() +{ + updateFormPriv(); +} + /// @return la QUndoStack a utiliser pour les annulations QUndoStack &ElementItemEditor::undoStack() const { diff --git a/sources/editor/elementitemeditor.h b/sources/editor/elementitemeditor.h index aa6deca86..9ddda01ec 100644 --- a/sources/editor/elementitemeditor.h +++ b/sources/editor/elementitemeditor.h @@ -55,7 +55,13 @@ class ElementItemEditor : public QWidget virtual CustomElementPart *currentPart() const = 0; virtual QList currentParts() const = 0; - virtual void updateForm() = 0; + /*! + * \brief updateForm + * update the values of the widget + */ + virtual void updateForm(); + private: + virtual void updateFormPriv() = 0; // attributes private: diff --git a/sources/editor/styleeditor.cpp b/sources/editor/styleeditor.cpp index d9791810d..fbea26dab 100644 --- a/sources/editor/styleeditor.cpp +++ b/sources/editor/styleeditor.cpp @@ -440,10 +440,10 @@ void StyleEditor::updatePartFilling() } /** - @brief StyleEditor::updateForm + @brief StyleEditor::updateFormPriv Update the edition form according to the value of edited part(s) */ -void StyleEditor::updateForm() +void StyleEditor::updateFormPriv() { if (!part && m_part_list.isEmpty()) return; activeConnections(false); diff --git a/sources/editor/styleeditor.h b/sources/editor/styleeditor.h index 20a63fb3b..775a3ed16 100644 --- a/sources/editor/styleeditor.h +++ b/sources/editor/styleeditor.h @@ -60,7 +60,7 @@ class StyleEditor : public ElementItemEditor static bool isStyleEditable (QList cep_list); public slots: - void updateForm() override; + void updateFormPriv() override; void updatePartAntialiasing(); void updatePartColor(); void updatePartLineStyle(); diff --git a/sources/editor/ui/dynamictextfieldeditor.cpp b/sources/editor/ui/dynamictextfieldeditor.cpp index e9135d52e..5624514b6 100644 --- a/sources/editor/ui/dynamictextfieldeditor.cpp +++ b/sources/editor/ui/dynamictextfieldeditor.cpp @@ -130,7 +130,7 @@ QList DynamicTextFieldEditor::currentParts() const return parts; } -void DynamicTextFieldEditor::updateForm() +void DynamicTextFieldEditor::updateFormPriv() { if(m_text_field) { ui -> m_x_sb -> setValue(m_text_field.data() -> x()); diff --git a/sources/editor/ui/dynamictextfieldeditor.h b/sources/editor/ui/dynamictextfieldeditor.h index e84c20228..1c83d20b4 100644 --- a/sources/editor/ui/dynamictextfieldeditor.h +++ b/sources/editor/ui/dynamictextfieldeditor.h @@ -45,7 +45,7 @@ class DynamicTextFieldEditor : public ElementItemEditor { bool setParts(QList ) override; CustomElementPart *currentPart() const override; QList currentParts() const override; - void updateForm() override; + void updateFormPriv() override; private: void setupWidget(); diff --git a/sources/editor/ui/ellipseeditor.cpp b/sources/editor/ui/ellipseeditor.cpp index d0b7b7511..57322571e 100644 --- a/sources/editor/ui/ellipseeditor.cpp +++ b/sources/editor/ui/ellipseeditor.cpp @@ -110,9 +110,9 @@ QList EllipseEditor::currentParts() const { } /** - * @brief EllipseEditor::updateForm + * @brief EllipseEditor::updateFormPriv */ -void EllipseEditor::updateForm() +void EllipseEditor::updateFormPriv() { if (!m_part) { return; diff --git a/sources/editor/ui/ellipseeditor.h b/sources/editor/ui/ellipseeditor.h index 47a24764e..b702a3439 100644 --- a/sources/editor/ui/ellipseeditor.h +++ b/sources/editor/ui/ellipseeditor.h @@ -43,7 +43,7 @@ class EllipseEditor : public ElementItemEditor bool setParts(QList parts) override; CustomElementPart *currentPart() const override; QList currentParts() const override; - void updateForm() override; + void updateFormPriv() override; private slots: void on_m_x_sb_editingFinished(); diff --git a/sources/editor/ui/lineeditor.cpp b/sources/editor/ui/lineeditor.cpp index dd31c310e..4ebd89445 100644 --- a/sources/editor/ui/lineeditor.cpp +++ b/sources/editor/ui/lineeditor.cpp @@ -176,10 +176,10 @@ QList LineEditor::currentParts() const { } /** - @brief LineEditor::updateForm + @brief LineEditor::updateFormPriv Reimplemented from ElementItemEditor */ -void LineEditor::updateForm() +void LineEditor::updateFormPriv() { if (!m_part) { return; diff --git a/sources/editor/ui/lineeditor.h b/sources/editor/ui/lineeditor.h index 8e1496893..20b7ec91e 100644 --- a/sources/editor/ui/lineeditor.h +++ b/sources/editor/ui/lineeditor.h @@ -43,7 +43,7 @@ class LineEditor : public ElementItemEditor bool setParts(QList parts) override; CustomElementPart *currentPart() const override; QList currentParts() const override; - void updateForm() override; + void updateFormPriv() override; private: void setUpChangeConnections(); diff --git a/sources/editor/ui/polygoneditor.cpp b/sources/editor/ui/polygoneditor.cpp index e2c8b1720..5b5392619 100644 --- a/sources/editor/ui/polygoneditor.cpp +++ b/sources/editor/ui/polygoneditor.cpp @@ -130,10 +130,10 @@ QList PolygonEditor::currentParts() const } /** - @brief PolygonEditor::updateForm + @brief PolygonEditor::updateFormPriv Update the widget */ -void PolygonEditor::updateForm() +void PolygonEditor::updateFormPriv() { if (!m_part) { return; diff --git a/sources/editor/ui/polygoneditor.h b/sources/editor/ui/polygoneditor.h index c13dad752..ec60d0360 100644 --- a/sources/editor/ui/polygoneditor.h +++ b/sources/editor/ui/polygoneditor.h @@ -39,7 +39,7 @@ class PolygonEditor : public ElementItemEditor bool setPart(CustomElementPart *part) override; CustomElementPart *currentPart() const override; QList currentParts() const override; - void updateForm() override; + void updateFormPriv() override; QVector pointsFromTree(); bool eventFilter(QObject *watched, QEvent *event) override; diff --git a/sources/editor/ui/rectangleeditor.cpp b/sources/editor/ui/rectangleeditor.cpp index 49a49ab99..8fc505dcc 100644 --- a/sources/editor/ui/rectangleeditor.cpp +++ b/sources/editor/ui/rectangleeditor.cpp @@ -136,7 +136,7 @@ QPointF RectangleEditor::editedTopLeft() const /** @brief RectangleEditor::updateForm */ -void RectangleEditor::updateForm() +void RectangleEditor::updateFormPriv() { if (!m_part) { return; diff --git a/sources/editor/ui/rectangleeditor.h b/sources/editor/ui/rectangleeditor.h index f074a2124..3d9df6f57 100644 --- a/sources/editor/ui/rectangleeditor.h +++ b/sources/editor/ui/rectangleeditor.h @@ -48,7 +48,7 @@ class RectangleEditor : public ElementItemEditor QPointF editedTopLeft () const; public slots: - void updateForm() override; + void updateFormPriv() override; private: void editingFinished(); void activeConnections(bool active); diff --git a/sources/editor/ui/terminaleditor.cpp b/sources/editor/ui/terminaleditor.cpp index a3edf8e54..01fbc9181 100644 --- a/sources/editor/ui/terminaleditor.cpp +++ b/sources/editor/ui/terminaleditor.cpp @@ -46,11 +46,11 @@ TerminalEditor::~TerminalEditor() } /** - * @brief TerminalEditor::updateForm + * @brief TerminalEditor::updateFormPriv * Reimplemented from ElementItemEditor * Update the content of this widget */ -void TerminalEditor::updateForm() +void TerminalEditor::updateFormPriv() { if (!m_part) { return; diff --git a/sources/editor/ui/terminaleditor.h b/sources/editor/ui/terminaleditor.h index 2a708add9..89a44c0f4 100644 --- a/sources/editor/ui/terminaleditor.h +++ b/sources/editor/ui/terminaleditor.h @@ -39,7 +39,7 @@ class TerminalEditor : public ElementItemEditor TerminalEditor(QETElementEditor *editor, QWidget *parent = nullptr); ~TerminalEditor() override; - void updateForm() override; + void updateFormPriv() override; bool setPart(CustomElementPart *new_part) override; CustomElementPart *currentPart() const override; QList currentParts() const override {return QList();} diff --git a/sources/editor/ui/texteditor.cpp b/sources/editor/ui/texteditor.cpp index 512a5614b..a9a95d2ad 100644 --- a/sources/editor/ui/texteditor.cpp +++ b/sources/editor/ui/texteditor.cpp @@ -48,7 +48,7 @@ TextEditor::~TextEditor() {} @brief TextEditor::updateForm Update the gui */ -void TextEditor::updateForm() +void TextEditor::updateFormPriv() { if (m_text.isNull()) { return; diff --git a/sources/editor/ui/texteditor.h b/sources/editor/ui/texteditor.h index 0e7cfd32c..4ede518e1 100644 --- a/sources/editor/ui/texteditor.h +++ b/sources/editor/ui/texteditor.h @@ -38,7 +38,7 @@ class TextEditor : public ElementItemEditor { explicit TextEditor(QETElementEditor *editor, PartText *text = nullptr, QWidget *parent = nullptr); ~TextEditor() override; - void updateForm() override; + void updateFormPriv() override; bool setPart(CustomElementPart *part) override; bool setParts(QList ) override; CustomElementPart *currentPart() const override;