diff options
Diffstat (limited to 'src')
-rw-r--r-- | src/app-indicator.c | 25 | ||||
-rw-r--r-- | src/notification-item.xml | 3 |
2 files changed, 16 insertions, 12 deletions
diff --git a/src/app-indicator.c b/src/app-indicator.c index aae8434..c2f0f69 100644 --- a/src/app-indicator.c +++ b/src/app-indicator.c @@ -1022,7 +1022,8 @@ bus_method_call (GDBusConnection * connection, const gchar * sender, delta = ABS(delta); g_signal_emit(app, signals[SCROLL_EVENT], 0, delta, direction); - } else if (g_strcmp0(method, "SecondaryActivate") == 0) { + } else if (g_strcmp0(method, "SecondaryActivate") == 0 || + g_strcmp0(method, "XAyatanaSecondaryActivate") == 0) { GtkWidget *menuitem = priv->sec_activate_target; if (priv->sec_activate_enabled && menuitem && @@ -1994,7 +1995,7 @@ setup_dbusmenu (AppIndicator *self) return; } -/* +/** * app_indicator_set_menu: * @self: The #AppIndicator * @menu: (allow-none): A #GtkMenu to set @@ -2074,15 +2075,15 @@ app_indicator_set_secondary_activate_target (AppIndicator *self, GtkWidget *menu g_return_if_fail (IS_APP_INDICATOR (self)); AppIndicatorPrivate *priv = self->priv; - if (menuitem == NULL) { - if (priv->sec_activate_target) { - g_object_unref(G_OBJECT(priv->sec_activate_target)); - g_signal_handlers_disconnect_by_func (priv->sec_activate_target, - sec_activate_target_parent_changed, - self); - priv->sec_activate_target = NULL; - } + if (priv->sec_activate_target) { + g_signal_handlers_disconnect_by_func (priv->sec_activate_target, + sec_activate_target_parent_changed, + self); + g_object_unref(G_OBJECT(priv->sec_activate_target)); + priv->sec_activate_target = NULL; + } + if (menuitem == NULL) { return; } @@ -2228,7 +2229,7 @@ app_indicator_get_attention_icon_desc (AppIndicator *self) * Gets the menu being used for this application indicator. * Wrapper function for property #AppIndicator:menu. * - * Returns: (transfer full): A #GtkMenu object or %NULL if one hasn't been set. + * Returns: (transfer none): A #GtkMenu object or %NULL if one hasn't been set. */ GtkMenu * app_indicator_get_menu (AppIndicator *self) @@ -2300,7 +2301,7 @@ app_indicator_get_ordering_index (AppIndicator *self) * * Gets the menuitem being called on secondary-activate event. * - * Returns: (transfer full): A #GtkWidget object or %NULL if none has been set. + * Returns: (transfer none): A #GtkWidget object or %NULL if none has been set. */ GtkWidget * app_indicator_get_secondary_activate_target (AppIndicator *self) diff --git a/src/notification-item.xml b/src/notification-item.xml index 0cf043e..589a438 100644 --- a/src/notification-item.xml +++ b/src/notification-item.xml @@ -27,6 +27,9 @@ <arg type="i" name="x" direction="in" /> <arg type="i" name="y" direction="in" /> </method> + <method name="XAyatanaSecondaryActivate"> + <arg type="u" name="timestamp" direction="in" /> + </method> <!-- Signals --> <signal name="NewIcon"> |