aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorTed Gould <ted@gould.cx>2013-08-21 20:46:47 -0500
committerTed Gould <ted@gould.cx>2013-08-21 20:46:47 -0500
commit027a06e9d59885a8f961ff83987b338c7c33755f (patch)
tree5e459759524c32918fcf09847c3ce0f1d6c1bb8e /src
parentff533d23778b9799765bfed600b676dc30a934db (diff)
downloadayatana-indicator-messages-027a06e9d59885a8f961ff83987b338c7c33755f.tar.gz
ayatana-indicator-messages-027a06e9d59885a8f961ff83987b338c7c33755f.tar.bz2
ayatana-indicator-messages-027a06e9d59885a8f961ff83987b338c7c33755f.zip
Swap g_simple_action_group_insert() for g_action_map_add_action()
Diffstat (limited to 'src')
-rw-r--r--src/app-section.c8
-rw-r--r--src/im-application-list.c10
2 files changed, 9 insertions, 9 deletions
diff --git a/src/app-section.c b/src/app-section.c
index aad994d..6f955e7 100644
--- a/src/app-section.c
+++ b/src/app-section.c
@@ -406,7 +406,7 @@ app_section_update_menu (AppSection *self)
launch = g_simple_action_new_stateful ("launch", G_VARIANT_TYPE_UINT32, g_variant_new_boolean (is_running));
g_signal_connect (launch, "activate", G_CALLBACK (activate_cb), self);
g_signal_connect (launch, "change-state", G_CALLBACK (launch_action_change_state), self);
- g_simple_action_group_insert (priv->static_shortcuts, G_ACTION (launch));
+ g_action_map_add_action (G_ACTION_MAP(priv->static_shortcuts), G_ACTION (launch));
item = g_menu_item_new (g_app_info_get_name (G_APP_INFO (priv->appinfo)), "launch");
g_menu_item_set_attribute (item, "x-canonical-type", "s", "ImAppMenuItem");
@@ -432,7 +432,7 @@ app_section_update_menu (AppSection *self)
action = g_simple_action_new (nicks[i], G_VARIANT_TYPE_UINT32);
g_signal_connect(action, "activate", G_CALLBACK (nick_activate_cb), self);
- g_simple_action_group_insert (priv->static_shortcuts, G_ACTION (action));
+ g_action_map_add_action (G_ACTION_MAP(priv->static_shortcuts), G_ACTION (action));
g_object_unref (action);
item = g_menu_item_new (name, nicks[i]);
@@ -722,7 +722,7 @@ sources_listed (GObject *source_object,
state = g_variant_new ("(uxsb)", count, time, string, draws_attention);
action = g_simple_action_new_stateful (id, NULL, state);
g_signal_connect (action, "activate", G_CALLBACK (source_action_activated), self);
- g_simple_action_group_insert (priv->source_actions, G_ACTION (action));
+ g_action_map_add_action (G_ACTION_MAP(priv->source_actions), G_ACTION (action));
item = g_menu_item_new (label, id);
g_menu_item_set_attribute (item, "x-canonical-type", "s", "ImSourceMenuItem");
@@ -760,7 +760,7 @@ source_added (IndicatorMessagesApplication *app,
state = g_variant_new ("(uxsb)", count, time, string, draws_attention);
action = g_simple_action_new_stateful (id, NULL, state);
- g_simple_action_group_insert (priv->source_actions, G_ACTION (action));
+ g_action_map_add_action (G_ACTION_MAP(priv->source_actions), G_ACTION (action));
if (draws_attention && !priv->draws_attention) {
priv->draws_attention = TRUE;
diff --git a/src/im-application-list.c b/src/im-application-list.c
index 684a2e4..755168a 100644
--- a/src/im-application-list.c
+++ b/src/im-application-list.c
@@ -575,13 +575,13 @@ im_application_list_init (ImApplicationList *list)
list->globalactions = g_simple_action_group_new ();
{
GSimpleAction * messages = g_simple_action_new_stateful("messages", G_VARIANT_TYPE("a{sv}"), g_variant_new_array(G_VARIANT_TYPE("{sv}"), NULL, 0));
- g_simple_action_group_insert(list->globalactions, G_ACTION(messages));
+ g_action_map_add_action(G_ACTION_MAP(list->globalactions), G_ACTION(messages));
}
g_simple_action_group_add_entries (list->globalactions, action_entries, G_N_ELEMENTS (action_entries), list);
list->statusaction = g_simple_action_new_stateful("status", G_VARIANT_TYPE_STRING, g_variant_new_string("offline"));
g_signal_connect(list->statusaction, "activate", G_CALLBACK(status_activated), list);
- g_simple_action_group_insert(list->globalactions, G_ACTION(list->statusaction));
+ g_action_map_add_action(G_ACTION_MAP(list->globalactions), G_ACTION(list->statusaction));
list->muxer = g_action_muxer_new ();
g_action_muxer_insert (list->muxer, NULL, G_ACTION_GROUP (list->globalactions));
@@ -780,7 +780,7 @@ im_application_list_source_added (Application *app,
action = g_simple_action_new_stateful (id, G_VARIANT_TYPE_BOOLEAN, state);
g_signal_connect (action, "activate", G_CALLBACK (im_application_list_source_activated), app);
- g_simple_action_group_insert (app->source_actions, G_ACTION (action));
+ g_action_map_add_action (G_ACTION_MAP(app->source_actions), G_ACTION (action));
g_signal_emit (app->list, signals[SOURCE_ADDED], 0, app->id, id, label, iconstr);
@@ -906,7 +906,7 @@ im_application_list_message_added (Application *app,
action = g_simple_action_new (id, G_VARIANT_TYPE_BOOLEAN);
g_object_set_qdata(G_OBJECT(action), message_action_draws_attention_quark(), GINT_TO_POINTER(draws_attention));
g_signal_connect (action, "activate", G_CALLBACK (im_application_list_message_activated), app);
- g_simple_action_group_insert (app->message_actions, G_ACTION (action));
+ g_action_map_add_action (G_ACTION_MAP(app->message_actions), G_ACTION (action));
{
GVariant *entry;
@@ -939,7 +939,7 @@ im_application_list_message_added (Application *app,
action = g_simple_action_new (name, type ? G_VARIANT_TYPE (type) : NULL);
g_object_set_data_full (G_OBJECT (action), "message", g_strdup (id), g_free);
g_signal_connect (action, "activate", G_CALLBACK (im_application_list_sub_message_activated), app);
- g_simple_action_group_insert (action_group, G_ACTION (action));
+ g_action_map_add_action (G_ACTION_MAP(action_group), G_ACTION (action));
g_variant_builder_init (&dict_builder, G_VARIANT_TYPE ("a{sv}"));