[gtk/wip/ebassi/shortcut: 193/267] widget: Port bindings to use shortcuts
- From: Emmanuele Bassi <ebassi src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gtk/wip/ebassi/shortcut: 193/267] widget: Port bindings to use shortcuts
- Date: Thu, 6 Feb 2020 18:20:05 +0000 (UTC)
commit 1d25790c0d0ae5c81f251a4d673a257fdf3bc44d
Author: Benjamin Otte <otte redhat com>
Date: Sat Aug 11 17:22:10 2018 +0200
widget: Port bindings to use shortcuts
gtk/gtkwidget.c | 15 ++++++++-------
1 file changed, 8 insertions(+), 7 deletions(-)
---
diff --git a/gtk/gtkwidget.c b/gtk/gtkwidget.c
index 31ebf46602..7c92d4c6c9 100644
--- a/gtk/gtkwidget.c
+++ b/gtk/gtkwidget.c
@@ -30,7 +30,6 @@
#include "gtkaccelgroupprivate.h"
#include "gtkaccessible.h"
#include "gtkapplicationprivate.h"
-#include "gtkbindings.h"
#include "gtkbuildable.h"
#include "gtkbuilderprivate.h"
#include "gtkcontainerprivate.h"
@@ -866,7 +865,6 @@ static void
gtk_widget_class_init (GtkWidgetClass *klass)
{
GObjectClass *gobject_class = G_OBJECT_CLASS (klass);
- GtkBindingSet *binding_set;
g_type_class_adjust_private_offset (klass, &GtkWidget_private_offset);
gtk_widget_parent_class = g_type_class_peek_parent (klass);
@@ -1733,11 +1731,14 @@ gtk_widget_class_init (GtkWidgetClass *klass)
G_TYPE_FROM_CLASS (klass),
_gtk_marshal_BOOLEAN__UINTv);
- binding_set = gtk_binding_set_by_class (klass);
- gtk_binding_entry_add_signal (binding_set, GDK_KEY_F10, GDK_SHIFT_MASK,
- "popup-menu", 0);
- gtk_binding_entry_add_signal (binding_set, GDK_KEY_Menu, 0,
- "popup-menu", 0);
+ gtk_widget_class_add_binding_signal (klass,
+ GDK_KEY_F10, GDK_SHIFT_MASK,
+ "popup-menu",
+ NULL);
+ gtk_widget_class_add_binding_signal (klass,
+ GDK_KEY_Menu, 0,
+ "popup-menu",
+ NULL);
gtk_widget_class_set_accessible_type (klass, GTK_TYPE_WIDGET_ACCESSIBLE);
gtk_widget_class_set_css_name (klass, I_("widget"));
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]