[Xfce4-commits] <midori:master> Build an invisible menubar in Hildon to retain hotkey functionality

Christian Dywan noreply at xfce.org
Sun Nov 29 15:12:02 CET 2009


Updating branch refs/heads/master
         to d9eb5dcec9d55cf39b718b59dcdee9291fb68f5c (commit)
       from a7ca507b3a2ad8246fae380e84656f0debe57074 (commit)

commit d9eb5dcec9d55cf39b718b59dcdee9291fb68f5c
Author: Christian Dywan <christian at twotoasts.de>
Date:   Sun Nov 29 15:00:15 2009 +0100

    Build an invisible menubar in Hildon to retain hotkey functionality
    
    GtkUIManager requires existing proxies for hotkeys to work at all.

 midori/midori-browser.c |    6 +++---
 1 files changed, 3 insertions(+), 3 deletions(-)

diff --git a/midori/midori-browser.c b/midori/midori-browser.c
index 2dc41e7..f8a0ddf 100644
--- a/midori/midori-browser.c
+++ b/midori/midori-browser.c
@@ -5753,6 +5753,9 @@ midori_browser_init (MidoriBrowser* browser)
     g_object_unref (action);
 
     /* Create the menubar */
+    browser->menubar = gtk_ui_manager_get_widget (ui_manager, "/menubar");
+    gtk_box_pack_start (GTK_BOX (vbox), browser->menubar, FALSE, FALSE, 0);
+    gtk_widget_hide (browser->menubar);
     #if HAVE_HILDON
     #if HILDON_CHECK_VERSION (2, 2, 0)
     browser->menubar = hildon_app_menu_new ();
@@ -5766,9 +5769,6 @@ midori_browser_init (MidoriBrowser* browser)
     hildon_program_add_window (hildon_program_get_instance (),
                                HILDON_WINDOW (browser));
     #else
-    browser->menubar = gtk_ui_manager_get_widget (ui_manager, "/menubar");
-    gtk_box_pack_start (GTK_BOX (vbox), browser->menubar, FALSE, FALSE, 0);
-    gtk_widget_hide (browser->menubar);
     g_signal_connect (browser->menubar, "button-press-event",
         G_CALLBACK (midori_browser_menu_button_press_event_cb), browser);
 



More information about the Xfce4-commits mailing list