Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/supermerill/SuperSlicer.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorYuSanka <yusanka@gmail.com>2019-06-05 12:03:46 +0300
committerYuSanka <yusanka@gmail.com>2019-06-05 12:14:57 +0300
commit567f382938b7939c4266b2ffcc3e14d91f9a80a1 (patch)
treed27cebf684a0a957379022101151d0a0f5d7ff6b /src/slic3r/GUI/GUI_ObjectLayers.hpp
parent213635f5596193008a96e1f910b8e2da507e9f9d (diff)
Implemented focusing of the last edited range
Diffstat (limited to 'src/slic3r/GUI/GUI_ObjectLayers.hpp')
-rw-r--r--src/slic3r/GUI/GUI_ObjectLayers.hpp19
1 files changed, 14 insertions, 5 deletions
diff --git a/src/slic3r/GUI/GUI_ObjectLayers.hpp b/src/slic3r/GUI/GUI_ObjectLayers.hpp
index f34dd1314..e69a6173a 100644
--- a/src/slic3r/GUI/GUI_ObjectLayers.hpp
+++ b/src/slic3r/GUI/GUI_ObjectLayers.hpp
@@ -14,16 +14,16 @@ class ConfigOptionsGroup;
class LayerRangeEditor : public wxTextCtrl
{
- bool m_enter_pressed { false };
+ bool m_enter_pressed { false };
+ bool m_call_kill_focus { false };
+
public:
LayerRangeEditor( wxWindow* parent,
const wxString& value = wxEmptyString,
- std::function<void(coordf_t val)> edit_fn = [](coordf_t) {},
- const bool deletable_after_change = true
+ std::function<bool(coordf_t val)> edit_fn = [](coordf_t) {return false; }
);
~LayerRangeEditor() {}
-
private:
coordf_t get_value();
};
@@ -34,7 +34,16 @@ class ObjectLayers : public OG_Settings
ScalableBitmap m_bmp_add;
ModelObject* m_object {nullptr};
- wxFlexGridSizer* m_grid_sizer;
+ wxFlexGridSizer* m_grid_sizer;
+ std::pair<coordf_t, coordf_t> m_last_edited_range;
+
+ enum SelectedItemType
+ {
+ sitUndef,
+ sitMinZ,
+ sitMaxZ,
+ sitLayerHeight,
+ } m_selection_type {sitUndef};
public:
ObjectLayers(wxWindow* parent);