[gnote] Use Gtk::ModelButton for Popover button
- From: Aurimas Černius <aurimasc src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gnote] Use Gtk::ModelButton for Popover button
- Date: Sun, 20 Dec 2015 19:06:49 +0000 (UTC)
commit d0781496b4eabdd1bc227a576d4b8ee6cc6a6b58
Author: Aurimas Černius <aurisc4 gmail com>
Date: Sun Dec 20 21:05:01 2015 +0200
Use Gtk::ModelButton for Popover button
src/utils.cpp | 11 ++++++-----
1 files changed, 6 insertions(+), 5 deletions(-)
---
diff --git a/src/utils.cpp b/src/utils.cpp
index 9a39255..d7ebeef 100644
--- a/src/utils.cpp
+++ b/src/utils.cpp
@@ -39,6 +39,7 @@
#include <gtkmm/icontheme.h>
#include <gtkmm/image.h>
#include <gtkmm/label.h>
+#include <gtkmm/modelbutton.h>
#include <gtkmm/stock.h>
#include <gtkmm/textbuffer.h>
@@ -275,11 +276,11 @@ namespace gnote {
Gtk::Widget * create_popover_button(const Glib::ustring & action, const Glib::ustring & label)
{
- GtkWidget *item = gtk_model_button_new();
- gtk_actionable_set_action_name(GTK_ACTIONABLE(item), action.c_str());
- gtk_button_set_label(GTK_BUTTON(item), label.c_str());
- gtk_button_set_use_underline(GTK_BUTTON(item), TRUE);
- return Glib::wrap(item);
+ Gtk::ModelButton *item = new Gtk::ModelButton;
+ gtk_actionable_set_action_name(GTK_ACTIONABLE(item->gobj()), action.c_str());
+ item->set_label(label);
+ item->set_use_underline(true);
+ return item;
}
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]