[gnome-shell/wip/gtkmenutrackeritem: 24/32] shell-app: Expose the muxer directly
- From: Jasper St. Pierre <jstpierre src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gnome-shell/wip/gtkmenutrackeritem: 24/32] shell-app: Expose the muxer directly
- Date: Mon, 13 May 2013 20:07:11 +0000 (UTC)
commit bf6302dcc2d1620d929628758e50c577fb41527c
Author: Jasper St. Pierre <jstpierre mecheye net>
Date: Thu May 9 15:44:26 2013 -0400
shell-app: Expose the muxer directly
Now that this is introspectable, export the variable as this type
directly. This will be necesssary when we port over to the newer
GtkMenuTracker.
js/ui/panel.js | 6 +++---
src/shell-app.c | 21 ++++++++++-----------
2 files changed, 13 insertions(+), 14 deletions(-)
---
diff --git a/js/ui/panel.js b/js/ui/panel.js
index 1aa2d8c..d086c50 100644
--- a/js/ui/panel.js
+++ b/js/ui/panel.js
@@ -620,12 +620,12 @@ const AppMenuButton = new Lang.Class({
_maybeSetMenu: function() {
let menu;
- if (this._targetApp.action_group && this._targetApp.menu) {
+ if (this._targetApp.action_muxer && this._targetApp.menu) {
if (this.menu instanceof PopupMenu.RemoteMenu &&
- this.menu.actionGroup == this._targetApp.action_group)
+ this.menu.actionGroup == this._targetApp.action_muxer)
return;
- menu = new PopupMenu.RemoteMenu(this.actor, this._targetApp.menu, this._targetApp.action_group);
+ menu = new PopupMenu.RemoteMenu(this.actor, this._targetApp.menu, this._targetApp.action_muxer);
menu.connect('activate', Lang.bind(this, function() {
let win = this._targetApp.get_windows()[0];
win.check_alive(global.get_current_time());
diff --git a/src/shell-app.c b/src/shell-app.c
index 6afa56a..fcdcfe4 100644
--- a/src/shell-app.c
+++ b/src/shell-app.c
@@ -88,7 +88,7 @@ enum {
PROP_STATE,
PROP_ID,
PROP_DBUS_ID,
- PROP_ACTION_GROUP,
+ PROP_ACTION_MUXER,
PROP_MENU
};
@@ -120,7 +120,7 @@ shell_app_get_property (GObject *gobject,
case PROP_ID:
g_value_set_string (value, shell_app_get_id (app));
break;
- case PROP_ACTION_GROUP:
+ case PROP_ACTION_MUXER:
if (app->running_state)
g_value_set_object (value, app->running_state->muxer);
break;
@@ -568,7 +568,7 @@ shell_app_update_window_actions (ShellApp *app, MetaWindow *window)
app->running_state->muxer = gtk_action_muxer_new ();
gtk_action_muxer_insert (app->running_state->muxer, "win", actions);
- g_object_notify (G_OBJECT (app), "action-group");
+ g_object_notify (G_OBJECT (app), "action-muxer");
}
}
@@ -1656,17 +1656,16 @@ shell_app_class_init(ShellAppClass *klass)
G_PARAM_READABLE | G_PARAM_STATIC_STRINGS));
/**
- * ShellApp:action-group:
+ * ShellApp:action-muxer:
*
- * The #GDBusActionGroup associated with this ShellApp, if any. See the
- * documentation of #GApplication and #GActionGroup for details.
+ * The #GtkActionMuxer associated with this ShellApp, if any.
*/
g_object_class_install_property (gobject_class,
- PROP_ACTION_GROUP,
- g_param_spec_object ("action-group",
- "Application Action Group",
- "The action group exported by the remote
application",
- G_TYPE_ACTION_GROUP,
+ PROP_ACTION_MUXER,
+ g_param_spec_object ("action-muxer",
+ "Application Action Muxer",
+ "",
+ GTK_TYPE_ACTION_MUXER,
G_PARAM_READABLE | G_PARAM_STATIC_STRINGS));
/**
* ShellApp:menu:
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]