Problems at use | Problèmes à l'utilisation
Vorron, Saturday 15 June 2013 à 18:41
|
|
Subscription date : 31 May 2013
Messages : 20
|
Hotkeys for global menu applet and application menu applet still doesn't work.
Cairo-dock 3.2.99.alpha2
Ubuntu 13.04 |
matttbe, Saturday 15 June 2013 à 19:19
|
|
Subscription date : 24 January 2009
Messages : 12573
|
Hello and thank you for this bug report,
Yes, I confirm this bug which is due to some changes in GTKMenu. It needs some "consequent" changes in the core...
I'll add a task! |
matttbe, Monday 17 June 2013 à 15:18
|
|
Subscription date : 24 January 2009
Messages : 12573
|
fabounet : these shortkeys are maybe used by another application
you can see that by launching the dock in a terminal (close the running one first)
No
I also have this bug with all shortcuts which try to popup a GtkMenu...
According to the documentation, gtk_menu_popup should be used with the timestamp of the event (when pressing the hotkey) and with the button = 0.
I implement that but it's still not working...
Any idea?
PS: I confirm that the problem is not due to a wrong shortkey because with a short delay (min 200ms), I don't have any problem to open a menu from a shortkey.
=== modified file 'src/gldit/cairo-dock-container.c'
--- src/gldit/cairo-dock-container.c 2013-06-04 22:58:28 +0000
+++ src/gldit/cairo-dock-container.c 2013-06-17 13:13:48 +0000
@@ -371,9 +371,28 @@
*x = y0 + pIcon->fHeight * pIcon->fScale;
}
}
+
+static gboolean _popup_menu (gpointer *data)
+{
+ GtkMenuPositionFunc place_menu = data[2];
+ GtkWidget *menu = data[3];
+ gtk_widget_show_all (GTK_WIDGET (menu));
+
+ gtk_menu_popup (GTK_MENU (menu),
+ NULL,
+ NULL,
+ place_menu,
+ data,
+ 1,
+ gtk_get_current_event_time ());
+ gtk_widget_show_all (GTK_WIDGET (menu));
+
+ return FALSE;
+}
+
void cairo_dock_popup_menu_on_icon (GtkWidget *menu, Icon *pIcon, GldiContainer *pContainer)
{
- static gpointer data[2]; + static gpointer data[4]; if (menu == NULL)
return;
@@ -383,20 +402,14 @@
place_menu = (GtkMenuPositionFunc)_place_menu_on_icon;
data[0] = pIcon;
data[1] = pContainer;
+ data[2] = place_menu;
}
+ data[3] = menu;
if (pContainer->iface.setup_menu)
pContainer->iface.setup_menu (pContainer, pIcon, menu);
-
- gtk_widget_show_all (GTK_WIDGET (menu));
-
- gtk_menu_popup (GTK_MENU (menu),
- NULL,
- NULL,
- place_menu,
- data,
- 1,
- gtk_get_current_event_time ());
+
+ g_timeout_add (200, (GSourceFunc) _popup_menu, data);
}
|
Subscription date : 30 November 2007
Messages : 17118
|
so it goes until the gtk_menu_popup, but the menu doesn't pop up ?
does it happen with another WM ? what if you set 0 instead of gtk_get_current_event_time() ? and 0 instead of 1 ? |
matttbe, Friday 21 June 2013 à 20:52
|
|
Subscription date : 24 January 2009
Messages : 12573
|
so it goes until the gtk_menu_popup, but the menu doesn't pop up ? Yes
does it happen with another WM ? I also have this bug with Mutter.
what if you set 0 instead of gtk_get_current_event_time() ? No difference. (but it still works when clicking on the icon)
and 0 instead of 1 ? For the button? No difference except that I have to maintain the right click button when navigating into these menus
@fabounet: do you have this bug? What's your version of GTK? |
Vorron, Wednesday 26 June 2013 à 13:23
|
|
Subscription date : 31 May 2013
Messages : 20
|
After last update application menu hotkey fixed, but global menu hotkey still doesn't work. |
Vorron, Saturday 20 July 2013 à 14:50
|
|
Subscription date : 31 May 2013
Messages : 20
|
By the way, global menu hotkey still doesn't work |
Subscription date : 30 November 2007
Messages : 17118
|
strange, they both use the same method
does it work on clicking on the icon ? isn't the shortkey used by another program ? |
Vorron, Friday 09 August 2013 à 20:33
|
|
Subscription date : 31 May 2013
Messages : 20
|
fabounet : does it work on clicking on the icon ? isn't the shortkey used by another program ?
Yes, clicking on icon works ok. Another programms definitely not used this key, and I was trying change hotkey as well.
Also, if press key when application without menu active, then message "The application didn't sent its menu to us" pops up. But with normal application nothing happens. |
Vorron, Thursday 15 August 2013 à 17:48
|
|
Subscription date : 31 May 2013
Messages : 20
|
It seems the cause of trouble was found. Problem with hotkey is only while option "Pop up the menu at mouse position" enabled. All works fine when it unchecked. My bad I have not noticed this before, but it's probably something wrong with this option. |
matttbe, Saturday 17 August 2013 à 00:43
|
|
Subscription date : 24 January 2009
Messages : 12573
|
Thank you for this detail!
@fabounet: any idea about this bug?  |
Guest, Saturday 24 August 2013 à 21:59
|
|
|
Vorron : It seems the cause of trouble was found. Problem with hotkey is only while option "Pop up the menu at mouse position" enabled. All works fine when it unchecked. My bad I have not noticed this before, but it's probably something wrong with this option.
Uhm... where do I find that option, so I can disable it?
I've looked through the menus in cairo, and I just can't find it. |
matttbe, Saturday 24 August 2013 à 23:47
|
|
Subscription date : 24 January 2009
Messages : 12573
|
Right click on Global Menu applet / Global Menu / Edit / Configuration / Third option
(PS: there is a 'filter' in the advanced mode of the config panel ) |
Problems at use | Problèmes à l'utilisation
|