BornAgain
1.19.0
Simulate and fit neutron and x-ray scattering at grazing incidence
|
Handles user actions applied to layer tree. More...
Classes | |
struct | LayerEditorActionsImpl |
Public Member Functions | |
LayerEditorActions (QObject *parent=nullptr) | |
~LayerEditorActions () | |
void | onAddLayer () |
Adds layer after selected item. If more than one item is selected, adds after the last one. More... | |
void | onAddMultiLayer () |
void | onClone () |
void | onMoveDown () |
void | onMoveUp () |
void | onRemove () |
void | setModel (SampleModel *model) |
void | setSelectionModel (LayerSelectionModel *selection_model) |
Private Attributes | |
std::unique_ptr< LayerEditorActionsImpl > | p_impl |
Handles user actions applied to layer tree.
Belongs to LayerEditor.
Definition at line 30 of file layereditoractions.h.
gui2::LayerEditorActions::LayerEditorActions | ( | QObject * | parent = nullptr | ) |
Definition at line 53 of file layereditoractions.cpp.
|
default |
void gui2::LayerEditorActions::onAddLayer | ( | ) |
Adds layer after selected item. If more than one item is selected, adds after the last one.
Definition at line 65 of file layereditoractions.cpp.
References p_impl.
Referenced by gui2::LayerEditorToolBar::create_layer_menu().
void gui2::LayerEditorActions::onAddMultiLayer | ( | ) |
Definition at line 75 of file layereditoractions.cpp.
References p_impl.
Referenced by gui2::LayerEditorToolBar::create_layer_menu().
void gui2::LayerEditorActions::onClone | ( | ) |
Definition at line 87 of file layereditoractions.cpp.
References p_impl.
Referenced by gui2::LayerEditorToolBar::LayerEditorToolBar().
void gui2::LayerEditorActions::onMoveDown | ( | ) |
Definition at line 132 of file layereditoractions.cpp.
References ModelView::Utils::MoveDown(), and p_impl.
Referenced by gui2::LayerEditorToolBar::LayerEditorToolBar().
void gui2::LayerEditorActions::onMoveUp | ( | ) |
Definition at line 122 of file layereditoractions.cpp.
References ModelView::Utils::MoveUp(), and p_impl.
Referenced by gui2::LayerEditorToolBar::LayerEditorToolBar().
void gui2::LayerEditorActions::onRemove | ( | ) |
Definition at line 104 of file layereditoractions.cpp.
References ModelView::Utils::DeleteItemFromModel(), ModelView::Utils::FindNextSibling(), ModelView::Utils::FindPreviousSibling(), and p_impl.
Referenced by gui2::LayerEditorToolBar::LayerEditorToolBar().
void gui2::LayerEditorActions::setModel | ( | SampleModel * | model | ) |
Definition at line 58 of file layereditoractions.cpp.
References p_impl.
Referenced by gui2::LayerEditor::setModels().
void gui2::LayerEditorActions::setSelectionModel | ( | LayerSelectionModel * | selection_model | ) |
Definition at line 142 of file layereditoractions.cpp.
References p_impl.
Referenced by gui2::LayerEditor::setModels().
|
private |
Definition at line 50 of file layereditoractions.h.
Referenced by onAddLayer(), onAddMultiLayer(), onClone(), onMoveDown(), onMoveUp(), onRemove(), setModel(), and setSelectionModel().