This class is responsible to manage the ControlEditor instances in the application.
More...
#include <ControlEditorManager.h>
This class is responsible to manage the ControlEditor instances in the application.
- Author
- Thales Lima Oliveira thale.nosp@m.s.ol.nosp@m.iveir.nosp@m.a@uf.nosp@m.tm.ed.nosp@m.u.br
- Date
- 30/06/2026
Definition at line 34 of file ControlEditorManager.h.
◆ ControlEditorManager()
| ControlEditorManager::ControlEditorManager |
( |
Workspace * |
workspace | ) |
|
|
explicit |
◆ ~ControlEditorManager()
| ControlEditorManager::~ControlEditorManager |
( |
| ) |
|
◆ CloseAll()
| void ControlEditorManager::CloseAll |
( |
| ) |
|
Definition at line 73 of file ControlEditorManager.cpp.
74{
75 auto editors = m_editors;
76
77 for (auto* editor : editors)
78 {
79 if (editor)
80 editor->Destroy();
81 }
82
83 m_editors.clear();
84}
◆ GetEditor()
Definition at line 91 of file ControlEditorManager.cpp.
92{
93 for (auto* editor : m_editors)
94 {
95 if (!editor)
96 continue;
97
98 if (editor->GetControlContainer() == container)
99 return editor;
100 }
101
102 return nullptr;
103}
◆ IsOpen()
◆ Open()
Definition at line 36 of file ControlEditorManager.cpp.
37{
39
40 if (editor)
41 {
42
43
44
45 editor->Close();
46 editor = nullptr;
47 }
48
49 editor =
new ControlEditor(m_workspace, m_workspace->GetProperties(), ioFlags);
50
51 editor->SetManager(this);
52 editor->SetElementsList(container->GetControlElementsList());
53 editor->SetConnectionsList(container->GetConnectionLineList());
54 editor->SetControlContainer(container);
55 editor->SetPlotLib(plotLib);
56
57 m_editors.push_back(editor);
58
59 editor->Show();
60 editor->SetJustOpened(true);
61
62 return editor;
63}
◆ Remove()
Definition at line 65 of file ControlEditorManager.cpp.
66{
67 auto it = std::find(m_editors.begin(), m_editors.end(), editor);
68
69 if (it != m_editors.end())
70 m_editors.erase(it);
71}
◆ m_editors
◆ m_workspace
| Workspace* ControlEditorManager::m_workspace = nullptr |
|
private |
The documentation for this class was generated from the following files: