Mercurial > pidgin
changeset 20597:591267f6f1d5
propagate from branch 'im.pidgin.pidgin' (head 025faf23aaac403798451974c320c4de6df470d5)
to branch 'org.maemo.garage.pidgin.pidgin.dialog-transience' (head bab8f4f115d13e3eb53165748f147eae91ee250d)
line wrap: on
line diff
--- a/finch/gntaccount.c Fri Sep 21 16:09:12 2007 +0000 +++ b/finch/gntaccount.c Sat Sep 22 09:48:07 2007 +0000 @@ -633,7 +633,7 @@ purple_account_get_username(account)); purple_request_action(account, _("Delete Account"), prompt, NULL, 0, - account, NULL, NULL, account, 2, + account, NULL, NULL, "accounts", account, 2, _("Delete"), really_delete_account, _("Cancel"), NULL); g_free(prompt); @@ -884,7 +884,7 @@ purple_request_action(NULL, NULL, _("Add buddy to your list?"), buffer, PURPLE_DEFAULT_ACTION_NONE, account, remote_user, NULL, - data, 2, + "blist", data, 2, _("Add"), G_CALLBACK(add_user_cb), _("Cancel"), G_CALLBACK(free_add_user_data)); g_free(buffer); @@ -972,7 +972,7 @@ widget = purple_request_action(NULL, _("Authorize buddy?"), buffer, NULL, PURPLE_DEFAULT_ACTION_NONE, account, remote_user, NULL, - aa, 2, + "blist", aa, 2, _("Authorize"), authorize_and_add_cb, _("Deny"), deny_no_add_cb); gnt_screen_release(widget); @@ -999,7 +999,7 @@ uihandle = purple_request_action(NULL, _("Authorize buddy?"), buffer, NULL, PURPLE_DEFAULT_ACTION_NONE, account, remote_user, NULL, - user_data, 2, + "blist", user_data, 2, _("Authorize"), auth_cb, _("Deny"), deny_cb); }
--- a/finch/gntblist.c Fri Sep 21 16:09:12 2007 +0000 +++ b/finch/gntblist.c Sat Sep 22 09:48:07 2007 +0000 @@ -343,7 +343,7 @@ _("Add"), G_CALLBACK(add_buddy_cb), _("Cancel"), NULL, account, NULL, NULL, - NULL); + "blist", NULL); } static void @@ -420,7 +420,7 @@ _("You can edit more information from the context menu later."), fields, _("Add"), G_CALLBACK(add_chat_cb), _("Cancel"), NULL, NULL, NULL, NULL, - NULL); + "blist", NULL); } static void @@ -455,7 +455,7 @@ NULL, FALSE, FALSE, NULL, _("Add"), G_CALLBACK(add_group_cb), _("Cancel"), NULL, NULL, NULL, NULL, - NULL); + "blist", NULL); } static PurpleBlistUiOps blist_ui_ops = @@ -802,7 +802,7 @@ purple_request_fields(NULL, _("Edit Chat"), NULL, _("Please Update the necessary fields."), fields, _("Edit"), G_CALLBACK(chat_components_edit_ok), _("Cancel"), NULL, NULL, NULL, NULL, - chat); + "blist", chat); } static void @@ -1004,7 +1004,7 @@ name, FALSE, FALSE, NULL, text, G_CALLBACK(rename_blist_node), _("Cancel"), NULL, NULL, NULL, NULL, - node); + "blist", node); g_free(prompt); } @@ -1096,7 +1096,7 @@ primary, sec, 1, account, name, NULL, - node, 2, + "blist", node, 2, _("Remove"), finch_blist_remove_node, _("Cancel"), NULL); g_free(primary); @@ -2221,7 +2221,7 @@ _("OK"), G_CALLBACK(send_im_select_cb), _("Cancel"), NULL, NULL, NULL, NULL, - NULL); + "blist", NULL); } static void @@ -2302,7 +2302,14 @@ item = gnt_menuitem_new(_("Add")); gnt_menu_add_item(GNT_MENU(sub), item); + gnt_menuitem_set_callback(GNT_MENU_ITEM(item), sort_blist_change_cb, "status"); + item = gnt_menuitem_new(_("Alphabetically")); + gnt_menu_add_item(GNT_MENU(subsub), item); + gnt_menuitem_set_callback(GNT_MENU_ITEM(item), sort_blist_change_cb, "text"); + + item = gnt_menuitem_new(_("Sort by log size")); + gnt_menu_add_item(GNT_MENU(sub), item); subsub = gnt_menu_new(GNT_MENU_POPUP); gnt_menuitem_set_submenu(item, GNT_MENU(subsub));
--- a/finch/gntcertmgr.c Fri Sep 21 16:09:12 2007 +0000 +++ b/finch/gntcertmgr.c Sat Sep 22 09:48:07 2007 +0000 @@ -90,7 +90,7 @@ _("OK"), G_CALLBACK(tls_peers_mgmt_import_ok2_cb), _("Cancel"), G_CALLBACK(tls_peers_mgmt_import_cancel2_cb), NULL, NULL, NULL, - crt); + "certmgr", crt); g_free(default_hostname); } else { gchar * secondary; @@ -112,7 +112,7 @@ FALSE, G_CALLBACK(tls_peers_mgmt_import_ok_cb), NULL, - NULL, NULL, NULL, NULL ); + NULL, NULL, NULL, "certmgr", NULL ); } /* Save certs in some file */ @@ -161,7 +161,7 @@ G_CALLBACK(tls_peers_mgmt_export_ok_cb), G_CALLBACK(purple_certificate_destroy), NULL, NULL, NULL, - crt); + "certmgr", crt); } /* Show information about a cert */ @@ -236,7 +236,7 @@ purple_request_yes_no((void *)key, _("Confirm certificate delete"), primary, NULL, 2, - NULL, NULL, NULL, + NULL, NULL, NULL, "certmgr", g_strdup(key), tls_peers_mgmt_delete_confirm_cb, g_free);
--- a/finch/gntconn.c Fri Sep 21 16:09:12 2007 +0000 +++ b/finch/gntconn.c Sat Sep 22 09:48:07 2007 +0000 @@ -132,7 +132,7 @@ purple_request_action(account, NULL, primary, secondary, 2, account, NULL, NULL, - account, 3, + "blist", account, 3, _("OK"), NULL, _("Modify Account"), PURPLE_CALLBACK(ce_modify_account_cb), _("Re-enable Account"), PURPLE_CALLBACK(ce_enable_account_cb));
--- a/finch/gntplugin.c Fri Sep 21 16:09:12 2007 +0000 +++ b/finch/gntplugin.c Sat Sep 22 09:48:07 2007 +0000 @@ -378,6 +378,6 @@ return purple_request_fields(NULL, _("Preferences"), NULL, NULL, fields, _("Save"), G_CALLBACK(finch_request_save_in_prefs), _("Cancel"), NULL, NULL, NULL, NULL, - NULL); + "plugins", NULL); }
--- a/finch/gntpounce.c Fri Sep 21 16:09:12 2007 +0000 +++ b/finch/gntpounce.c Sat Sep 22 09:48:07 2007 +0000 @@ -662,7 +662,7 @@ buf = g_strdup_printf(_("Are you sure you want to delete the pounce on %s for %s?"), pouncee, pouncer); purple_request_action(pounce, NULL, buf, NULL, 0, account, pouncee, NULL, - pounce, 2, + "pounces", pounce, 2, _("Delete"), pounces_manager_delete_confirm_cb, _("Cancel"), NULL); g_free(buf);
--- a/finch/gntprefs.c Fri Sep 21 16:09:12 2007 +0000 +++ b/finch/gntprefs.c Sat Sep 22 09:48:07 2007 +0000 @@ -264,6 +264,6 @@ pref_request.window = purple_request_fields(NULL, _("Preferences"), NULL, NULL, fields, _("Save"), G_CALLBACK(save_cb), _("Cancel"), free_strings, NULL, NULL, NULL, - NULL); + "preferences", NULL); }
--- a/finch/gntrequest.c Fri Sep 21 16:09:12 2007 +0000 +++ b/finch/gntrequest.c Sat Sep 22 09:48:07 2007 +0000 @@ -146,7 +146,7 @@ const char *ok_text, GCallback ok_cb, const char *cancel_text, GCallback cancel_cb, PurpleAccount *account, const char *who, PurpleConversation *conv, - void *user_data) + const char *ui_hint, void *user_data) { GntWidget *window, *box, *entry; @@ -203,7 +203,7 @@ const char *ok_text, GCallback ok_cb, const char *cancel_text, GCallback cancel_cb, PurpleAccount *account, const char *who, PurpleConversation *conv, - void *user_data, va_list choices) + const char *ui_hint, void *user_data, va_list choices) { GntWidget *window, *combo, *box; const char *text; @@ -247,7 +247,7 @@ finch_request_action(const char *title, const char *primary, const char *secondary, int default_value, PurpleAccount *account, const char *who, PurpleConversation *conv, - void *user_data, size_t actioncount, + const char *ui_hint, void *user_data, size_t actioncount, va_list actions) { GntWidget *window, *box, *button; @@ -391,7 +391,7 @@ const char *ok, GCallback ok_cb, const char *cancel, GCallback cancel_cb, PurpleAccount *account, const char *who, PurpleConversation *conv, - void *userdata) + const char *ui_hint, void *userdata) { GntWidget *window, *box; GList *grlist; @@ -643,7 +643,7 @@ gboolean savedialog, GCallback ok_cb, GCallback cancel_cb, PurpleAccount *account, const char *who, PurpleConversation *conv, - void *user_data) + const char *ui_hint, void *user_data) { GntWidget *window = gnt_file_sel_new(); GntFileSel *sel = GNT_FILE_SEL(window);
--- a/finch/gntstatus.c Fri Sep 21 16:09:12 2007 +0000 +++ b/finch/gntstatus.c Sat Sep 22 09:48:07 2007 +0000 @@ -140,7 +140,7 @@ purple_request_action(saved, _("Delete Status"), ask, NULL, 0, NULL, NULL, NULL, - saved, 2, + "statuses", saved, 2, _("Delete"), really_delete_status, _("Cancel"), NULL); g_free(ask);
--- a/libpurple/account.c Fri Sep 21 16:09:12 2007 +0000 +++ b/libpurple/account.c Sat Sep 22 09:48:07 2007 +0000 @@ -1012,7 +1012,7 @@ _("OK"), ok_cb, _("Cancel"), cancel_cb, account, NULL, NULL, - user_data); + "account", user_data); g_free(primary); } @@ -1262,7 +1262,7 @@ _("OK"), G_CALLBACK(change_password_cb), _("Cancel"), NULL, account, NULL, NULL, - account); + "account", account); } static void @@ -1297,7 +1297,7 @@ _("Save"), G_CALLBACK(set_user_info_cb), _("Cancel"), NULL, account, NULL, NULL, - account); + "account", account); } void
--- a/libpurple/certificate.c Fri Sep 21 16:09:12 2007 +0000 +++ b/libpurple/certificate.c Sat Sep 22 09:48:07 2007 +0000 @@ -559,6 +559,7 @@ NULL, /* No account */ NULL, /* No other user */ NULL, /* No associated conversation */ + "blist", vrq, x509_singleuse_verify_cb, x509_singleuse_verify_cb ); @@ -1181,6 +1182,7 @@ NULL, /* No account */ NULL, /* No other user */ NULL, /* No associated conversation */ + "blist", x509_tls_cached_ua_ctx_new(vrq, reason), 3, /* Number of actions */ _("Accept"), x509_tls_cached_user_auth_accept_cb,
--- a/libpurple/conversation.c Fri Sep 21 16:09:12 2007 +0000 +++ b/libpurple/conversation.c Sat Sep 22 09:48:07 2007 +0000 @@ -1210,7 +1210,7 @@ purple_request_action(conv, NULL, _("Send Message"), text, 0, purple_conversation_get_account(conv), NULL, conv, - data, 2, + "conversation", data, 2, _("_Send Message"), G_CALLBACK(purple_conv_send_confirm_cb), _("Cancel"), NULL); }
--- a/libpurple/ft.c Fri Sep 21 16:09:12 2007 +0000 +++ b/libpurple/ft.c Sat Sep 22 09:48:07 2007 +0000 @@ -314,7 +314,7 @@ G_CALLBACK(purple_xfer_choose_file_ok_cb), G_CALLBACK(purple_xfer_choose_file_cancel_cb), purple_xfer_get_account(xfer), xfer->who, NULL, - xfer); + "xfer", xfer); return 0; } @@ -362,7 +362,7 @@ purple_request_accept_cancel(xfer, NULL, buf, NULL, PURPLE_DEFAULT_ACTION_NONE, xfer->account, xfer->who, NULL, - xfer, + "xfer", xfer, G_CALLBACK(purple_xfer_choose_file), G_CALLBACK(cancel_recv_cb)); @@ -405,7 +405,7 @@ purple_request_accept_cancel(xfer, NULL, buf, buf2, PURPLE_DEFAULT_ACTION_NONE, xfer->account, xfer->who, NULL, - xfer, + "xfer", xfer, G_CALLBACK(ask_accept_ok), G_CALLBACK(ask_accept_cancel)); g_free(buf);
--- a/libpurple/plugins/autoaccept.c Fri Sep 21 16:09:12 2007 +0000 +++ b/libpurple/plugins/autoaccept.c Sat Sep 22 09:48:07 2007 +0000 @@ -164,7 +164,7 @@ _("_Save"), G_CALLBACK(save_cb), _("_Cancel"), NULL, NULL, NULL, NULL, - node, + "xfer", node, _("Ask"), FT_ASK, _("Auto Accept"), FT_ACCEPT, _("Auto Reject"), FT_REJECT,
--- a/libpurple/plugins/buddynote.c Fri Sep 21 16:09:12 2007 +0000 +++ b/libpurple/plugins/buddynote.c Sat Sep 22 09:48:07 2007 +0000 @@ -50,7 +50,7 @@ _("Save"), G_CALLBACK(do_it_cb), _("Cancel"), G_CALLBACK(dont_do_it_cb), NULL, NULL, NULL, - node); + "buddy", node); } static void
--- a/libpurple/plugins/idle.c Fri Sep 21 16:09:12 2007 +0000 +++ b/libpurple/plugins/idle.c Sat Sep 22 09:48:07 2007 +0000 @@ -169,7 +169,7 @@ _("_Set"), G_CALLBACK(idle_action_ok), _("_Cancel"), NULL, NULL, NULL, NULL, - NULL); + "account", NULL); } static void @@ -203,7 +203,7 @@ _("_Unset"), G_CALLBACK(unidle_action_ok), _("_Cancel"), NULL, NULL, NULL, NULL, - NULL); + "account", NULL); } static void @@ -229,7 +229,7 @@ _("_Set"), G_CALLBACK(idle_all_action_ok), _("_Cancel"), NULL, NULL, NULL, NULL, - NULL); + "account", NULL); } static void
--- a/libpurple/plugins/offlinemsg.c Fri Sep 21 16:09:12 2007 +0000 +++ b/libpurple/plugins/offlinemsg.c Sat Sep 22 09:48:07 2007 +0000 @@ -161,7 +161,7 @@ _("You can edit/delete the pounce from the `Buddy Pounces' dialog"), 1, offline->account, offline->who, offline->conv, - offline, 2, + "buddy", offline, 2, _("Yes"), record_pounce, _("No"), cancel_poune); g_free(ask);
--- a/libpurple/plugins/perl/common/Request.xs Fri Sep 21 16:09:12 2007 +0000 +++ b/libpurple/plugins/perl/common/Request.xs Sat Sep 22 09:48:07 2007 +0000 @@ -2,12 +2,13 @@ /* This breaks on faceprint's amd64 box void * -purple_request_action_varg(handle, title, primary, secondary, default_action, user_data, action_count, actions) +purple_request_action_varg(handle, title, primary, secondary, default_action, ui_hint, user_data, action_count, actions) void * handle const char *title const char *primary const char *secondary unsigned int default_action + const char * ui_hint void *user_data size_t action_count va_list actions @@ -116,7 +117,7 @@ } void * -purple_request_input(handle, title, primary, secondary, default_value, multiline, masked, hint, ok_text, ok_cb, cancel_text, cancel_cb) +purple_request_input(handle, title, primary, secondary, default_value, multiline, masked, hint, ok_text, ok_cb, cancel_text, cancel_cb, ui_hint) Purple::Plugin handle const char * title const char * primary @@ -129,6 +130,7 @@ SV * ok_cb const char * cancel_text SV * cancel_cb + const char * ui_hint CODE: PurplePerlRequestData *gpr; STRLEN len; @@ -141,18 +143,19 @@ gpr->cancel_cb = g_strdup_printf("Purple::Script::%s::%s", basename, SvPV(cancel_cb, len)); g_free(basename); - RETVAL = purple_request_input(handle, title, primary, secondary, default_value, multiline, masked, hint, ok_text, G_CALLBACK(purple_perl_request_ok_cb), cancel_text, G_CALLBACK(purple_perl_request_cancel_cb), NULL, NULL, NULL, gpr); + RETVAL = purple_request_input(handle, title, primary, secondary, default_value, multiline, masked, hint, ok_text, G_CALLBACK(purple_perl_request_ok_cb), cancel_text, G_CALLBACK(purple_perl_request_cancel_cb), NULL, NULL, NULL, ui_hint, gpr); OUTPUT: RETVAL void * -purple_request_file(handle, title, filename, savedialog, ok_cb, cancel_cb) +purple_request_file(handle, title, filename, savedialog, ok_cb, cancel_cb, ui_hint) Purple::Plugin handle const char * title const char * filename gboolean savedialog SV * ok_cb SV * cancel_cb + const char * ui_hint CODE: PurplePerlRequestData *gpr; STRLEN len; @@ -165,12 +168,12 @@ gpr->cancel_cb = g_strdup_printf("Purple::Script::%s::%s", basename, SvPV(cancel_cb, len)); g_free(basename); - RETVAL = purple_request_file(handle, title, filename, savedialog, G_CALLBACK(purple_perl_request_ok_cb), G_CALLBACK(purple_perl_request_cancel_cb), NULL, NULL, NULL, gpr); + RETVAL = purple_request_file(handle, title, filename, savedialog, G_CALLBACK(purple_perl_request_ok_cb), G_CALLBACK(purple_perl_request_cancel_cb), NULL, NULL, NULL, ui_hint, gpr); OUTPUT: RETVAL void * -purple_request_fields(handle, title, primary, secondary, fields, ok_text, ok_cb, cancel_text, cancel_cb) +purple_request_fields(handle, title, primary, secondary, fields, ok_text, ok_cb, cancel_text, cancel_cb, ui_hint) Purple::Plugin handle const char * title const char * primary @@ -180,6 +183,7 @@ SV * ok_cb const char * cancel_text SV * cancel_cb + const char *ui_hint CODE: PurplePerlRequestData *gpr; STRLEN len; @@ -192,7 +196,7 @@ gpr->cancel_cb = g_strdup_printf("Purple::Script::%s::%s", basename, SvPV(cancel_cb, len)); g_free(basename); - RETVAL = purple_request_fields(handle, title, primary, secondary, fields, ok_text, G_CALLBACK(purple_perl_request_ok_cb), cancel_text, G_CALLBACK(purple_perl_request_cancel_cb), NULL, NULL, NULL, gpr); + RETVAL = purple_request_fields(handle, title, primary, secondary, fields, ok_text, G_CALLBACK(purple_perl_request_ok_cb), cancel_text, G_CALLBACK(purple_perl_request_cancel_cb), NULL, NULL, NULL, ui_hint, gpr); OUTPUT: RETVAL
--- a/libpurple/protocols/gg/gg.c Fri Sep 21 16:09:12 2007 +0000 +++ b/libpurple/protocols/gg/gg.c Sat Sep 22 09:48:07 2007 +0000 @@ -336,7 +336,7 @@ purple_request_file(action, _("Save buddylist..."), NULL, TRUE, G_CALLBACK(ggp_callback_buddylist_save_ok), NULL, purple_connection_get_account(gc), NULL, NULL, - gc); + "blist", gc); } /* }}} */ @@ -350,7 +350,7 @@ purple_request_file(action, "Load buddylist from file...", NULL, FALSE, G_CALLBACK(ggp_callback_buddylist_load_ok), NULL, purple_connection_get_account(gc), NULL, NULL, - gc); + "blist", gc); } /* }}} */ @@ -506,7 +506,7 @@ _("OK"), G_CALLBACK(ggp_callback_register_account_ok), _("Cancel"), G_CALLBACK(ggp_callback_register_account_cancel), purple_connection_get_account(gc), NULL, NULL, - gc); + "register-account", gc); } /* }}} */ @@ -665,7 +665,7 @@ _("OK"), G_CALLBACK(ggp_callback_find_buddies), _("Cancel"), NULL, purple_connection_get_account(gc), NULL, NULL, - gc); + "blist", gc); } /* }}} */ @@ -802,7 +802,7 @@ fields, _("OK"), G_CALLBACK(ggp_callback_change_passwd_ok), _("Cancel"), NULL, purple_connection_get_account(gc), NULL, NULL, - gc); + "account", gc); g_free(msg); } @@ -883,7 +883,7 @@ _("Add"), G_CALLBACK(ggp_callback_add_to_chat_ok), _("Cancel"), NULL, purple_connection_get_account(gc), NULL, NULL, - gc); + "buddy", gc); g_free(msg); } /* }}} */
--- a/libpurple/protocols/jabber/auth.c Fri Sep 21 16:09:12 2007 +0000 +++ b/libpurple/protocols/jabber/auth.c Sat Sep 22 09:48:07 2007 +0000 @@ -321,7 +321,7 @@ purple_request_yes_no(js->gc, _("Plaintext Authentication"), _("Plaintext Authentication"), msg, - 2, js->gc->account, NULL, NULL, js->gc->account, + 2, js->gc->account, NULL, NULL, "account", js->gc->account, allow_cyrus_plaintext_auth, disallow_plaintext_auth); g_free(msg); @@ -512,8 +512,8 @@ msg, 2, purple_connection_get_account(js->gc), NULL, NULL, - purple_connection_get_account(js->gc), allow_plaintext_auth, - disallow_plaintext_auth); + "account", purple_connection_get_account(js->gc), + allow_plaintext_auth, disallow_plaintext_auth); g_free(msg); return; } @@ -600,8 +600,8 @@ _("This server requires plaintext authentication over an unencrypted connection. Allow this and continue authentication?"), 2, purple_connection_get_account(js->gc), NULL, NULL, - purple_connection_get_account(js->gc), allow_plaintext_auth, - disallow_plaintext_auth); + "account", purple_connection_get_account(js->gc), + allow_plaintext_auth, disallow_plaintext_auth); return; } finish_plaintext_authentication(js);
--- a/libpurple/protocols/jabber/buddy.c Fri Sep 21 16:09:12 2007 +0000 +++ b/libpurple/protocols/jabber/buddy.c Sat Sep 22 09:48:07 2007 +0000 @@ -727,7 +727,7 @@ _("Save"), G_CALLBACK(jabber_format_info), _("Cancel"), NULL, purple_connection_get_account(gc), NULL, NULL, - gc); + "account", gc); } /*---------------------------------------*/ @@ -2415,7 +2415,7 @@ _("Search"), G_CALLBACK(user_search_cb), _("Cancel"), G_CALLBACK(user_search_cancel_cb), purple_connection_get_account(js->gc), NULL, NULL, - usi); + "account", usi); g_free(instructions); } @@ -2451,7 +2451,7 @@ _("Search Directory"), PURPLE_CALLBACK(jabber_user_search), _("Cancel"), NULL, NULL, NULL, NULL, - js); + "account", js); }
--- a/libpurple/protocols/jabber/chat.c Fri Sep 21 16:09:12 2007 +0000 +++ b/libpurple/protocols/jabber/chat.c Sat Sep 22 09:48:07 2007 +0000 @@ -785,7 +785,7 @@ _("Find Rooms"), PURPLE_CALLBACK(roomlist_ok_cb), _("Cancel"), PURPLE_CALLBACK(roomlist_cancel_cb), purple_connection_get_account(gc), NULL, NULL, - js); + "chat", js); return js->roomlist; }
--- a/libpurple/protocols/jabber/jabber.c Fri Sep 21 16:09:12 2007 +0000 +++ b/libpurple/protocols/jabber/jabber.c Sat Sep 22 09:48:07 2007 +0000 @@ -1007,7 +1007,7 @@ _("Register"), G_CALLBACK(jabber_register_cb), _("Cancel"), G_CALLBACK(jabber_register_cancel_cb), purple_connection_get_account(js->gc), NULL, NULL, - cbdata); + "register-account", cbdata); else { char *title = registered?g_strdup_printf(_("Change Account Registration at %s"), from) :g_strdup_printf(_("Register New Account at %s"), from); @@ -1736,7 +1736,7 @@ fields, _("OK"), G_CALLBACK(jabber_password_change_cb), _("Cancel"), NULL, purple_connection_get_account(gc), NULL, NULL, - js); + "account", js); } GList *jabber_actions(PurplePlugin *plugin, gpointer context)
--- a/libpurple/protocols/jabber/presence.c Fri Sep 21 16:09:12 2007 +0000 +++ b/libpurple/protocols/jabber/presence.c Sat Sep 22 09:48:07 2007 +0000 @@ -507,7 +507,7 @@ " accept the default settings?"), /* Default Action */ 1, purple_connection_get_account(js->gc), NULL, chat->conv, - chat, 2, + "chat", chat, 2, _("_Configure Room"), G_CALLBACK(jabber_chat_request_room_configure), _("_Accept Defaults"), G_CALLBACK(jabber_chat_create_instant_room)); }
--- a/libpurple/protocols/jabber/si.c Fri Sep 21 16:09:12 2007 +0000 +++ b/libpurple/protocols/jabber/si.c Sat Sep 22 09:48:07 2007 +0000 @@ -872,7 +872,7 @@ purple_request_fields(jsx->js->gc, _("Select a Resource"), msg, NULL, fields, _("Send File"), G_CALLBACK(resource_select_ok_cb), _("Cancel"), G_CALLBACK(resource_select_cancel_cb), - jsx->js->gc->account, xfer->who, NULL, xfer); + jsx->js->gc->account, xfer->who, NULL, "xfer", xfer); g_free(msg); }
--- a/libpurple/protocols/jabber/usermood.c Fri Sep 21 16:09:12 2007 +0000 +++ b/libpurple/protocols/jabber/usermood.c Sat Sep 22 09:48:07 2007 +0000 @@ -183,7 +183,7 @@ _("Set"), G_CALLBACK(do_mood_set_from_fields), _("Cancel"), NULL, purple_connection_get_account(gc), NULL, NULL, - gc); + "blist", gc); }
--- a/libpurple/protocols/jabber/xdata.c Fri Sep 21 16:09:12 2007 +0000 +++ b/libpurple/protocols/jabber/xdata.c Sat Sep 22 09:48:07 2007 +0000 @@ -399,7 +399,7 @@ _("OK"), G_CALLBACK(jabber_x_data_ok_cb), _("Cancel"), G_CALLBACK(jabber_x_data_cancel_cb), purple_connection_get_account(js->gc), /* XXX Do we have a who here? */ NULL, NULL, - data); + "account", data); g_free(title); g_free(instructions);
--- a/libpurple/protocols/msn/dialog.c Fri Sep 21 16:09:12 2007 +0000 +++ b/libpurple/protocols/msn/dialog.c Sat Sep 22 09:48:07 2007 +0000 @@ -137,7 +137,7 @@ purple_request_action(gc, NULL, msg, reason, PURPLE_DEFAULT_ACTION_NONE, purple_connection_get_account(gc), data->who, NULL, - data, 2, + "blist", data, 2, _("Yes"), G_CALLBACK(msn_add_cb), _("No"), G_CALLBACK(msn_rem_cb));
--- a/libpurple/protocols/msn/msn.c Fri Sep 21 16:09:12 2007 +0000 +++ b/libpurple/protocols/msn/msn.c Sat Sep 22 09:48:07 2007 +0000 @@ -289,7 +289,7 @@ _("OK"), G_CALLBACK(msn_act_id), _("Cancel"), NULL, purple_connection_get_account(gc), NULL, NULL, - gc); + "account", gc); } static void @@ -306,7 +306,7 @@ _("OK"), G_CALLBACK(msn_set_home_phone_cb), _("Cancel"), NULL, purple_connection_get_account(gc), NULL, NULL, - gc); + "account", gc); } static void @@ -323,7 +323,7 @@ _("OK"), G_CALLBACK(msn_set_work_phone_cb), _("Cancel"), NULL, purple_connection_get_account(gc), NULL, NULL, - gc); + "account", gc); } static void @@ -340,7 +340,7 @@ _("OK"), G_CALLBACK(msn_set_mobile_phone_cb), _("Cancel"), NULL, purple_connection_get_account(gc), NULL, NULL, - gc); + "account", gc); } static void @@ -356,7 +356,7 @@ "to your cell phone or other mobile device?"), -1, purple_connection_get_account(gc), NULL, NULL, - gc, 3, + "account", gc, 3, _("Allow"), G_CALLBACK(enable_msn_pages_cb), _("Disallow"), G_CALLBACK(disable_msn_pages_cb), _("Cancel"), NULL); @@ -405,7 +405,7 @@ _("Page"), G_CALLBACK(send_to_mobile_cb), _("Close"), G_CALLBACK(close_mobile_page_cb), purple_connection_get_account(gc), purple_buddy_get_name(buddy), NULL, - data); + "account", data); } static gboolean
--- a/libpurple/protocols/novell/novell.c Fri Sep 21 16:09:12 2007 +0000 +++ b/libpurple/protocols/novell/novell.c Sat Sep 22 09:48:07 2007 +0000 @@ -1915,7 +1915,7 @@ purple_request_action(gc, title, primary, secondary, PURPLE_DEFAULT_ACTION_NONE, purple_connection_get_account(gc), name, NULL, - parms, 2, + "chat", parms, 2, _("Yes"), G_CALLBACK(_join_conference_cb), _("No"), G_CALLBACK(_reject_conference_cb));
--- a/libpurple/protocols/oscar/oscar.c Fri Sep 21 16:09:12 2007 +0000 +++ b/libpurple/protocols/oscar/oscar.c Sat Sep 22 09:48:07 2007 +0000 @@ -1450,7 +1450,7 @@ _("_OK"), G_CALLBACK(purple_parse_auth_securid_request_yes_cb), _("_Cancel"), G_CALLBACK(purple_parse_auth_securid_request_no_cb), account, NULL, NULL, - gc); + "account", gc); g_free(primary); return 1; @@ -2225,7 +2225,7 @@ _("_OK"), G_CALLBACK(purple_auth_request), _("_Cancel"), G_CALLBACK(purple_auth_dontrequest), purple_connection_get_account(gc), name, NULL, - data); + "blist", data); } @@ -2274,7 +2274,7 @@ _("_OK"), G_CALLBACK(purple_auth_dontgrant), _("_Cancel"), G_CALLBACK(oscar_free_name_data), purple_connection_get_account(data->gc), data->name, NULL, - data); + "blist", data); } /* When someone sends you buddies */ @@ -2460,7 +2460,7 @@ "to your buddy list?"), PURPLE_DEFAULT_ACTION_NONE, purple_connection_get_account(gc), data->name, NULL, - data, 2, + "blist", data, 2, _("_Add"), G_CALLBACK(purple_icq_buddyadd), _("_Decline"), G_CALLBACK(oscar_free_name_data)); g_free(message); @@ -5170,7 +5170,7 @@ purple_request_yes_no(gc, NULL, _("Authorization Given"), dialog_msg, PURPLE_DEFAULT_ACTION_NONE, purple_connection_get_account(gc), sn, NULL, - data, + "blist", data, G_CALLBACK(purple_icq_buddyadd), G_CALLBACK(oscar_free_name_data)); g_free(dialog_msg); @@ -5871,7 +5871,7 @@ _("_OK"), G_CALLBACK(oscar_ssi_editcomment), _("_Cancel"), G_CALLBACK(oscar_free_name_data), purple_connection_get_account(gc), data->name, NULL, - data); + "buddy", data); g_free(title); g_free(comment); @@ -5922,7 +5922,7 @@ "wish to continue?"), 0, purple_connection_get_account(gc), data->who, NULL, - data, 2, + "buddy", data, 2, _("C_onnect"), G_CALLBACK(oscar_ask_directim_yes_cb), _("_Cancel"), G_CALLBACK(oscar_ask_directim_no_cb)); g_free(buf); @@ -6079,7 +6079,7 @@ _("OK"), G_CALLBACK(oscar_icq_privacy_opts), _("Cancel"), NULL, purple_connection_get_account(gc), NULL, NULL, - gc); + "account", gc); } static void oscar_format_screenname(PurpleConnection *gc, const char *nick) { @@ -6152,7 +6152,7 @@ _("_OK"), G_CALLBACK(oscar_change_email), _("_Cancel"), NULL, purple_connection_get_account(gc), NULL, NULL, - gc); + "account", gc); } static void oscar_show_awaitingauth(PurplePluginAction *action) @@ -6222,7 +6222,7 @@ _("_Search"), G_CALLBACK(search_by_email_cb), _("_Cancel"), NULL, purple_connection_get_account(gc), NULL, NULL, - gc); + "buddy", gc); } static void oscar_show_set_info(PurplePluginAction *action)
--- a/libpurple/protocols/oscar/peer.c Fri Sep 21 16:09:12 2007 +0000 +++ b/libpurple/protocols/oscar/peer.c Sat Sep 22 09:48:07 2007 +0000 @@ -1041,7 +1041,7 @@ "risk."), PURPLE_DEFAULT_ACTION_NONE, account, sn, NULL, - conn, 2, + "buddy", conn, 2, _("C_onnect"), G_CALLBACK(peer_connection_got_proposition_yes_cb), _("Cancel"), G_CALLBACK(peer_connection_got_proposition_no_cb)); }
--- a/libpurple/protocols/qq/buddy_info.c Fri Sep 21 16:09:12 2007 +0000 +++ b/libpurple/protocols/qq/buddy_info.c Sat Sep 22 09:48:07 2007 +0000 @@ -483,7 +483,7 @@ _("Update my information"), G_CALLBACK(modify_info_ok_cb), _("Cancel"), G_CALLBACK(modify_info_cancel_cb), purple_connection_get_account(gc), NULL, NULL, - mid); + "account", mid); } }
--- a/libpurple/protocols/qq/buddy_opt.c Fri Sep 21 16:09:12 2007 +0000 +++ b/libpurple/protocols/qq/buddy_opt.c Sat Sep 22 09:48:07 2007 +0000 @@ -213,7 +213,7 @@ _("Sorry, you are not my type..."), TRUE, FALSE, NULL, _("Reject"), G_CALLBACK(_qq_reject_add_request_real), _("Cancel"), NULL, purple_connection_get_account(gc), nombre, NULL, - g2); + "buddy", g2); g_free(nombre); } @@ -410,7 +410,7 @@ (_qq_send_packet_add_buddy_auth_with_gc_and_uid), _("Cancel"), G_CALLBACK(qq_do_nothing_with_gc_and_uid), purple_connection_get_account(gc), nombre, NULL, - g); + "buddy", g); g_free(msg); g_free(nombre); } else { /* add OK */
--- a/libpurple/protocols/qq/group.c Fri Sep 21 16:09:12 2007 +0000 +++ b/libpurple/protocols/qq/group.c Sat Sep 22 09:48:07 2007 +0000 @@ -123,7 +123,7 @@ _("Search"), G_CALLBACK(_qq_group_search_callback), _("Cancel"), G_CALLBACK(_qq_group_search_cancel_callback), purple_connection_get_account(gc), NULL, NULL, - gc); + "chat", gc); return qd->roomlist; }
--- a/libpurple/protocols/qq/group_im.c Fri Sep 21 16:09:12 2007 +0000 +++ b/libpurple/protocols/qq/group_im.c Sat Sep 22 09:48:07 2007 +0000 @@ -137,7 +137,7 @@ msg, reason, 2, purple_connection_get_account(gc), nombre, NULL, - g, 3, + "chat", g, 3, _("Approve"), G_CALLBACK (qq_group_approve_application_with_struct),
--- a/libpurple/protocols/qq/group_join.c Fri Sep 21 16:09:12 2007 +0000 +++ b/libpurple/protocols/qq/group_join.c Sat Sep 22 09:48:07 2007 +0000 @@ -139,7 +139,7 @@ G_CALLBACK(_qq_group_join_auth_with_gc_and_id), _("Cancel"), G_CALLBACK(qq_do_nothing_with_gc_and_uid), purple_connection_get_account(gc), group->group_name_utf8, NULL, - g); + "chat", g); g_free(msg); } @@ -362,7 +362,7 @@ ("Note, if you are the creator, \nthis operation will eventually remove this Qun."), 1, purple_connection_get_account(gc), NULL, NULL, - g, 2, _("Cancel"), + "chat", g, 2, _("Cancel"), G_CALLBACK(qq_do_nothing_with_gc_and_uid), _("Continue"), G_CALLBACK(_qq_group_exit_with_gc_and_id)); }
--- a/libpurple/protocols/qq/group_opt.c Fri Sep 21 16:09:12 2007 +0000 +++ b/libpurple/protocols/qq/group_opt.c Sat Sep 22 09:48:07 2007 +0000 @@ -123,7 +123,7 @@ qq_send_packet_get_info(g->gc, g->member, TRUE); /* we want to see window */ purple_request_action(g->gc, NULL, _("Do you want to approve the request?"), "", 2, purple_connection_get_account(g->gc), NULL, NULL, - g, 2, + "chat", g, 2, _("Reject"), G_CALLBACK(qq_group_reject_application_with_struct), _("Approve"), G_CALLBACK(qq_group_approve_application_with_struct)); } @@ -143,7 +143,7 @@ _("Send"), G_CALLBACK(_qq_group_reject_application_real), _("Cancel"), G_CALLBACK(_qq_group_do_nothing_with_struct), purple_connection_get_account(g->gc), nombre, NULL, - g); + "chat", g); g_free(msg1); g_free(msg2); @@ -394,7 +394,7 @@ ("Would you like to set up the Qun details now?"), 1, purple_connection_get_account(gc), NULL, NULL, - g, 2, + "chat", g, 2, _("Setup"), G_CALLBACK(qq_group_setup_with_gc_and_uid), _("Cancel"), G_CALLBACK(qq_do_nothing_with_gc_and_uid)); }
--- a/libpurple/protocols/qq/sys_msg.c Fri Sep 21 16:09:12 2007 +0000 +++ b/libpurple/protocols/qq/sys_msg.c Sat Sep 22 09:48:07 2007 +0000 @@ -86,7 +86,7 @@ purple_request_action (gc, NULL, _("Do you want to approve the request?"), "", 2, purple_connection_get_account(gc), nombre, NULL, - g, 2, + "chat", g, 2, _("Reject"), G_CALLBACK(qq_reject_add_request_with_gc_and_uid), _("Approve"), G_CALLBACK(qq_approve_add_request_with_gc_and_uid)); g_free(nombre); @@ -109,7 +109,7 @@ purple_request_action (gc, NULL, _("Do you want to add this buddy?"), "", 2, purple_connection_get_account(gc), nombre, NULL, - g, 2, + "buddy", g, 2, _("Cancel"), NULL, _("Add"), G_CALLBACK(qq_add_buddy_with_gc_and_uid)); g_free(nombre); @@ -168,7 +168,7 @@ purple_request_action(gc, NULL, message, _("Would you like to add him?"), 2, purple_connection_get_account(gc), name, NULL, - g, 3, + "buddy", g, 3, _("Cancel"), NULL, _("Add"), G_CALLBACK(qq_add_buddy_with_gc_and_uid), _("Search"), G_CALLBACK(_qq_search_before_add_with_gc_and_uid)); @@ -242,7 +242,7 @@ purple_request_action (gc, NULL, message, reason, 2, purple_connection_get_account(gc), name, NULL, - g, 3, + "buddy", g, 3, _("Reject"), G_CALLBACK(qq_reject_add_request_with_gc_and_uid), _("Approve"), @@ -262,7 +262,7 @@ purple_request_action(gc, NULL, message, _("Would you like to add him?"), 2, purple_connection_get_account(gc), name, NULL, - g2, 3, + "blist", g2, 3, _("Cancel"), NULL, _("Add"), G_CALLBACK(qq_add_buddy_with_gc_and_uid), _("Search"), G_CALLBACK(_qq_search_before_add_with_gc_and_uid));
--- a/libpurple/protocols/sametime/sametime.c Fri Sep 21 16:09:12 2007 +0000 +++ b/libpurple/protocols/sametime/sametime.c Sat Sep 22 09:48:07 2007 +0000 @@ -3387,7 +3387,7 @@ _("Create"), G_CALLBACK(conf_create_prompt_join), _("Cancel"), G_CALLBACK(conf_create_prompt_cancel), acct, purple_buddy_get_name(buddy), NULL, - buddy); + "chat", buddy); g_free(msg1); } @@ -3473,7 +3473,7 @@ _("Invite"), G_CALLBACK(conf_select_prompt_invite), _("Cancel"), G_CALLBACK(conf_select_prompt_cancel), acct, purple_buddy_get_name(buddy), NULL, - buddy); + "chat", buddy); g_free(msg); } @@ -3644,7 +3644,7 @@ _("Connect"), G_CALLBACK(prompt_host_ok_cb), _("Cancel"), G_CALLBACK(prompt_host_cancel_cb), acct, NULL, NULL, - gc); + "account", gc); g_free(msg); } @@ -5218,7 +5218,7 @@ purple_request_file(gc, title, NULL, FALSE, G_CALLBACK(st_import_action_cb), NULL, account, NULL, NULL, - gc); + "blist", gc); g_free(title); } @@ -5258,7 +5258,7 @@ purple_request_file(gc, title, NULL, TRUE, G_CALLBACK(st_export_action_cb), NULL, account, NULL, NULL, - gc); + "blist", gc); g_free(title); } @@ -5396,7 +5396,7 @@ _("Add Group"), G_CALLBACK(remote_group_multi_cb), _("Cancel"), G_CALLBACK(remote_group_multi_cleanup), purple_connection_get_account(gc), result->name, NULL, - pd); + "blist", pd); g_free(msg); } @@ -5486,7 +5486,7 @@ _("Add"), G_CALLBACK(remote_group_action_cb), _("Cancel"), NULL, purple_connection_get_account(gc), NULL, NULL, - gc); + "blist", gc); } @@ -5611,7 +5611,7 @@ _("Search"), G_CALLBACK(search_action_cb), _("Cancel"), NULL, purple_connection_get_account(gc), NULL, NULL, - gc); + "blist", gc); }
--- a/libpurple/protocols/yahoo/yahoo.c Fri Sep 21 16:09:12 2007 +0000 +++ b/libpurple/protocols/yahoo/yahoo.c Sat Sep 22 09:48:07 2007 +0000 @@ -1030,7 +1030,7 @@ _("OK"), G_CALLBACK(yahoo_buddy_add_deny_cb), _("Cancel"), G_CALLBACK(yahoo_buddy_add_deny_noreason_cb), purple_connection_get_account(add_req->gc), add_req->who, NULL, - add_req); + "blist", add_req); } static void yahoo_buddy_denied_our_add(PurpleConnection *gc, const char *who, const char *reason) @@ -2064,7 +2064,7 @@ "will remove and ignore the buddy."), who); purple_request_yes_no(gc, NULL, _("Ignore buddy?"), buf, 0, gc->account, who, NULL, - b, + "blist", b, G_CALLBACK(ignore_buddy), G_CALLBACK(keep_buddy)); break; @@ -3496,18 +3496,18 @@ _("OK"), G_CALLBACK(yahoo_act_id), _("Cancel"), NULL, purple_connection_get_account(gc), NULL, NULL, - gc); + "account", gc); } static void yahoo_show_chat_goto(PurplePluginAction *action) { PurpleConnection *gc = (PurpleConnection *) action->context; - purple_request_input(gc, NULL, _("Join whom in chat?"), NULL, + purple_request_input(gc, NULL, _("Join who in chat?"), NULL, "", FALSE, FALSE, NULL, _("OK"), G_CALLBACK(yahoo_chat_goto), _("Cancel"), NULL, purple_connection_get_account(gc), NULL, NULL, - gc); + "chat", gc); } static GList *yahoo_actions(PurplePlugin *plugin, gpointer context) {
--- a/libpurple/request.c Fri Sep 21 16:09:12 2007 +0000 +++ b/libpurple/request.c Sat Sep 22 09:48:07 2007 +0000 @@ -1140,7 +1140,7 @@ const char *ok_text, GCallback ok_cb, const char *cancel_text, GCallback cancel_cb, PurpleAccount *account, const char *who, PurpleConversation *conv, - void *user_data) + const char *ui_hint, void *user_data) { PurpleRequestUiOps *ops; @@ -1161,7 +1161,7 @@ ok_text, ok_cb, cancel_text, cancel_cb, account, who, conv, - user_data); + ui_hint, user_data); handles = g_list_append(handles, info); @@ -1177,7 +1177,7 @@ const char *ok_text, GCallback ok_cb, const char *cancel_text, GCallback cancel_cb, PurpleAccount *account, const char *who, PurpleConversation *conv, - void *user_data, ...) + const char *ui_hint, void *user_data, ...) { void *ui_handle; va_list args; @@ -1189,7 +1189,7 @@ ui_handle = purple_request_choice_varg(handle, title, primary, secondary, default_value, ok_text, ok_cb, cancel_text, cancel_cb, - account, who, conv, user_data, args); + account, who, conv, ui_hint, user_data, args); va_end(args); return ui_handle; @@ -1202,7 +1202,7 @@ const char *ok_text, GCallback ok_cb, const char *cancel_text, GCallback cancel_cb, PurpleAccount *account, const char *who, PurpleConversation *conv, - void *user_data, va_list choices) + const char *ui_hint, void *user_data, va_list choices) { PurpleRequestUiOps *ops; @@ -1222,7 +1222,7 @@ ok_text, ok_cb, cancel_text, cancel_cb, account, who, conv, - user_data, choices); + ui_hint, user_data, choices); handles = g_list_append(handles, info); @@ -1236,7 +1236,7 @@ purple_request_action(void *handle, const char *title, const char *primary, const char *secondary, int default_action, PurpleAccount *account, const char *who, PurpleConversation *conv, - void *user_data, size_t action_count, ...) + const char *ui_hint, void *user_data, size_t action_count, ...) { void *ui_handle; va_list args; @@ -1246,7 +1246,7 @@ va_start(args, action_count); ui_handle = purple_request_action_varg(handle, title, primary, secondary, default_action, account, who, conv, - user_data, action_count, args); + ui_hint, user_data, action_count, args); va_end(args); return ui_handle; @@ -1257,7 +1257,7 @@ const char *primary, const char *secondary, int default_action, PurpleAccount *account, const char *who, PurpleConversation *conv, - void *user_data, size_t action_count, va_list actions) + const char *ui_hint, void *user_data, size_t action_count, va_list actions) { PurpleRequestUiOps *ops; @@ -1273,7 +1273,7 @@ info->handle = handle; info->ui_handle = ops->request_action(title, primary, secondary, default_action, account, who, conv, - user_data, action_count, actions); + ui_hint, user_data, action_count, actions); handles = g_list_append(handles, info); @@ -1289,7 +1289,7 @@ const char *ok_text, GCallback ok_cb, const char *cancel_text, GCallback cancel_cb, PurpleAccount *account, const char *who, PurpleConversation *conv, - void *user_data) + const char *ui_hint, void *user_data) { PurpleRequestUiOps *ops; @@ -1309,7 +1309,7 @@ fields, ok_text, ok_cb, cancel_text, cancel_cb, account, who, conv, - user_data); + ui_hint, user_data); handles = g_list_append(handles, info); @@ -1324,7 +1324,7 @@ gboolean savedialog, GCallback ok_cb, GCallback cancel_cb, PurpleAccount *account, const char *who, PurpleConversation *conv, - void *user_data) + const char *ui_hint, void *user_data) { PurpleRequestUiOps *ops; @@ -1338,7 +1338,7 @@ info->handle = handle; info->ui_handle = ops->request_file(title, filename, savedialog, ok_cb, cancel_cb, - account, who, conv, user_data); + account, who, conv, ui_hint, user_data); handles = g_list_append(handles, info); return info->ui_handle; } @@ -1350,7 +1350,7 @@ purple_request_folder(void *handle, const char *title, const char *dirname, GCallback ok_cb, GCallback cancel_cb, PurpleAccount *account, const char *who, PurpleConversation *conv, - void *user_data) + const char *ui_hint, void *user_data) { PurpleRequestUiOps *ops; @@ -1365,7 +1365,7 @@ info->ui_handle = ops->request_folder(title, dirname, ok_cb, cancel_cb, account, who, conv, - user_data); + ui_hint, user_data); handles = g_list_append(handles, info); return info->ui_handle; }
--- a/libpurple/request.h Fri Sep 21 16:09:12 2007 +0000 +++ b/libpurple/request.h Sat Sep 22 09:48:07 2007 +0000 @@ -189,33 +189,33 @@ const char *ok_text, GCallback ok_cb, const char *cancel_text, GCallback cancel_cb, PurpleAccount *account, const char *who, PurpleConversation *conv, - void *user_data); + const char *ui_hint, void *user_data); void *(*request_choice)(const char *title, const char *primary, const char *secondary, int default_value, const char *ok_text, GCallback ok_cb, const char *cancel_text, GCallback cancel_cb, PurpleAccount *account, const char *who, PurpleConversation *conv, - void *user_data, va_list choices); + const char *ui_hint, void *user_data, va_list choices); void *(*request_action)(const char *title, const char *primary, const char *secondary, int default_action, PurpleAccount *account, const char *who, PurpleConversation *conv, - void *user_data, size_t action_count, + const char *ui_hint, void *user_data, size_t action_count, va_list actions); void *(*request_fields)(const char *title, const char *primary, const char *secondary, PurpleRequestFields *fields, const char *ok_text, GCallback ok_cb, const char *cancel_text, GCallback cancel_cb, PurpleAccount *account, const char *who, PurpleConversation *conv, - void *user_data); + const char *ui_hint, void *user_data); void *(*request_file)(const char *title, const char *filename, gboolean savedialog, GCallback ok_cb, GCallback cancel_cb, PurpleAccount *account, const char *who, PurpleConversation *conv, - void *user_data); + const char *ui_hint, void *user_data); void (*close_request)(PurpleRequestType type, void *ui_handle); void *(*request_folder)(const char *title, const char *dirname, GCallback ok_cb, GCallback cancel_cb, PurpleAccount *account, const char *who, PurpleConversation *conv, - void *user_data); + const char *ui_hint, void *user_data); void (*_purple_reserved1)(void); void (*_purple_reserved2)(void); @@ -1187,6 +1187,7 @@ * @param account The PurpleAccount associated with this request, or NULL if none is * @param who The username of the buddy assocaited with this request, or NULL if none is * @param conv The PurpleConversation associated with this request, or NULL if none is + * @param ui_hint UI hint * @param user_data The data to pass to the callback. * * @return A UI-specific handle. @@ -1198,7 +1199,7 @@ const char *ok_text, GCallback ok_cb, const char *cancel_text, GCallback cancel_cb, PurpleAccount *account, const char *who, PurpleConversation *conv, - void *user_data); + const char *ui_hint, void *user_data); /** * Prompts the user for multiple-choice input. @@ -1216,7 +1217,8 @@ * @param cancel_cb The callback for the @c Cancel button. * @param account The PurpleAccount associated with this request, or NULL if none is * @param who The username of the buddy assocaited with this request, or NULL if none is - * @param conv The PurpleConversation associated with this request, or NULL if none is + * @param conv The PurpleConversation associated with this request, or NULL if none is + * @param ui_hint UI hint * @param user_data The data to pass to the callback. * @param ... The choices. This argument list should be * terminated with a NULL parameter. @@ -1229,7 +1231,7 @@ const char *ok_text, GCallback ok_cb, const char *cancel_text, GCallback cancel_cb, PurpleAccount *account, const char *who, PurpleConversation *conv, - void *user_data, ...) G_GNUC_NULL_TERMINATED; + const char *ui_hint, void *user_data, ...) G_GNUC_NULL_TERMINATED; /** * Prompts the user for multiple-choice input. @@ -1247,7 +1249,8 @@ * @param cancel_cb The callback for the @c Cancel button. * @param account The PurpleAccount associated with this request, or NULL if none is * @param who The username of the buddy assocaited with this request, or NULL if none is - * @param conv The PurpleConversation associated with this request, or NULL if none is + * @param conv The PurpleConversation associated with this request, or NULL if none is + * @param ui_hint UI hint * @param user_data The data to pass to the callback. * @param choices The choices. This argument list should be * terminated with a @c NULL parameter. @@ -1260,7 +1263,7 @@ const char *ok_text, GCallback ok_cb, const char *cancel_text, GCallback cancel_cb, PurpleAccount *account, const char *who, PurpleConversation *conv, - void *user_data, va_list choices); + const char *ui_hint, void *user_data, va_list choices); /** * Prompts the user for an action. @@ -1276,7 +1279,8 @@ * @param default_action The default value. * @param account The PurpleAccount associated with this request, or NULL if none is * @param who The username of the buddy assocaited with this request, or NULL if none is - * @param conv The PurpleConversation associated with this request, or NULL if none is + * @param conv The PurpleConversation associated with this request, or NULL if none is + * @param ui_hint UI hint * @param user_data The data to pass to the callback. * @param action_count The number of actions. * @param ... A list of actions. These are pairs of @@ -1293,7 +1297,7 @@ const char *primary, const char *secondary, int default_action, PurpleAccount *account, const char *who, PurpleConversation *conv, - void *user_data, size_t action_count, ...); + const char *ui_hint, void *user_data, size_t action_count, ...); /** * Prompts the user for an action. @@ -1309,7 +1313,8 @@ * @param default_action The default value. * @param account The PurpleAccount associated with this request, or NULL if none is * @param who The username of the buddy assocaited with this request, or NULL if none is - * @param conv The PurpleConversation associated with this request, or NULL if none is + * @param conv The PurpleConversation associated with this request, or NULL if none is + * @param ui_hint UI hint * @param user_data The data to pass to the callback. * @param action_count The number of actions. * @param actions A list of actions and callbacks. @@ -1320,7 +1325,7 @@ const char *primary, const char *secondary, int default_action, PurpleAccount *account, const char *who, PurpleConversation *conv, - void *user_data, size_t action_count, + const char *ui_hint, void *user_data, size_t action_count, va_list actions); /** @@ -1339,7 +1344,8 @@ * @param cancel_cb The callback for the @c Cancel button. * @param account The PurpleAccount associated with this request, or NULL if none is * @param who The username of the buddy associated with this request, or NULL if none is - * @param conv The PurpleConversation associated with this request, or NULL if none is + * @param conv The PurpleConversation associated with this request, or NULL if none is + * @param ui_hint UI hint * @param user_data The data to pass to the callback. * * @return A UI-specific handle. @@ -1350,7 +1356,7 @@ const char *ok_text, GCallback ok_cb, const char *cancel_text, GCallback cancel_cb, PurpleAccount *account, const char *who, PurpleConversation *conv, - void *user_data); + const char *ui_hint, void *user_data); /** * Closes a request. @@ -1372,9 +1378,9 @@ */ #define purple_request_yes_no(handle, title, primary, secondary, \ default_action, account, who, conv, \ - user_data, yes_cb, no_cb) \ + ui_hint, user_data, yes_cb, no_cb) \ purple_request_action((handle), (title), (primary), (secondary), \ - (default_action), account, who, conv, (user_data), 2, \ + (default_action), account, who, conv, (ui_hint), (user_data), 2, \ _("_Yes"), (yes_cb), _("_No"), (no_cb)) /** @@ -1382,9 +1388,9 @@ */ #define purple_request_ok_cancel(handle, title, primary, secondary, \ default_action, account, who, conv, \ - user_data, ok_cb, cancel_cb) \ + ui_hint, user_data, ok_cb, cancel_cb) \ purple_request_action((handle), (title), (primary), (secondary), \ - (default_action), account, who, conv, (user_data), 2, \ + (default_action), account, who, conv, (ui_hint), (user_data), 2, \ _("_OK"), (ok_cb), _("_Cancel"), (cancel_cb)) /** @@ -1392,9 +1398,9 @@ */ #define purple_request_accept_cancel(handle, title, primary, secondary, \ default_action, account, who, conv, \ - user_data, accept_cb, cancel_cb) \ + ui_hint, user_data, accept_cb, cancel_cb) \ purple_request_action((handle), (title), (primary), (secondary), \ - (default_action), account, who, conv, (user_data), 2, \ + (default_action), account, who, conv, (ui_hint), (user_data), 2, \ _("_Accept"), (accept_cb), _("_Cancel"), (cancel_cb)) /** @@ -1412,7 +1418,8 @@ * @param cancel_cb The callback for the @c Cancel button. * @param account The PurpleAccount associated with this request, or NULL if none is * @param who The username of the buddy assocaited with this request, or NULL if none is - * @param conv The PurpleConversation associated with this request, or NULL if none is + * @param conv The PurpleConversation associated with this request, or NULL if none is + * @param ui_hint UI hint * @param user_data The data to pass to the callback. * * @return A UI-specific handle. @@ -1421,7 +1428,7 @@ gboolean savedialog, GCallback ok_cb, GCallback cancel_cb, PurpleAccount *account, const char *who, PurpleConversation *conv, - void *user_data); + const char *ui_hint, void *user_data); /** * Displays a folder select dialog. Returns the selected filename to @@ -1436,7 +1443,8 @@ * @param cancel_cb The callback for the @c Cancel button. * @param account The PurpleAccount associated with this request, or NULL if none is * @param who The username of the buddy assocaited with this request, or NULL if none is - * @param conv The PurpleConversation associated with this request, or NULL if none is + * @param conv The PurpleConversation associated with this request, or NULL if none is + * @param ui_hint UI hint * @param user_data The data to pass to the callback. * * @return A UI-specific handle.
--- a/libpurple/server.c Fri Sep 21 16:09:12 2007 +0000 +++ b/libpurple/server.c Sat Sep 22 09:48:07 2007 +0000 @@ -801,7 +801,7 @@ purple_request_accept_cancel(gc, NULL, _("Accept chat invitation?"), buf2, PURPLE_DEFAULT_ACTION_NONE, account, who, NULL, - cid, G_CALLBACK(chat_invite_accept), + "chat", cid, G_CALLBACK(chat_invite_accept), G_CALLBACK(chat_invite_reject)); } else if (plugin_return > 0)
--- a/pidgin/gtkaccount.c Fri Sep 21 16:09:12 2007 +0000 +++ b/pidgin/gtkaccount.c Sat Sep 22 09:48:07 2007 +0000 @@ -1903,7 +1903,7 @@ purple_request_close_with_handle(account); purple_request_action(account, NULL, buf, NULL, 0, account, NULL, NULL, - account, 2, + "accounts", account, 2, _("Delete"), delete_account_cb, _("Cancel"), NULL); g_free(buf);
--- a/pidgin/gtkblist.c Fri Sep 21 16:09:12 2007 +0000 +++ b/pidgin/gtkblist.c Sat Sep 22 09:48:07 2007 +0000 @@ -617,7 +617,7 @@ static void gtk_blist_menu_bp_cb(GtkWidget *w, PurpleBuddy *b) { - pidgin_pounce_editor_show(b->account, b->name, NULL); + pidgin_pounce_editor_show(GTK_WINDOW(gtkblist->window), b->account, b->name, NULL); } static void gtk_blist_menu_showlog_cb(GtkWidget *w, PurpleBlistNode *node) @@ -643,7 +643,7 @@ name = prpl_info->get_chat_name(c->components); } } else if (PURPLE_BLIST_NODE_IS_CONTACT(node)) { - pidgin_log_show_contact((PurpleContact *)node); + pidgin_log_show_contact(GTK_WINDOW(gtkblist->window), (PurpleContact *)node); pidgin_clear_cursor(gtkblist->window); return; } else { @@ -655,7 +655,7 @@ } if (name && account) { - pidgin_log_show(type, name, account); + pidgin_log_show(GTK_WINDOW(gtkblist->window), type, name, account); g_free(name); pidgin_clear_cursor(gtkblist->window); @@ -682,11 +682,6 @@ pidgin_blist_update(purple_get_blist(), node); } -static void gtk_blist_show_systemlog_cb() -{ - pidgin_syslog_show(); -} - static void gtk_blist_show_onlinehelp_cb() { purple_notify_uri(NULL, PURPLE_WEBSITE "documentation"); @@ -3057,6 +3052,11 @@ !purple_prefs_get_bool(PIDGIN_PREFS_ROOT "/debug/enabled")); } +static void +pidgin_blist_show_with_parent(gpointer data1, void (*callback)(GtkWindow *parent), gpointer data3) +{ + callback(GTK_WINDOW(gtkblist->window)); +} /*************************************************** * Crap * @@ -3092,13 +3092,13 @@ { N_("/_Tools"), NULL, NULL, 0, "<Branch>", NULL }, { N_("/Tools/Buddy _Pounces"), NULL, pidgin_pounces_manager_show, 0, "<Item>", NULL }, { N_("/Tools/_Certificates"), NULL, pidgin_certmgr_show, 0, "<Item>", NULL }, - { N_("/Tools/Plu_gins"), "<CTL>U", pidgin_plugin_dialog_show, 0, "<StockItem>", PIDGIN_STOCK_TOOLBAR_PLUGINS }, + { N_("/Tools/Plu_gins"), "<CTL>U", pidgin_blist_show_with_parent, (int)pidgin_plugin_dialog_show, "<StockItem>", PIDGIN_STOCK_TOOLBAR_PLUGINS }, { N_("/Tools/Pr_eferences"), "<CTL>P", pidgin_prefs_show, 0, "<StockItem>", GTK_STOCK_PREFERENCES }, { N_("/Tools/Pr_ivacy"), NULL, pidgin_privacy_dialog_show, 0, "<Item>", NULL }, { "/Tools/sep2", NULL, NULL, 0, "<Separator>", NULL }, { N_("/Tools/_File Transfers"), "<CTL>T", pidgin_xfer_dialog_show, 0, "<Item>", NULL }, { N_("/Tools/R_oom List"), NULL, pidgin_roomlist_dialog_show, 0, "<Item>", NULL }, - { N_("/Tools/System _Log"), NULL, gtk_blist_show_systemlog_cb, 0, "<Item>", NULL }, + { N_("/Tools/System _Log"), NULL, pidgin_blist_show_with_parent, (int)pidgin_syslog_show, "<Item>", NULL }, { "/Tools/sep3", NULL, NULL, 0, "<Separator>", NULL }, { N_("/Tools/Mute _Sounds"), "<CTL>S", pidgin_blist_mute_sounds_cb, 0, "<CheckItem>", NULL }, /* Help */ @@ -3106,7 +3106,7 @@ { N_("/Help/Online _Help"), "F1", gtk_blist_show_onlinehelp_cb, 0, "<StockItem>", GTK_STOCK_HELP }, { N_("/Help/_Debug Window"), NULL, toggle_debug, 0, "<Item>", NULL }, #if GTK_CHECK_VERSION(2,6,0) - { N_("/Help/_About"), NULL, pidgin_dialogs_about, 0, "<StockItem>", GTK_STOCK_ABOUT }, + { N_("/Help/_About"), NULL, pidgin_blist_show_with_parent, (int)pidgin_dialogs_about, "<StockItem>", GTK_STOCK_ABOUT }, #else { N_("/Help/_About"), NULL, pidgin_dialogs_about, 0, "<Item>", NULL }, #endif @@ -4317,7 +4317,7 @@ enabled = purple_account_get_enabled(account, purple_core_get_ui()); purple_request_action(account, _("Connection Error"), primary, text, 2, account, NULL, NULL, - account, 3, + "account", account, 3, _("OK"), NULL, _("Modify Account"), PURPLE_CALLBACK(ce_modify_account_cb), enabled ? _("Connect") : _("Re-enable Account"), @@ -6266,7 +6266,7 @@ _("Add"), G_CALLBACK(add_group_cb), _("Cancel"), NULL, NULL, NULL, NULL, - NULL); + "blist", NULL); } void
--- a/pidgin/gtkcertmgr.c Fri Sep 21 16:09:12 2007 +0000 +++ b/pidgin/gtkcertmgr.c Sat Sep 22 09:48:07 2007 +0000 @@ -197,7 +197,7 @@ _("Cancel"), G_CALLBACK(tls_peers_mgmt_import_cancel2_cb), NULL, NULL, NULL, /* No account/who/conv*/ - crt /* Pass cert instance to callback*/ + "certmgr", crt /* Pass cert instance to callback*/ ); g_free(default_hostname); @@ -226,7 +226,7 @@ FALSE, /* Not a save dialog */ G_CALLBACK(tls_peers_mgmt_import_ok_cb), NULL, /* Do nothing if cancelled */ - NULL, NULL, NULL, NULL );/* No account,conv,etc. */ + NULL, NULL, NULL, "certmgr", NULL );/* No account,conv,etc. */ } static void @@ -302,7 +302,7 @@ G_CALLBACK(tls_peers_mgmt_export_ok_cb), G_CALLBACK(tls_peers_mgmt_export_cancel_cb), NULL, NULL, NULL, /* No account,conv,etc. */ - crt); /* Pass the certificate on to the callback */ + "certmgr", crt); /* Pass the certificate on to the callback */ } static void @@ -375,6 +375,7 @@ primary, NULL, /* Can this be NULL? */ 2, /* NO is default action */ NULL, NULL, NULL, + "certmgr", id, /* id ownership passed to callback */ tls_peers_mgmt_delete_confirm_cb, tls_peers_mgmt_delete_confirm_cb );
--- a/pidgin/gtkconv.c Fri Sep 21 16:09:12 2007 +0000 +++ b/pidgin/gtkconv.c Sat Sep 22 09:48:07 2007 +0000 @@ -1033,7 +1033,7 @@ buf, TRUE, G_CALLBACK(savelog_writefile_cb), NULL, NULL, NULL, conv, - conv); + "conversation", conv); g_free(buf); } @@ -1081,7 +1081,7 @@ PurpleBlistNode *node = cur->data; if ((node != NULL) && ((node->prev != NULL) || (node->next != NULL))) { - pidgin_log_show_contact((PurpleContact *)node->parent); + pidgin_log_show_contact(GTK_WINDOW(win->window), (PurpleContact *)node->parent); g_slist_free(buddies); gdk_window_set_cursor(gtkblist->window->window, NULL); gdk_window_set_cursor(win->window->window, NULL); @@ -1090,7 +1090,7 @@ } g_slist_free(buddies); - pidgin_log_show(type, name, account); + pidgin_log_show(GTK_WINDOW(win->window), type, name, account); gdk_window_set_cursor(gtkblist->window->window, NULL); gdk_window_set_cursor(win->window->window, NULL); @@ -1236,7 +1236,7 @@ conv = pidgin_conv_window_get_active_gtkconv(win)->active_conv; - pidgin_pounce_editor_show(purple_conversation_get_account(conv), + pidgin_pounce_editor_show(GTK_WINDOW(win->window), purple_conversation_get_account(conv), purple_conversation_get_name(conv), NULL); } @@ -2716,7 +2716,7 @@ purple_request_file(gtkconv, _("Save Icon"), buf, TRUE, G_CALLBACK(saveicon_writefile_cb), NULL, conv->account, NULL, conv, - gtkconv); + "conversation", gtkconv); g_free(buf); }
--- a/pidgin/gtkdebug.c Fri Sep 21 16:09:12 2007 +0000 +++ b/pidgin/gtkdebug.c Sat Sep 22 09:48:07 2007 +0000 @@ -234,7 +234,7 @@ purple_request_file(win, _("Save Debug Log"), "purple-debug.log", TRUE, G_CALLBACK(save_writefile_cb), NULL, NULL, NULL, NULL, - win); + "blist", win); } static void
--- a/pidgin/gtkdialogs.c Fri Sep 21 16:09:12 2007 +0000 +++ b/pidgin/gtkdialogs.c Sat Sep 22 09:48:07 2007 +0000 @@ -326,7 +326,7 @@ } #endif -void pidgin_dialogs_about() +void pidgin_dialogs_about(GtkWindow *parent) { GtkWidget *hbox; GtkWidget *vbox; @@ -343,11 +343,15 @@ GdkPixbuf *pixbuf; if (about != NULL) { + if (parent) + gtk_window_set_transient_for(GTK_WINDOW(about), parent); gtk_window_present(GTK_WINDOW(about)); return; } PIDGIN_DIALOG(about); + if (parent) + gtk_window_set_transient_for(GTK_WINDOW(about), parent); tmp = g_strdup_printf(_("About %s"), PIDGIN_NAME); gtk_window_set_title(GTK_WINDOW(about), tmp); g_free(tmp); @@ -766,7 +770,7 @@ _("OK"), G_CALLBACK(pidgin_dialogs_im_cb), _("Cancel"), NULL, NULL, NULL, NULL, - NULL); + "blist", NULL); } void @@ -905,7 +909,7 @@ _("OK"), G_CALLBACK(pidgin_dialogs_info_cb), _("Cancel"), NULL, NULL, NULL, NULL, - NULL); + "blist", NULL); } static void @@ -933,7 +937,7 @@ PurpleBlistNode *node = cur->data; if ((node != NULL) && ((node->prev != NULL) || (node->next != NULL))) { - pidgin_log_show_contact((PurpleContact *)node->parent); + pidgin_log_show_contact(GTK_WINDOW(gtkblist->window), (PurpleContact *)node->parent); g_slist_free(buddies); pidgin_clear_cursor(gtkblist->window); g_free(username); @@ -942,7 +946,7 @@ } g_slist_free(buddies); - pidgin_log_show(PURPLE_LOG_IM, username, account); + pidgin_log_show(GTK_WINDOW(gtkblist->window), PURPLE_LOG_IM, username, account); pidgin_clear_cursor(gtkblist->window); } @@ -997,7 +1001,7 @@ _("OK"), G_CALLBACK(pidgin_dialogs_log_cb), _("Cancel"), NULL, NULL, NULL, NULL, - NULL); + "blist", NULL); } static void @@ -1017,7 +1021,7 @@ _("Alias"), G_CALLBACK(pidgin_dialogs_alias_contact_cb), _("Cancel"), NULL, NULL, purple_contact_get_alias(contact), NULL, - contact); + "blist", contact); } static void @@ -1041,7 +1045,7 @@ _("Alias"), G_CALLBACK(pidgin_dialogs_alias_buddy_cb), _("Cancel"), NULL, purple_buddy_get_account(buddy), purple_buddy_get_name(buddy), NULL, - buddy); + "blist", buddy); g_free(secondary); } @@ -1063,7 +1067,7 @@ _("Alias"), G_CALLBACK(pidgin_dialogs_alias_chat_cb), _("Cancel"), NULL, chat->account, NULL, NULL, - chat); + "blist", chat); } static void @@ -1107,7 +1111,7 @@ purple_request_action(contact, NULL, _("Remove Contact"), text, 0, NULL, purple_contact_get_alias(contact), NULL, - contact, 2, + "blist", contact, 2, _("_Remove Contact"), G_CALLBACK(pidgin_dialogs_remove_contact_cb), _("Cancel"), NULL); @@ -1148,7 +1152,7 @@ purple_request_action(source, NULL, _("Merge Groups"), text, 0, NULL, NULL, NULL, - ggp, 2, + "blist", ggp, 2, _("_Merge Groups"), G_CALLBACK(pidgin_dialogs_merge_groups_cb), _("Cancel"), G_CALLBACK(free_ggmo)); @@ -1204,7 +1208,7 @@ purple_request_action(group, NULL, _("Remove Group"), text, 0, NULL, NULL, NULL, - group, 2, + "blist", group, 2, _("_Remove Group"), G_CALLBACK(pidgin_dialogs_remove_group_cb), _("Cancel"), NULL); @@ -1243,7 +1247,7 @@ purple_request_action(buddy, NULL, _("Remove Buddy"), text, 0, purple_buddy_get_account(buddy), purple_buddy_get_name(buddy), NULL, - buddy, 2, + "blist", buddy, 2, _("_Remove Buddy"), G_CALLBACK(pidgin_dialogs_remove_buddy_cb), _("Cancel"), NULL); @@ -1270,7 +1274,7 @@ purple_request_action(chat, NULL, _("Remove Chat"), text, 0, chat->account, NULL, NULL, - chat, 2, + "blist", chat, 2, _("_Remove Chat"), G_CALLBACK(pidgin_dialogs_remove_chat_cb), _("Cancel"), NULL);
--- a/pidgin/gtkdialogs.h Fri Sep 21 16:09:12 2007 +0000 +++ b/pidgin/gtkdialogs.h Sat Sep 22 09:48:07 2007 +0000 @@ -32,7 +32,7 @@ /* Functions in gtkdialogs.c (these should actually stay in this file) */ void pidgin_dialogs_destroy_all(void); -void pidgin_dialogs_about(void); +void pidgin_dialogs_about(GtkWindow *parent); void pidgin_dialogs_im(void); void pidgin_dialogs_im_with_user(PurpleAccount *, const char *); void pidgin_dialogs_info(void);
--- a/pidgin/gtkimhtmltoolbar.c Fri Sep 21 16:09:12 2007 +0000 +++ b/pidgin/gtkimhtmltoolbar.c Sat Sep 22 09:48:07 2007 +0000 @@ -184,6 +184,8 @@ g_signal_connect_after(G_OBJECT(toolbar->font_dialog), "realize", G_CALLBACK(realize_toolbar_font), toolbar); } + gtk_window_set_transient_for(GTK_WINDOW(toolbar->font_dialog), + GTK_WINDOW(gtk_widget_get_toplevel(GTK_WIDGET(toolbar)))); gtk_window_present(GTK_WINDOW(toolbar->font_dialog)); } else { cancel_toolbar_font(font, toolbar); @@ -434,7 +436,7 @@ _("_Insert"), G_CALLBACK(do_insert_link_cb), _("Cancel"), G_CALLBACK(cancel_link_cb), NULL, NULL, NULL, - toolbar); + "conversation", toolbar); g_free(msg); g_free(desc); } else { @@ -709,6 +711,8 @@ gtk_window_set_resizable(GTK_WINDOW(dialog), FALSE); gtk_window_set_role(GTK_WINDOW(dialog), "smiley_dialog"); gtk_window_set_position(GTK_WINDOW(dialog), GTK_WIN_POS_MOUSE); + gtk_window_set_transient_for(GTK_WINDOW(dialog), + GTK_WINDOW(gtk_widget_get_toplevel(GTK_WIDGET(toolbar)))); if (unique_smileys != NULL) { struct smiley_button_list *ls, *it, *it_tmp;
--- a/pidgin/gtklog.c Fri Sep 21 16:09:12 2007 +0000 +++ b/pidgin/gtklog.c Sat Sep 22 09:48:07 2007 +0000 @@ -323,7 +323,7 @@ data2[2] = log; purple_request_action(lv, NULL, "Delete Log?", tmp, 0, NULL, NULL, NULL, - data2, 2, + "log_viewer", data2, 2, _("Delete"), delete_log_cb, _("Cancel"), delete_log_cleanup_cb); g_free(tmp); @@ -523,7 +523,7 @@ } } -static PidginLogViewer *display_log_viewer(struct log_viewer_hash_t *ht, GList *logs, +static PidginLogViewer *display_log_viewer(GtkWindow *parent, struct log_viewer_hash_t *ht, GList *logs, const char *title, GtkWidget *icon, int log_size) { PidginLogViewer *lv; @@ -569,7 +569,7 @@ g_hash_table_insert(log_viewers, ht, lv); /* Window ***********/ - lv->window = gtk_dialog_new_with_buttons(title, NULL, 0, + lv->window = gtk_dialog_new_with_buttons(title, parent, 0, GTK_STOCK_CLOSE, GTK_RESPONSE_CLOSE, NULL); #ifdef _WIN32 /* Steal the "HELP" response and use it to trigger browsing to the logs folder */ @@ -675,7 +675,7 @@ return lv; } -void pidgin_log_show(PurpleLogType type, const char *screenname, PurpleAccount *account) { +void pidgin_log_show(GtkWindow *parent, PurpleLogType type, const char *screenname, PurpleAccount *account) { struct log_viewer_hash_t *ht; PidginLogViewer *lv = NULL; const char *name = screenname; @@ -717,13 +717,13 @@ title = g_strdup_printf(_("Conversations with %s"), name); } - display_log_viewer(ht, purple_log_get_logs(type, screenname, account), + display_log_viewer(parent, ht, purple_log_get_logs(type, screenname, account), title, gtk_image_new_from_pixbuf(pidgin_create_prpl_icon(account, PIDGIN_PRPL_ICON_MEDIUM)), purple_log_get_total_size(type, screenname, account)); g_free(title); } -void pidgin_log_show_contact(PurpleContact *contact) { +void pidgin_log_show_contact(GtkWindow *parent, PurpleContact *contact) { struct log_viewer_hash_t *ht = g_new0(struct log_viewer_hash_t, 1); PurpleBlistNode *child; PidginLogViewer *lv = NULL; @@ -777,11 +777,11 @@ } title = g_strdup_printf(_("Conversations with %s"), name); - display_log_viewer(ht, logs, title, image, total_log_size); + display_log_viewer(parent, ht, logs, title, image, total_log_size); g_free(title); } -void pidgin_syslog_show() +void pidgin_syslog_show(GtkWindow *parent) { GList *accounts = NULL; GList *logs = NULL; @@ -801,7 +801,7 @@ } logs = g_list_sort(logs, purple_log_compare); - syslog_viewer = display_log_viewer(NULL, logs, _("System Log"), NULL, 0); + syslog_viewer = display_log_viewer(parent, NULL, logs, _("System Log"), NULL, 0); } /****************************************************************************
--- a/pidgin/gtklog.h Fri Sep 21 16:09:12 2007 +0000 +++ b/pidgin/gtklog.h Sat Sep 22 09:48:07 2007 +0000 @@ -52,10 +52,10 @@ -void pidgin_log_show(PurpleLogType type, const char *screenname, PurpleAccount *account); -void pidgin_log_show_contact(PurpleContact *contact); +void pidgin_log_show(GtkWindow *parent, PurpleLogType type, const char *screenname, PurpleAccount *account); +void pidgin_log_show_contact(GtkWindow *parent, PurpleContact *contact); -void pidgin_syslog_show(void); +void pidgin_syslog_show(GtkWindow *parent); /**************************************************************************/ /** @name GTK+ Log Subsystem */
--- a/pidgin/gtkplugin.c Fri Sep 21 16:09:12 2007 +0000 +++ b/pidgin/gtkplugin.c Sat Sep 22 09:48:07 2007 +0000 @@ -284,7 +284,7 @@ _("Multiple plugins will be unloaded."), tmp->str, 0, NULL, NULL, NULL, - cb_data, 2, + "plugins", cb_data, 2, _("Unload Plugins"), G_CALLBACK(plugin_unload_confirm_cb), _("Cancel"), g_free); g_string_free(tmp, TRUE); @@ -514,7 +514,7 @@ plugin_dialog_response_cb(dialog, PIDGIN_RESPONSE_CONFIGURE, sel); } -void pidgin_plugin_dialog_show() +void pidgin_plugin_dialog_show(GtkWindow *parent) { GtkWidget *sw; GtkWidget *event_view; @@ -524,6 +524,8 @@ GtkTreeSelection *sel; if (plugin_dialog != NULL) { + if (parent) + gtk_window_set_transient_for(GTK_WINDOW(plugin_dialog), parent); gtk_window_present(GTK_WINDOW(plugin_dialog)); return; } @@ -532,6 +534,8 @@ NULL, GTK_DIALOG_NO_SEPARATOR, NULL); + if (parent) + gtk_window_set_transient_for(GTK_WINDOW(plugin_dialog), parent); pref_button = gtk_dialog_add_button(GTK_DIALOG(plugin_dialog), _("Configure Pl_ugin"), PIDGIN_RESPONSE_CONFIGURE); gtk_dialog_add_button(GTK_DIALOG(plugin_dialog),
--- a/pidgin/gtkplugin.h Fri Sep 21 16:09:12 2007 +0000 +++ b/pidgin/gtkplugin.h Sat Sep 22 09:48:07 2007 +0000 @@ -75,6 +75,6 @@ /** * Shows the Plugins dialog */ -void pidgin_plugin_dialog_show(void); +void pidgin_plugin_dialog_show(GtkWindow *parent); #endif /* _PIDGINPLUGIN_H_ */
--- a/pidgin/gtkpounce.c Fri Sep 21 16:09:12 2007 +0000 +++ b/pidgin/gtkpounce.c Sat Sep 22 09:48:07 2007 +0000 @@ -157,7 +157,7 @@ purple_request_file(entry, _("Select a file"), name, FALSE, G_CALLBACK(pounce_update_entry_fields), NULL, NULL, NULL, NULL, - entry); + "buddy_pounce", entry); g_signal_connect_swapped(G_OBJECT(entry), "destroy", G_CALLBACK(purple_request_close_with_handle), entry); } @@ -462,7 +462,7 @@ } void -pidgin_pounce_editor_show(PurpleAccount *account, const char *name, +pidgin_pounce_editor_show(GtkWindow *parent, PurpleAccount *account, const char *name, PurplePounce *cur_pounce) { PidginPounceDialog *dialog; @@ -1043,7 +1043,7 @@ static void pounces_manager_add_cb(GtkButton *button, gpointer user_data) { - pidgin_pounce_editor_show(NULL, NULL, NULL); + pidgin_pounce_editor_show(GTK_WINDOW(pounces_manager->window), NULL, NULL, NULL); } static void @@ -1053,7 +1053,7 @@ PurplePounce *pounce; gtk_tree_model_get(model, iter, POUNCES_MANAGER_COLUMN_POUNCE, &pounce, -1); - pidgin_pounce_editor_show(NULL, NULL, pounce); + pidgin_pounce_editor_show(GTK_WINDOW(pounces_manager->window), NULL, NULL, pounce); } static void @@ -1096,7 +1096,7 @@ buf = g_strdup_printf(_("Are you sure you want to delete the pounce on %s for %s?"), pouncee, pouncer); purple_request_action(pounce, NULL, buf, NULL, 0, account, pouncee, NULL, - pounce, 2, + "pounces", pounce, 2, _("Delete"), pounces_manager_delete_confirm_cb, _("Cancel"), NULL); g_free(buf); @@ -1153,7 +1153,7 @@ if ((pounce != NULL) && (event->button == 1) && (event->type == GDK_2BUTTON_PRESS)) { - pidgin_pounce_editor_show(NULL, NULL, pounce); + pidgin_pounce_editor_show(GTK_WINDOW(pounces_manager->window), NULL, NULL, pounce); return TRUE; } @@ -1302,7 +1302,7 @@ } void -pidgin_pounces_manager_show(void) +pidgin_pounces_manager_show(GtkWindow *parent) { PouncesManager *dialog; GtkWidget *bbox; @@ -1314,6 +1314,7 @@ if (pounces_manager != NULL) { gtk_window_present(GTK_WINDOW(pounces_manager->window)); + gtk_window_set_transient_for(GTK_WINDOW(pounces_manager->window), parent); return; } @@ -1324,6 +1325,7 @@ dialog->window = win = pidgin_create_window(_("Buddy Pounces"), PIDGIN_HIG_BORDER, "pounces", TRUE); gtk_window_set_default_size(GTK_WINDOW(win), width, height); + gtk_window_set_transient_for(GTK_WINDOW(win), parent); g_signal_connect(G_OBJECT(win), "delete_event", G_CALLBACK(pounces_manager_destroy_cb), dialog);
--- a/pidgin/gtkpounce.h Fri Sep 21 16:09:12 2007 +0000 +++ b/pidgin/gtkpounce.h Sat Sep 22 09:48:07 2007 +0000 @@ -35,13 +35,13 @@ * @param name The optional name to pounce on. * @param cur_pounce The current buddy pounce, if editing an existing one. */ -void pidgin_pounce_editor_show(PurpleAccount *account, const char *name, +void pidgin_pounce_editor_show(GtkWindow *parent, PurpleAccount *account, const char *name, PurplePounce *cur_pounce); /** * Shows the pounces manager window. */ -void pidgin_pounces_manager_show(void); +void pidgin_pounces_manager_show(GtkWindow *parent); /** * Hides the pounces manager window.
--- a/pidgin/gtkprefs.c Fri Sep 21 16:09:12 2007 +0000 +++ b/pidgin/gtkprefs.c Sat Sep 22 09:48:07 2007 +0000 @@ -641,7 +641,8 @@ static void add_theme_button_clicked_cb(GtkWidget *widget, gpointer null) { - purple_request_file(NULL, _("Install Theme"), NULL, FALSE, (GCallback)request_theme_file_name_cb, NULL, NULL, NULL, NULL, NULL) ; + purple_request_file(NULL, _("Install Theme"), NULL, FALSE, + (GCallback)request_theme_file_name_cb, NULL, NULL, NULL, NULL, "preferences", NULL) ; } static void @@ -1626,7 +1627,7 @@ purple_request_file(prefs, _("Sound Selection"), filename, FALSE, G_CALLBACK(sound_chosen_cb), NULL, - NULL, NULL, NULL, + NULL, NULL, NULL, "preferences", GINT_TO_POINTER(sound_row_sel)); }
--- a/pidgin/gtkprivacy.c Fri Sep 21 16:09:12 2007 +0000 +++ b/pidgin/gtkprivacy.c Sat Sep 22 09:48:07 2007 +0000 @@ -562,7 +562,7 @@ _("_Permit"), G_CALLBACK(add_permit_block_cb), _("Cancel"), G_CALLBACK(destroy_request_data), account, name, NULL, - data); + "privacy", data); } else { char *primary = g_strdup_printf(_("Allow %s to contact you?"), name); @@ -574,7 +574,7 @@ purple_request_action(account, _("Permit User"), primary, secondary, 0, account, name, NULL, - data, 2, + "privacy", data, 2, _("_Permit"), G_CALLBACK(confirm_permit_block_cb), _("Cancel"), G_CALLBACK(destroy_request_data)); @@ -603,7 +603,7 @@ _("_Block"), G_CALLBACK(add_permit_block_cb), _("Cancel"), G_CALLBACK(destroy_request_data), account, name, NULL, - data); + "privacy", data); } else { char *primary = g_strdup_printf(_("Block %s?"), name); @@ -613,7 +613,7 @@ purple_request_action(account, _("Block User"), primary, secondary, 0, account, name, NULL, - data, 2, + "privacy", data, 2, _("_Block"), G_CALLBACK(confirm_permit_block_cb), _("Cancel"), G_CALLBACK(destroy_request_data));
--- a/pidgin/gtkrequest.c Fri Sep 21 16:09:12 2007 +0000 +++ b/pidgin/gtkrequest.c Sat Sep 22 09:48:07 2007 +0000 @@ -34,6 +34,7 @@ #include "gtkrequest.h" #include "gtkutils.h" #include "pidginstock.h" +#include "gtkblist.h" #include <gdk/gdkkeysyms.h> @@ -79,6 +80,55 @@ } PidginRequestData; +static GtkWindow * +find_toplevel(GList *ll_toplevels, const char *role) +{ + const char *window_role = NULL; + GList *ll_itr = NULL; + + for (ll_itr = ll_toplevels ; ll_itr ; ll_itr = ll_itr->next) { + if ((window_role = gtk_window_get_role(GTK_WINDOW(ll_itr->data))) != NULL) { + if (!strcmp(window_role, role)) + return GTK_WINDOW(ll_itr->data); + } + } + + return NULL; +} + +static GtkWindow * +get_request_parent(const char *ui_hint, PidginConversation *convo) +{ + GtkWindow *toplevel = NULL; + PidginBuddyList *blist = NULL; + + if (convo) + return GTK_WINDOW(convo->win->window); + + if (strcmp(ui_hint, "blist")) { + GList *ll_toplevels = NULL; + + ll_toplevels = gtk_window_list_toplevels(); + + if (!(toplevel = find_toplevel(ll_toplevels, ui_hint))) { + if (!strcmp(ui_hint, "register-account")) + toplevel = find_toplevel(ll_toplevels, "account"); + else + if (!strcmp(ui_hint, "xfer")) + toplevel = find_toplevel(ll_toplevels, "file transfer"); + } + + g_list_free(ll_toplevels); + } + + /* Takes care of "pidgin-statusbox" as well */ + if (!toplevel) + if ((blist = pidgin_blist_get_default_gtk_blist()) != NULL) + return GTK_WINDOW(blist->window); + + return toplevel; +} + static void generic_response_start(PidginRequestData *data) { @@ -287,7 +337,7 @@ const char *ok_text, GCallback ok_cb, const char *cancel_text, GCallback cancel_cb, PurpleAccount *account, const char *who, PurpleConversation *conv, - void *user_data) + const char *ui_hint, void *user_data) { PidginRequestData *data; GtkWidget *dialog; @@ -312,7 +362,7 @@ /* Create the dialog. */ dialog = gtk_dialog_new_with_buttons(title ? title : PIDGIN_ALERT_TITLE, - NULL, 0, + get_request_parent(ui_hint, conv ? PIDGIN_CONVERSATION(conv) : NULL), 0, text_to_stock(cancel_text), 1, text_to_stock(ok_text), 0, NULL); @@ -450,7 +500,7 @@ const char *ok_text, GCallback ok_cb, const char *cancel_text, GCallback cancel_cb, PurpleAccount *account, const char *who, PurpleConversation *conv, - void *user_data, va_list args) + const char *ui_hint, void *user_data, va_list args) { PidginRequestData *data; GtkWidget *dialog; @@ -474,6 +524,8 @@ /* Create the dialog. */ data->dialog = dialog = gtk_dialog_new(); + gtk_window_set_transient_for(GTK_WINDOW(dialog), + get_request_parent(ui_hint, conv ? PIDGIN_CONVERSATION(conv) : NULL)); if (title != NULL) gtk_window_set_title(GTK_WINDOW(dialog), title); @@ -554,7 +606,7 @@ pidgin_request_action(const char *title, const char *primary, const char *secondary, int default_action, PurpleAccount *account, const char *who, PurpleConversation *conv, - void *user_data, size_t action_count, va_list actions) + const char *ui_hint, void *user_data, size_t action_count, va_list actions) { PidginRequestData *data; GtkWidget *dialog; @@ -584,6 +636,8 @@ /* Create the dialog. */ data->dialog = dialog = gtk_dialog_new(); + gtk_window_set_transient_for(GTK_WINDOW(dialog), + get_request_parent(ui_hint, conv ? PIDGIN_CONVERSATION(conv) : NULL)); #if GTK_CHECK_VERSION(2,10,0) gtk_window_set_deletable(GTK_WINDOW(data->dialog), FALSE); @@ -1051,7 +1105,7 @@ const char *ok_text, GCallback ok_cb, const char *cancel_text, GCallback cancel_cb, PurpleAccount *account, const char *who, PurpleConversation *conv, - void *user_data) + const char *ui_hint, void *user_data) { PidginRequestData *data; GtkWidget *win; @@ -1092,6 +1146,8 @@ #else /* !_WIN32 */ data->dialog = win = pidgin_create_window(title, PIDGIN_HIG_BORDER, "multifield", TRUE) ; #endif /* _WIN32 */ + gtk_window_set_transient_for(GTK_WINDOW(win), + get_request_parent(ui_hint, conv ? PIDGIN_CONVERSATION(conv) : NULL)); g_signal_connect(G_OBJECT(win), "delete_event", G_CALLBACK(destroy_multifield_cb), data); @@ -1507,7 +1563,7 @@ purple_request_action(data, NULL, _("That file already exists"), _("Would you like to overwrite it?"), 0, NULL, NULL, NULL, - data, 2, + "pidgin-request-file", data, 2, _("Overwrite"), G_CALLBACK(file_yes_no_cb), _("Choose New Name"), G_CALLBACK(file_yes_no_cb)); } else @@ -1532,7 +1588,7 @@ gboolean savedialog, GCallback ok_cb, GCallback cancel_cb, PurpleAccount *account, const char *who, PurpleConversation *conv, - void *user_data) + const char *ui_hint, void *user_data) { PidginRequestData *data; GtkWidget *filesel; @@ -1620,6 +1676,9 @@ g_signal_connect(G_OBJECT(GTK_FILE_SELECTION(filesel)->ok_button), "clicked", G_CALLBACK(file_ok_check_if_exists_cb), data); #endif /* FILECHOOSER */ + gtk_window_set_role(GTK_WINDOW(filesel), "pidgin-request-file"); + gtk_window_set_transient_for(GTK_WINDOW(filesel), + get_request_parent(ui_hint, conv ? PIDGIN_CONVERSATION(conv) : NULL)); data->dialog = filesel; gtk_widget_show(filesel); @@ -1631,7 +1690,7 @@ pidgin_request_folder(const char *title, const char *dirname, GCallback ok_cb, GCallback cancel_cb, PurpleAccount *account, const char *who, PurpleConversation *conv, - void *user_data) + const char *ui_hint, void *user_data) { PidginRequestData *data; GtkWidget *dirsel; @@ -1670,6 +1729,9 @@ g_signal_connect(G_OBJECT(GTK_FILE_SELECTION(dirsel)->ok_button), "clicked", G_CALLBACK(file_ok_check_if_exists_cb), data); #endif + gtk_window_set_role(GTK_WINDOW(dirsel), "pidgin-request-dir"); + gtk_window_set_transient_for(GTK_WINDOW(dirsel), + get_request_parent(ui_hint, conv ? PIDGIN_CONVERSATION(conv) : NULL)); data->dialog = dirsel; gtk_widget_show(dirsel);
--- a/pidgin/gtksavedstatuses.c Fri Sep 21 16:09:12 2007 +0000 +++ b/pidgin/gtksavedstatuses.c Sat Sep 22 09:48:07 2007 +0000 @@ -340,7 +340,7 @@ purple_request_action(handle, NULL, title, NULL, 0, NULL, NULL, NULL, - sel_titles, 2, + "statuses", sel_titles, 2, _("Delete"), status_window_delete_confirm_cb, _("Cancel"), status_window_delete_cancel_cb);
--- a/pidgin/gtkstatusbox.c Fri Sep 21 16:09:12 2007 +0000 +++ b/pidgin/gtkstatusbox.c Sat Sep 22 09:48:07 2007 +0000 @@ -1569,7 +1569,7 @@ purple_request_action(saved, NULL, msg, NULL, 0, NULL, NULL, NULL, - data, 2, + "pidgin-statusbox", data, 2, _("Delete"), tree_view_delete_current_selection_cb, _("Cancel"), NULL);
--- a/pidgin/gtkutils.c Fri Sep 21 16:09:12 2007 +0000 +++ b/pidgin/gtkutils.c Sat Sep 22 09:48:07 2007 +0000 @@ -1534,7 +1534,7 @@ DND_FILE_TRANSFER, "OK", (GCallback)dnd_image_ok_callback, "Cancel", (GCallback)dnd_image_cancel_callback, account, who, NULL, - data, + "conversation", data, _("Set as buddy icon"), DND_BUDDY_ICON, _("Send image file"), DND_FILE_TRANSFER, _("Insert in message"), DND_IM_IMAGE, @@ -1544,7 +1544,7 @@ _("Would you like to set it as the buddy icon for this user?"), 0, account, who, NULL, - data, (GCallback)dnd_set_icon_ok_cb, (GCallback)dnd_set_icon_cancel_cb); + "conversation", data, (GCallback)dnd_set_icon_ok_cb, (GCallback)dnd_set_icon_cancel_cb); else purple_request_choice(NULL, NULL, _("You have dragged an image"), @@ -1554,7 +1554,7 @@ "OK", (GCallback)dnd_image_ok_callback, "Cancel", (GCallback)dnd_image_cancel_callback, account, who, NULL, - data, + "conversation", data, _("Set as buddy icon"), DND_BUDDY_ICON, (ft ? _("Send image file") : _("Insert in message")), (ft ? DND_FILE_TRANSFER : DND_IM_IMAGE), NULL);
--- a/pidgin/plugins/perl/common/GtkDialogs.xs Fri Sep 21 16:09:12 2007 +0000 +++ b/pidgin/plugins/perl/common/GtkDialogs.xs Sat Sep 22 09:48:07 2007 +0000 @@ -8,6 +8,8 @@ void pidgin_dialogs_about() +CODE: + pidgin_dialogs_about(NULL); void pidgin_dialogs_im()
--- a/pidgin/plugins/perl/common/GtkLog.xs Fri Sep 21 16:09:12 2007 +0000 +++ b/pidgin/plugins/perl/common/GtkLog.xs Sat Sep 22 09:48:07 2007 +0000 @@ -11,13 +11,19 @@ Purple::LogType type const char * screenname Purple::Account account +CODE: + pidgin_log_show(NULL, type, screenname, account); void pidgin_log_show_contact(contact) Purple::BuddyList::Contact contact +CODE: + pidgin_log_show_contact(NULL, contact); MODULE = Pidgin::Log PACKAGE = Pidgin::SysLog PREFIX = pidgin_syslog_ PROTOTYPES: ENABLE void pidgin_syslog_show() +CODE: + pidgin_syslog_show(NULL);
--- a/pidgin/plugins/perl/common/GtkPlugin.xs Fri Sep 21 16:09:12 2007 +0000 +++ b/pidgin/plugins/perl/common/GtkPlugin.xs Sat Sep 22 09:48:07 2007 +0000 @@ -11,3 +11,5 @@ void pidgin_plugin_dialog_show() +CODE: + pidgin_plugin_dialog_show(NULL);
--- a/pidgin/plugins/perl/common/GtkPounce.xs Fri Sep 21 16:09:12 2007 +0000 +++ b/pidgin/plugins/perl/common/GtkPounce.xs Sat Sep 22 09:48:07 2007 +0000 @@ -8,6 +8,8 @@ Purple::Account account const char * name Purple::Pounce cur_pounce +CODE: + pidgin_pounce_editor_show(NULL, account, name, cur_pounce); MODULE = Pidgin::Pounce PACKAGE = Pidgin::Pounces PREFIX = pidgin_pounces_ PROTOTYPES: ENABLE @@ -20,6 +22,8 @@ void pidgin_pounces_manager_show() +CODE: + pidgin_pounces_manager_show(NULL); void pidgin_pounces_manager_hide()