Editor API
UnigineEditor public API
Selection.h
1 // Copyright (C), UNIGINE. All rights reserved.
2 #pragma once
3 
4 
5 #include <EditorGlobal.h>
6 #include <QObject>
7 
8 
10 // Forward decl.
12 namespace Editor
13 {
14 class Presenter;
15 class Selector;
16 class SelectorNodes;
17 class SelectorGUIDs;
18 }
19 
20 
21 namespace Editor
22 {
24 // Selection.
26 class EDITOR_API Selection: public QObject
27 {
28  Q_OBJECT
29 public:
38  static Selection *instance();
39 
41  static void clear();
43  static Selector *getSelector();
45  static void setSelector(Selector *selector);
47  static Selector *copySelector();
48 
51  static SelectorNodes *getSelectorNodes();
54  static SelectorGUIDs *getSelectorRuntimes();
57  static SelectorGUIDs *getSelectorMaterials();
60  static SelectorGUIDs *getSelectorProperties();
61 
64  static SelectorNodes *copySelectorNodes();
67  static SelectorGUIDs *copySelectorRuntimes();
70  static SelectorGUIDs *copySelectorMaterials();
73  static SelectorGUIDs *copySelectorProperties();
74 
75 signals:
77  void changed();
78 
79 private:
80  explicit Selection(QObject *parent);
81  ~Selection() override;
82 
83  friend class Editor::Presenter;
84 };
85 
86 
87 } // namespace Editor
Definition: Actions.h:9
Definition: Selector.h:48
Selector for GUIDs-based items (materials, properties, runtimes). An item of this type is associated ...
Definition: Selector.h:69
Definition: Selection.h:26
This class is used to manage selected nodes along with their subobjects (such as surfaces,...
Definition: Selector.h:117