diff options
author | Alan Fitton <ajf@eth0.org.uk> | 2011-12-12 22:32:01 +0000 |
---|---|---|
committer | Alan Fitton <ajf@eth0.org.uk> | 2011-12-12 22:32:01 +0000 |
commit | c8240fd86272a628ef20e6947dde0f53620f33e5 (patch) | |
tree | 8a2832c7d17b1295f2316af9b54a6eb819ff3ad5 | |
parent | 01ec0d25feda61bfe4a4d04a97893d40618aad5d (diff) |
use gtk_status_icon_position_menu when right clicking a GtkStatusIcon. This positions it correctly, as I notice on GNOME3 (not on XFCE or Ubuntu with libappindicator) the top can be obscured, depending where on the icon you click.
-rw-r--r-- | src/trg-main-window.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/src/trg-main-window.c b/src/trg-main-window.c index 92680a1..8c93c7c 100644 --- a/src/trg-main-window.c +++ b/src/trg-main-window.c @@ -1656,9 +1656,9 @@ static gboolean status_icon_button_press_event(GtkStatusIcon * icon, { if (event->type == GDK_BUTTON_PRESS && event->button == 3) { TrgMainWindowPrivate *priv = TRG_MAIN_WINDOW_GET_PRIVATE(data); - gtk_menu_popup(priv->iconMenu, NULL, NULL, NULL, NULL, - (event != NULL) ? event->button : 0, - gdk_event_get_time((GdkEvent *) event)); + gtk_menu_popup(priv->iconMenu, NULL, NULL, + gtk_status_icon_position_menu, priv->statusIcon, event->button, + gdk_event_get_time((GdkEvent *) event)); return TRUE; } else { return FALSE; |