From 0fcf616ce740986f4a4f0d5aecd7048ad3a6da54 Mon Sep 17 00:00:00 2001 From: David Robillard Date: Wed, 23 Aug 2023 11:12:50 -0400 Subject: Add missing const qualifiers --- src/gui/App.hpp | 2 +- src/gui/GraphTreeWindow.hpp | 2 +- src/gui/WidgetFactory.hpp | 4 ++-- 3 files changed, 4 insertions(+), 4 deletions(-) (limited to 'src/gui') diff --git a/src/gui/App.hpp b/src/gui/App.hpp index bb17e126..6c77ea2d 100644 --- a/src/gui/App.hpp +++ b/src/gui/App.hpp @@ -97,7 +97,7 @@ public: bool signal() const { return _enable_signal; } void enable_signals(bool b) { _enable_signal = b; } bool disable_signals() { - bool old = _enable_signal; + const bool old = _enable_signal; _enable_signal = false; return old; } diff --git a/src/gui/GraphTreeWindow.hpp b/src/gui/GraphTreeWindow.hpp index 8534d66c..dab81c90 100644 --- a/src/gui/GraphTreeWindow.hpp +++ b/src/gui/GraphTreeWindow.hpp @@ -119,7 +119,7 @@ public: void set_window(GraphTreeWindow* win) { _window = win; } bool on_button_press_event(GdkEventButton* ev) override { - bool ret = Gtk::TreeView::on_button_press_event(ev); + const bool ret = Gtk::TreeView::on_button_press_event(ev); if ((ev->type == GDK_BUTTON_PRESS) && (ev->button == 3)) { _window->show_graph_menu(ev); diff --git a/src/gui/WidgetFactory.hpp b/src/gui/WidgetFactory.hpp index 1c45fd6e..474071ec 100644 --- a/src/gui/WidgetFactory.hpp +++ b/src/gui/WidgetFactory.hpp @@ -38,13 +38,13 @@ public: template static void get_widget(const Glib::ustring& name, T*& widget) { - Glib::RefPtr xml = create(name); + const Glib::RefPtr xml = create(name); xml->get_widget(name, widget); } template static void get_widget_derived(const Glib::ustring& name, T*& widget) { - Glib::RefPtr xml = create(name); + const Glib::RefPtr xml = create(name); xml->get_widget_derived(name, widget); } -- cgit v1.2.1