[gtk+] application: new 'insert action group' private api



commit 6da7b11ff60726d410e40d744dcaa174fa2a47f1
Author: Ryan Lortie <desrt desrt ca>
Date:   Wed Jan 15 01:21:29 2014 -0500

    application: new 'insert action group' private api
    
    Add a new private API to GtkApplication akin to
    gtk_widget_insert_action_group().
    
    We'll use this to insert a few extra actions at the app level with a
    separate namespace for the special items in the Mac OS application menu.
    
    https://bugzilla.gnome.org/show_bug.cgi?id=720552

 gtk/gtkapplication.c        |    8 ++++++++
 gtk/gtkapplicationprivate.h |    4 ++++
 2 files changed, 12 insertions(+), 0 deletions(-)
---
diff --git a/gtk/gtkapplication.c b/gtk/gtkapplication.c
index 5e55b8c..61035b5 100644
--- a/gtk/gtkapplication.c
+++ b/gtk/gtkapplication.c
@@ -1546,6 +1546,14 @@ gtk_application_get_action_muxer (GtkApplication *application)
 }
 
 void
+gtk_application_insert_action_group (GtkApplication *application,
+                                     const gchar    *name,
+                                     GActionGroup   *action_group)
+{
+  gtk_action_muxer_insert (application->priv->muxer, name, action_group);
+}
+
+void
 gtk_application_handle_window_realize (GtkApplication *application,
                                        GtkWindow      *window)
 {
diff --git a/gtk/gtkapplicationprivate.h b/gtk/gtkapplicationprivate.h
index 7847fcf..3ba26d5 100644
--- a/gtk/gtkapplicationprivate.h
+++ b/gtk/gtkapplicationprivate.h
@@ -53,6 +53,10 @@ void                    gtk_application_foreach_accel_keys              (GtkAppl
                                                                          gpointer                  
user_data);
 G_GNUC_INTERNAL
 GtkActionMuxer *        gtk_application_get_action_muxer                (GtkApplication           
*application);
+G_GNUC_INTERNAL
+void                    gtk_application_insert_action_group             (GtkApplication           
*application,
+                                                                         const gchar              *name,
+                                                                         GActionGroup             
*action_group);
 
 
 #define GTK_TYPE_APPLICATION_IMPL                           (gtk_application_impl_get_type ())


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]