[gtk/wip/matthiasc/popup4: 25/115] window: Implement root mnemonic api
- From: Matthias Clasen <matthiasc src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gtk/wip/matthiasc/popup4: 25/115] window: Implement root mnemonic api
- Date: Wed, 24 Apr 2019 19:32:43 +0000 (UTC)
commit 7cfdc6cf9ea23b324779ef7144311a70e31e1aa3
Author: Matthias Clasen <mclasen redhat com>
Date: Sun Mar 3 22:24:21 2019 -0500
window: Implement root mnemonic api
Hook up the root mnemonic api to the existing
mnemonic machinery.
gtk/gtkwindow.c | 26 ++++++++++++++++++++++++++
1 file changed, 26 insertions(+)
---
diff --git a/gtk/gtkwindow.c b/gtk/gtkwindow.c
index 3356e1fa73..fefdc677be 100644
--- a/gtk/gtkwindow.c
+++ b/gtk/gtkwindow.c
@@ -2348,6 +2348,29 @@ gtk_window_root_check_resize (GtkRoot *root)
gtk_window_check_resize (GTK_WINDOW (root));
}
+static void
+gtk_window_root_add_mnemonic (GtkRoot *root,
+ guint keyval,
+ GtkWidget *target)
+{
+ gtk_window_add_mnemonic (GTK_WINDOW (root), keyval, target);
+}
+
+static void
+gtk_window_root_remove_mnemonic (GtkRoot *root,
+ guint keyval,
+ GtkWidget *target)
+{
+ gtk_window_remove_mnemonic (GTK_WINDOW (root), keyval, target);
+}
+
+static gboolean
+gtk_window_root_activate_key (GtkRoot *root,
+ GdkEventKey *event)
+{
+ return gtk_window_activate_key (GTK_WINDOW (root), event);
+}
+
static void
gtk_window_root_interface_init (GtkRootInterface *iface)
{
@@ -2355,6 +2378,9 @@ gtk_window_root_interface_init (GtkRootInterface *iface)
iface->get_renderer = gtk_window_root_get_renderer;
iface->get_surface_transform = gtk_window_root_get_surface_transform;
iface->check_resize = gtk_window_root_check_resize;
+ iface->add_mnemonic = gtk_window_root_add_mnemonic;
+ iface->remove_mnemonic = gtk_window_root_remove_mnemonic;
+ iface->activate_key = gtk_window_root_activate_key;
}
/**
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]