diff options
| author | Alexander Valavanis <valavanisalex@gmail.com> | 2019-02-01 19:59:05 +0000 |
|---|---|---|
| committer | Alexander Valavanis <valavanisalex@gmail.com> | 2019-02-01 19:59:05 +0000 |
| commit | db053372c3b10afd89e780ab08a63493ccc3d1a7 (patch) | |
| tree | 97d7ad322270c4167de38b7194021d45405fa8d5 /src/ui/widget | |
| parent | ComboToolItem: Temporary workaround to display pixbuf by default (diff) | |
| download | inkscape-db053372c3b10afd89e780ab08a63493ccc3d1a7.tar.gz inkscape-db053372c3b10afd89e780ab08a63493ccc3d1a7.zip | |
clang-tidy recent changes
Diffstat (limited to 'src/ui/widget')
| -rw-r--r-- | src/ui/widget/combo-tool-item.cpp | 12 | ||||
| -rw-r--r-- | src/ui/widget/combo-tool-item.h | 6 | ||||
| -rw-r--r-- | src/ui/widget/spin-button-tool-item.cpp | 1 | ||||
| -rw-r--r-- | src/ui/widget/spinbutton.h | 9 |
4 files changed, 13 insertions, 15 deletions
diff --git a/src/ui/widget/combo-tool-item.cpp b/src/ui/widget/combo-tool-item.cpp index ee9202b6f..eb26e5c6e 100644 --- a/src/ui/widget/combo-tool-item.cpp +++ b/src/ui/widget/combo-tool-item.cpp @@ -39,13 +39,13 @@ ComboToolItem::create(const Glib::ustring &group_label, return new ComboToolItem(group_label, tooltip, stock_id, store); } -ComboToolItem::ComboToolItem(const Glib::ustring &group_label, - const Glib::ustring &tooltip, - const Glib::ustring &stock_id, +ComboToolItem::ComboToolItem(Glib::ustring group_label, + Glib::ustring tooltip, + Glib::ustring stock_id, Glib::RefPtr<Gtk::ListStore> store ) : - _group_label( group_label ), - _tooltip( tooltip ), - _stock_id( stock_id ), + _group_label(std::move( group_label )), + _tooltip(std::move( tooltip )), + _stock_id(std::move( stock_id )), _store (std::move(store)), _use_label (true), _use_icon (false), diff --git a/src/ui/widget/combo-tool-item.h b/src/ui/widget/combo-tool-item.h index 50f81cc43..1e4590163 100644 --- a/src/ui/widget/combo-tool-item.h +++ b/src/ui/widget/combo-tool-item.h @@ -105,9 +105,9 @@ private: void on_changed_combobox(); void on_toggled_radiomenu(int n); - ComboToolItem(const Glib::ustring &group_label, - const Glib::ustring &tooltip, - const Glib::ustring &stock_id, + ComboToolItem(Glib::ustring group_label, + Glib::ustring tooltip, + Glib::ustring stock_id, Glib::RefPtr<Gtk::ListStore> store ); }; } diff --git a/src/ui/widget/spin-button-tool-item.cpp b/src/ui/widget/spin-button-tool-item.cpp index 2efb24ff9..140df1586 100644 --- a/src/ui/widget/spin-button-tool-item.cpp +++ b/src/ui/widget/spin-button-tool-item.cpp @@ -274,7 +274,6 @@ SpinButtonToolItem::create_numeric_menu() auto adj_value = adj->get_value(); auto lower = adj->get_lower(); auto upper = adj->get_upper(); - auto range = upper - lower; auto step = adj->get_step_increment(); auto page = adj->get_page_increment(); diff --git a/src/ui/widget/spinbutton.h b/src/ui/widget/spinbutton.h index 33ff11576..c41aabf84 100644 --- a/src/ui/widget/spinbutton.h +++ b/src/ui/widget/spinbutton.h @@ -48,6 +48,10 @@ public: ~SpinButton() override = default;; + // noncopyable + SpinButton(const SpinButton&) = delete; + SpinButton& operator=(const SpinButton&) = delete; + void setUnitMenu(UnitMenu* unit_menu) { _unit_menu = unit_menu; }; void addUnitTracker(UnitTracker* ut) { _unit_tracker = ut; }; @@ -87,11 +91,6 @@ protected: * Undo the editing, by resetting the value upon when the spinbutton got focus. */ void undo(); - -private: - // noncopyable - SpinButton(const SpinButton&) = delete; - SpinButton& operator=(const SpinButton&) = delete; }; } // namespace Widget |
