[gnote] Remove unused CheckActions
- From: Aurimas Černius <aurimasc src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gnote] Remove unused CheckActions
- Date: Sun, 9 May 2021 18:29:50 +0000 (UTC)
commit 1f30fa85af1d7deb580475fc8326626de7907e76
Author: Aurimas Černius <aurisc4 gmail com>
Date: Sun May 9 21:29:42 2021 +0300
Remove unused CheckActions
src/utils.cpp | 20 --------------------
src/utils.hpp | 26 --------------------------
2 files changed, 46 deletions(-)
---
diff --git a/src/utils.cpp b/src/utils.cpp
index a6118319..7aeca629 100644
--- a/src/utils.cpp
+++ b/src/utils.cpp
@@ -30,7 +30,6 @@
#include <glibmm/i18n.h>
#include <glibmm/stringutils.h>
#include <glibmm/threads.h>
-#include <gtkmm/checkmenuitem.h>
#include <gtkmm/image.h>
#include <gtkmm/textbuffer.h>
@@ -706,24 +705,5 @@ namespace gnote {
return false;
}
-
- CheckAction::CheckAction(const Glib::ustring & name)
- : Gtk::Action(name)
- , m_checked(false)
- {}
-
- Gtk::Widget *CheckAction::create_menu_item_vfunc()
- {
- Gtk::CheckMenuItem *item = new Gtk::CheckMenuItem;
- item->set_active(m_checked);
- return item;
- }
-
- void CheckAction::on_activate()
- {
- m_checked = !m_checked;
- Gtk::Action::on_activate();
- }
-
}
}
diff --git a/src/utils.hpp b/src/utils.hpp
index 92af2f14..a4af6467 100644
--- a/src/utils.hpp
+++ b/src/utils.hpp
@@ -221,32 +221,6 @@ class Preferences;
bool timeout_expired();
guint m_timeout_id;
};
-
-
- class CheckAction
- : public Gtk::Action
- {
- public:
- typedef Glib::RefPtr<CheckAction> Ptr;
- static Ptr create(const Glib::ustring & name)
- {
- return Ptr(new CheckAction(name));
- }
- void checked(bool check)
- {
- m_checked = check;
- }
- bool checked() const
- {
- return m_checked;
- }
- protected:
- CheckAction(const Glib::ustring & name);
- virtual Gtk::Widget *create_menu_item_vfunc() override;
- virtual void on_activate() override;
- private:
- bool m_checked;
- };
}
}
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]