diff options
75 files changed, 463 insertions, 234 deletions
diff --git a/finch/gntaccount.c b/finch/gntaccount.c index 597a475fde..5990be7ab6 100644 --- a/finch/gntaccount.c +++ b/finch/gntaccount.c @@ -632,7 +632,7 @@ delete_account_cb(GntWidget *widget, GntTree *tree) prompt = g_strdup_printf(_("Are you sure you want to delete %s?"), purple_account_get_username(account)); - purple_request_action(account, _("Delete Account"), prompt, NULL, 0, + purple_request_action_with_hint(account, _("Delete Account"), prompt, NULL, 0, account, NULL, NULL, "accounts", account, 2, _("Delete"), really_delete_account, _("Cancel"), NULL); @@ -881,7 +881,7 @@ request_add(PurpleAccount *account, const char *remote_user, data->alias = (alias != NULL ? g_strdup(alias) : NULL); buffer = make_info(account, gc, remote_user, id, alias, msg); - purple_request_action(NULL, NULL, _("Add buddy to your list?"), + purple_request_action_with_hint(NULL, NULL, _("Add buddy to your list?"), buffer, PURPLE_DEFAULT_ACTION_NONE, account, remote_user, NULL, "blist", data, 2, @@ -969,7 +969,7 @@ finch_request_authorize(PurpleAccount *account, gnt_box_set_title(GNT_BOX(uihandle), _("Authorize buddy?")); gnt_box_set_pad(GNT_BOX(uihandle), 0); - widget = purple_request_action(NULL, _("Authorize buddy?"), buffer, NULL, + widget = purple_request_action_with_hint(NULL, _("Authorize buddy?"), buffer, NULL, PURPLE_DEFAULT_ACTION_NONE, account, remote_user, NULL, "blist", aa, 2, @@ -996,7 +996,7 @@ finch_request_authorize(PurpleAccount *account, g_signal_connect_swapped(G_OBJECT(uihandle), "destroy", G_CALLBACK(free_auth_and_add), aa); } else { - uihandle = purple_request_action(NULL, _("Authorize buddy?"), buffer, NULL, + uihandle = purple_request_action_with_hint(NULL, _("Authorize buddy?"), buffer, NULL, PURPLE_DEFAULT_ACTION_NONE, account, remote_user, NULL, "blist", user_data, 2, diff --git a/finch/gntblist.c b/finch/gntblist.c index 290e03f44b..5e3421c3c9 100644 --- a/finch/gntblist.c +++ b/finch/gntblist.c @@ -338,7 +338,7 @@ finch_request_add_buddy(PurpleAccount *account, const char *username, const char purple_request_field_account_set_value(field, account); purple_request_field_group_add_field(group, field); - purple_request_fields(NULL, _("Add Buddy"), NULL, _("Please enter buddy information."), + purple_request_fields_with_hint(NULL, _("Add Buddy"), NULL, _("Please enter buddy information."), fields, _("Add"), G_CALLBACK(add_buddy_cb), _("Cancel"), NULL, @@ -416,7 +416,7 @@ finch_request_add_chat(PurpleAccount *account, PurpleGroup *grp, const char *ali field = purple_request_field_bool_new("autojoin", _("Auto-join"), FALSE); purple_request_field_group_add_field(group, field); - purple_request_fields(NULL, _("Add Chat"), NULL, + purple_request_fields_with_hint(NULL, _("Add Chat"), NULL, _("You can edit more information from the context menu later."), fields, _("Add"), G_CALLBACK(add_chat_cb), _("Cancel"), NULL, NULL, NULL, NULL, @@ -451,7 +451,7 @@ add_group_cb(gpointer null, const char *group) static void finch_request_add_group() { - purple_request_input(NULL, _("Add Group"), NULL, _("Enter the name of the group"), + purple_request_input_with_hint(NULL, _("Add Group"), NULL, _("Enter the name of the group"), NULL, FALSE, FALSE, NULL, _("Add"), G_CALLBACK(add_group_cb), _("Cancel"), NULL, NULL, NULL, NULL, @@ -799,7 +799,7 @@ chat_components_edit(PurpleBlistNode *selected, PurpleChat *chat) g_list_free(parts); - purple_request_fields(NULL, _("Edit Chat"), NULL, _("Please Update the necessary fields."), + purple_request_fields_with_hint(NULL, _("Edit Chat"), NULL, _("Please Update the necessary fields."), fields, _("Edit"), G_CALLBACK(chat_components_edit_ok), _("Cancel"), NULL, NULL, NULL, NULL, "blist", chat); @@ -1000,7 +1000,7 @@ finch_blist_rename_node_cb(PurpleBlistNode *selected, PurpleBlistNode *node) prompt = g_strdup_printf(_("Please enter the new name for %s"), name); text = PURPLE_BLIST_NODE_IS_GROUP(node) ? _("Rename") : _("Set Alias"); - purple_request_input(node, text, prompt, _("Enter empty string to reset the name."), + purple_request_input_with_hint(node, text, prompt, _("Enter empty string to reset the name."), name, FALSE, FALSE, NULL, text, G_CALLBACK(rename_blist_node), _("Cancel"), NULL, NULL, NULL, NULL, @@ -1092,7 +1092,7 @@ finch_blist_remove_node_cb(PurpleBlistNode *selected, PurpleBlistNode *node) primary = g_strdup_printf(_("Are you sure you want to remove %s?"), name); /* XXX: anything to do with the returned ui-handle? */ - purple_request_action(node, _("Confirm Remove"), + purple_request_action_with_hint(node, _("Confirm Remove"), primary, sec, 1, account, name, NULL, @@ -2213,7 +2213,7 @@ send_im_select(GntMenuItem *item, gpointer n) purple_request_field_set_required(field, TRUE); purple_request_field_group_add_field(group, field); - purple_request_fields(purple_get_blist(), _("New Instant Message"), + purple_request_fields_with_hint(purple_get_blist(), _("New Instant Message"), NULL, _("Please enter the screen name or alias of the person " "you would like to IM."), diff --git a/finch/gntcertmgr.c b/finch/gntcertmgr.c index 5ded4bfa9d..1e3d93fb46 100644 --- a/finch/gntcertmgr.c +++ b/finch/gntcertmgr.c @@ -82,7 +82,7 @@ tls_peers_mgmt_import_ok_cb(gpointer data, const char *filename) if (crt != NULL) { gchar *default_hostname; default_hostname = purple_certificate_get_subject_name(crt); - purple_request_input(NULL, + purple_request_input_with_hint(NULL, _("Certificate Import"), _("Specify a hostname"), _("Type the host name this certificate is for."), @@ -106,7 +106,7 @@ tls_peers_mgmt_import_ok_cb(gpointer data, const char *filename) static void add_cert_cb(GntWidget *button, gpointer null) { - purple_request_file(NULL, + purple_request_file_with_hint(NULL, _("Select a PEM certificate"), "certificate.pem", FALSE, @@ -155,7 +155,7 @@ save_cert_cb(GntWidget *button, gpointer null) return; } - purple_request_file((void*)key, + purple_request_file_with_hint((void*)key, _("PEM X.509 Certificate Export"), "certificate.pem", TRUE, G_CALLBACK(tls_peers_mgmt_export_ok_cb), @@ -233,7 +233,7 @@ delete_cert_cb(GntWidget *button, gpointer null) primary = g_strdup_printf(_("Really delete certificate for %s?"), key); purple_request_close_with_handle((void *)key); - purple_request_yes_no((void *)key, _("Confirm certificate delete"), + purple_request_yes_no_with_hint((void *)key, _("Confirm certificate delete"), primary, NULL, 2, NULL, NULL, NULL, "certmgr", diff --git a/finch/gntconn.c b/finch/gntconn.c index 6a4abdd8ea..bd1e052984 100644 --- a/finch/gntconn.c +++ b/finch/gntconn.c @@ -130,7 +130,7 @@ finch_connection_report_disconnect(PurpleConnection *gc, const char *text) "Finch will not attempt to reconnect the account until you " "correct the error and re-enable the account."), text); - purple_request_action(account, NULL, primary, secondary, 2, + purple_request_action_with_hint(account, NULL, primary, secondary, 2, account, NULL, NULL, "blist", account, 3, _("OK"), NULL, diff --git a/finch/gntplugin.c b/finch/gntplugin.c index 2ce16c0452..c2f5f8004a 100644 --- a/finch/gntplugin.c +++ b/finch/gntplugin.c @@ -375,7 +375,7 @@ process_pref_frame(PurplePluginPrefFrame *frame) } } - return purple_request_fields(NULL, _("Preferences"), NULL, NULL, fields, + return purple_request_fields_with_hint(NULL, _("Preferences"), NULL, NULL, fields, _("Save"), G_CALLBACK(finch_request_save_in_prefs), _("Cancel"), NULL, NULL, NULL, NULL, "plugins", NULL); diff --git a/finch/gntpounce.c b/finch/gntpounce.c index 454a05a371..a2d733490f 100644 --- a/finch/gntpounce.c +++ b/finch/gntpounce.c @@ -660,7 +660,7 @@ pounces_manager_delete_cb(GntButton *button, gpointer user_data) pouncer = purple_account_get_username(account); pouncee = purple_pounce_get_pouncee(pounce); 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, + purple_request_action_with_hint(pounce, NULL, buf, NULL, 0, account, pouncee, NULL, "pounces", pounce, 2, _("Delete"), pounces_manager_delete_confirm_cb, diff --git a/finch/gntprefs.c b/finch/gntprefs.c index 44534a5ca8..0f6d2872af 100644 --- a/finch/gntprefs.c +++ b/finch/gntprefs.c @@ -261,7 +261,7 @@ void finch_prefs_show_all() add_pref_group(fields, _("Idle"), idle); pref_request.showing = TRUE; - pref_request.window = purple_request_fields(NULL, _("Preferences"), NULL, NULL, fields, + pref_request.window = purple_request_fields_with_hint(NULL, _("Preferences"), NULL, NULL, fields, _("Save"), G_CALLBACK(save_cb), _("Cancel"), free_strings, NULL, NULL, NULL, "preferences", NULL); diff --git a/finch/gntstatus.c b/finch/gntstatus.c index a9983ed2a1..f5e5407480 100644 --- a/finch/gntstatus.c +++ b/finch/gntstatus.c @@ -138,7 +138,7 @@ ask_before_delete(GntWidget *button, gpointer null) ask = g_strdup_printf(_("Are you sure you want to delete \"%s\""), purple_savedstatus_get_title(saved)); - purple_request_action(saved, _("Delete Status"), ask, NULL, 0, + purple_request_action_with_hint(saved, _("Delete Status"), ask, NULL, 0, NULL, NULL, NULL, "statuses", saved, 2, _("Delete"), really_delete_status, diff --git a/libpurple/account.c b/libpurple/account.c index 78b32007db..1dd2e8ab89 100644 --- a/libpurple/account.c +++ b/libpurple/account.c @@ -1004,7 +1004,7 @@ purple_account_request_password(PurpleAccount *account, GCallback ok_cb, field = purple_request_field_bool_new("remember", _("Save password"), FALSE); purple_request_field_group_add_field(group, field); - purple_request_fields(account, + purple_request_fields_with_hint(account, NULL, primary, NULL, @@ -1253,7 +1253,7 @@ purple_account_request_change_password(PurpleAccount *account) /* I'm sticking this somewhere in the code: bologna */ - purple_request_fields(purple_account_get_connection(account), + purple_request_fields_with_hint(purple_account_get_connection(account), NULL, primary, _("Please enter your current password and your " @@ -1290,7 +1290,7 @@ purple_account_request_change_user_info(PurpleAccount *account) _("Change user information for %s"), purple_account_get_username(account)); - purple_request_input(gc, _("Set User Info"), primary, NULL, + purple_request_input_with_hint(gc, _("Set User Info"), primary, NULL, purple_account_get_user_info(account), TRUE, FALSE, ((gc != NULL) && (gc->flags & PURPLE_CONNECTION_HTML) ? "html" : NULL), diff --git a/libpurple/certificate.c b/libpurple/certificate.c index 88e0a923b8..b885c2c164 100644 --- a/libpurple/certificate.c +++ b/libpurple/certificate.c @@ -550,7 +550,7 @@ x509_singleuse_start_verify (PurpleCertificateVerificationRequest *vrq) secondary = g_strdup_printf(_("Common name: %s %s\nFingerprint (SHA1): %s"), cn, cn_match, sha_asc); /* Make a semi-pretty display */ - purple_request_accept_cancel( + purple_request_accept_cancel_with_hint( vrq->cb_data, /* TODO: Find what the handle ought to be */ _("Single-use Certificate Verification"), primary, @@ -1173,7 +1173,7 @@ x509_tls_cached_user_auth(PurpleCertificateVerificationRequest *vrq, vrq->subject_name); /* Make a semi-pretty display */ - purple_request_action( + purple_request_action_with_hint( vrq->cb_data, /* TODO: Find what the handle ought to be */ _("SSL Certificate Verification"), primary, diff --git a/libpurple/conversation.c b/libpurple/conversation.c index 81e2f7b545..9829c7578e 100644 --- a/libpurple/conversation.c +++ b/libpurple/conversation.c @@ -1208,7 +1208,7 @@ purple_conv_send_confirm(PurpleConversation *conv, const char *message) data[0] = conv; data[1] = (gpointer)message; - purple_request_action(conv, NULL, _("Send Message"), text, 0, + purple_request_action_with_hint(conv, NULL, _("Send Message"), text, 0, purple_conversation_get_account(conv), NULL, conv, "conversation", data, 2, _("_Send Message"), G_CALLBACK(purple_conv_send_confirm_cb), diff --git a/libpurple/ft.c b/libpurple/ft.c index 65b13edf0a..a3e4073531 100644 --- a/libpurple/ft.c +++ b/libpurple/ft.c @@ -309,7 +309,7 @@ purple_xfer_choose_file_cancel_cb(void *user_data, const char *filename) static int purple_xfer_choose_file(PurpleXfer *xfer) { - purple_request_file(xfer, NULL, purple_xfer_get_filename(xfer), + purple_request_file_with_hint(xfer, NULL, purple_xfer_get_filename(xfer), (purple_xfer_get_type(xfer) == PURPLE_XFER_RECEIVE), G_CALLBACK(purple_xfer_choose_file_ok_cb), G_CALLBACK(purple_xfer_choose_file_cancel_cb), @@ -359,7 +359,7 @@ purple_xfer_ask_recv(PurpleXfer *xfer) serv_got_im(purple_account_get_connection(xfer->account), xfer->who, xfer->message, 0, time(NULL)); - purple_request_accept_cancel(xfer, NULL, buf, NULL, + purple_request_accept_cancel_with_hint(xfer, NULL, buf, NULL, PURPLE_DEFAULT_ACTION_NONE, xfer->account, xfer->who, NULL, "xfer", xfer, @@ -402,7 +402,7 @@ purple_xfer_ask_accept(PurpleXfer *xfer) "Remote host: %s\nRemote port: %d"), purple_xfer_get_remote_ip(xfer), purple_xfer_get_remote_port(xfer)); - purple_request_accept_cancel(xfer, NULL, buf, buf2, + purple_request_accept_cancel_with_hint(xfer, NULL, buf, buf2, PURPLE_DEFAULT_ACTION_NONE, xfer->account, xfer->who, NULL, "xfer", xfer, diff --git a/libpurple/plugins/autoaccept.c b/libpurple/plugins/autoaccept.c index 350336b935..dc6b8f329f 100644 --- a/libpurple/plugins/autoaccept.c +++ b/libpurple/plugins/autoaccept.c @@ -159,7 +159,7 @@ set_auto_accept_settings(PurpleBlistNode *node, gpointer plugin) message = g_strdup_printf(_("When a file-transfer request arrives from %s"), purple_contact_get_alias((PurpleContact *)node)); - purple_request_choice(plugin, _("Set Autoaccept Setting"), message, + purple_request_choice_with_hint(plugin, _("Set Autoaccept Setting"), message, NULL, purple_blist_node_get_int(node, "autoaccept"), _("_Save"), G_CALLBACK(save_cb), _("_Cancel"), NULL, diff --git a/libpurple/plugins/buddynote.c b/libpurple/plugins/buddynote.c index dad68052b8..3ad7a4ae5d 100644 --- a/libpurple/plugins/buddynote.c +++ b/libpurple/plugins/buddynote.c @@ -43,7 +43,7 @@ buddynote_edit_cb(PurpleBlistNode *node, gpointer data) note = purple_blist_node_get_string(node, "notes"); - purple_request_input(node, _("Notes"), + purple_request_input_with_hint(node, _("Notes"), _("Enter your notes below..."), NULL, note, TRUE, FALSE, "html", diff --git a/libpurple/plugins/idle.c b/libpurple/plugins/idle.c index 2f48826cb2..19386cd575 100644 --- a/libpurple/plugins/idle.c +++ b/libpurple/plugins/idle.c @@ -161,7 +161,7 @@ idle_action(PurplePluginAction *action) request = purple_request_fields_new(); purple_request_fields_add_group(request, group); - purple_request_fields(action->plugin, + purple_request_fields_with_hint(action->plugin, N_("I'dle Mak'er"), _("Set Account Idle Time"), NULL, @@ -195,7 +195,7 @@ unidle_action(PurplePluginAction *action) request = purple_request_fields_new(); purple_request_fields_add_group(request, group); - purple_request_fields(action->plugin, + purple_request_fields_with_hint(action->plugin, N_("I'dle Mak'er"), _("Unset Account Idle Time"), NULL, @@ -221,7 +221,7 @@ idle_all_action(PurplePluginAction *action) request = purple_request_fields_new(); purple_request_fields_add_group(request, group); - purple_request_fields(action->plugin, + purple_request_fields_with_hint(action->plugin, N_("I'dle Mak'er"), _("Set Idle Time for All Accounts"), NULL, diff --git a/libpurple/plugins/offlinemsg.c b/libpurple/plugins/offlinemsg.c index ea8dc8ed9c..6c0f34ada8 100644 --- a/libpurple/plugins/offlinemsg.c +++ b/libpurple/plugins/offlinemsg.c @@ -157,7 +157,7 @@ sending_msg_cb(PurpleAccount *account, const char *who, char **message, gpointer "rest of the messages in a pounce and automatically send them " "when \"%s\" logs back in?"), who, who); - purple_request_action(handle, _("Offline Message"), ask, + purple_request_action_with_hint(handle, _("Offline Message"), ask, _("You can edit/delete the pounce from the `Buddy Pounces' dialog"), 1, offline->account, offline->who, offline->conv, diff --git a/libpurple/protocols/gg/gg.c b/libpurple/protocols/gg/gg.c index 1bba29d059..2a2b2f5da8 100644 --- a/libpurple/protocols/gg/gg.c +++ b/libpurple/protocols/gg/gg.c @@ -333,7 +333,7 @@ static void ggp_action_buddylist_save(PurplePluginAction *action) { PurpleConnection *gc = (PurpleConnection *)action->context; - purple_request_file(action, _("Save buddylist..."), NULL, TRUE, + purple_request_file_with_hint(action, _("Save buddylist..."), NULL, TRUE, G_CALLBACK(ggp_callback_buddylist_save_ok), NULL, purple_connection_get_account(gc), NULL, NULL, "blist", gc); @@ -347,7 +347,7 @@ static void ggp_action_buddylist_load(PurplePluginAction *action) { PurpleConnection *gc = (PurpleConnection *)action->context; - purple_request_file(action, "Load buddylist from file...", NULL, FALSE, + purple_request_file_with_hint(action, "Load buddylist from file...", NULL, FALSE, G_CALLBACK(ggp_callback_buddylist_load_ok), NULL, purple_connection_get_account(gc), NULL, NULL, "blist", gc); @@ -498,7 +498,7 @@ static void ggp_register_user_dialog(PurpleConnection *gc) _("Current token"), token->data, token->size); purple_request_field_group_add_field(group, field); - purple_request_fields(account, + purple_request_fields_with_hint(account, _("Register New Gadu-Gadu Account"), _("Register New Gadu-Gadu Account"), _("Please, fill in the following fields"), @@ -657,7 +657,7 @@ static void ggp_find_buddies(PurplePluginAction *action) _("Only online"), FALSE); purple_request_field_group_add_field(group, field); - purple_request_fields(gc, + purple_request_fields_with_hint(gc, _("Find buddies"), _("Find buddies"), _("Please, enter your search criteria below"), @@ -795,7 +795,7 @@ static void ggp_change_passwd_dialog(PurpleConnection *gc) _("Please, enter your current password and your new password for UIN: "), ggp_get_uin(purple_connection_get_account(gc))); - purple_request_fields(gc, + purple_request_fields_with_hint(gc, _("Change Gadu-Gadu Password"), _("Change Gadu-Gadu Password"), msg, @@ -875,7 +875,7 @@ static void ggp_bmenu_add_to_chat(PurpleBlistNode *node, gpointer ignored) msg = g_strdup_printf(_("Select a chat for buddy: %s"), purple_buddy_get_alias(buddy)); - purple_request_fields(gc, + purple_request_fields_with_hint(gc, _("Add to chat..."), _("Add to chat..."), msg, diff --git a/libpurple/protocols/jabber/auth.c b/libpurple/protocols/jabber/auth.c index 59069cae74..068701dfdd 100644 --- a/libpurple/protocols/jabber/auth.c +++ b/libpurple/protocols/jabber/auth.c @@ -318,7 +318,7 @@ static void jabber_auth_start_cyrus(JabberStream *js) } else if (!plaintext) { char *msg = g_strdup_printf(_("%s requires plaintext authentication over an unencrypted connection. Allow this and continue authentication?"), js->gc->account->username); - purple_request_yes_no(js->gc, _("Plaintext Authentication"), + purple_request_yes_no_with_hint(js->gc, _("Plaintext Authentication"), _("Plaintext Authentication"), msg, 2, js->gc->account, NULL, NULL, "account", js->gc->account, @@ -507,7 +507,7 @@ jabber_auth_start(JabberStream *js, xmlnode *packet) if(js->gsc == NULL && !purple_account_get_bool(js->gc->account, "auth_plain_in_clear", FALSE)) { char *msg = g_strdup_printf(_("%s requires plaintext authentication over an unencrypted connection. Allow this and continue authentication?"), js->gc->account->username); - purple_request_yes_no(js->gc, _("Plaintext Authentication"), + purple_request_yes_no_with_hint(js->gc, _("Plaintext Authentication"), _("Plaintext Authentication"), msg, 2, @@ -595,7 +595,7 @@ static void auth_old_cb(JabberStream *js, xmlnode *packet, gpointer data) } else if(xmlnode_get_child(query, "password")) { if(js->gsc == NULL && !purple_account_get_bool(js->gc->account, "auth_plain_in_clear", FALSE)) { - purple_request_yes_no(js->gc, _("Plaintext Authentication"), + purple_request_yes_no_with_hint(js->gc, _("Plaintext Authentication"), _("Plaintext Authentication"), _("This server requires plaintext authentication over an unencrypted connection. Allow this and continue authentication?"), 2, diff --git a/libpurple/protocols/jabber/buddy.c b/libpurple/protocols/jabber/buddy.c index 3afd62c5e6..912c23a61c 100644 --- a/libpurple/protocols/jabber/buddy.c +++ b/libpurple/protocols/jabber/buddy.c @@ -719,7 +719,7 @@ void jabber_setup_set_info(PurplePluginAction *action) if(x_vc_data != NULL) xmlnode_free(x_vc_data); - purple_request_fields(gc, _("Edit XMPP vCard"), + purple_request_fields_with_hint(gc, _("Edit XMPP vCard"), _("Edit XMPP vCard"), _("All items below are optional. Enter only the " "information with which you feel comfortable."), @@ -2410,7 +2410,7 @@ static void user_search_fields_result_cb(JabberStream *js, xmlnode *packet, gpoi usi->js = js; usi->directory_server = g_strdup(from); - purple_request_fields(js->gc, _("Search for XMPP users"), + purple_request_fields_with_hint(js->gc, _("Search for XMPP users"), _("Search for XMPP users"), instructions, fields, _("Search"), G_CALLBACK(user_search_cb), _("Cancel"), G_CALLBACK(user_search_cancel_cb), @@ -2444,7 +2444,7 @@ void jabber_user_search_begin(PurplePluginAction *action) PurpleConnection *gc = (PurpleConnection *) action->context; JabberStream *js = gc->proto_data; - purple_request_input(gc, _("Enter a User Directory"), _("Enter a User Directory"), + purple_request_input_with_hint(gc, _("Enter a User Directory"), _("Enter a User Directory"), _("Select a user directory to search"), js->user_directories ? js->user_directories->data : NULL, FALSE, FALSE, NULL, diff --git a/libpurple/protocols/jabber/chat.c b/libpurple/protocols/jabber/chat.c index 1cd610e460..98817a7f4e 100644 --- a/libpurple/protocols/jabber/chat.c +++ b/libpurple/protocols/jabber/chat.c @@ -778,7 +778,7 @@ PurpleRoomlist *jabber_roomlist_get_list(PurpleConnection *gc) purple_roomlist_set_fields(js->roomlist, fields); - purple_request_input(gc, _("Enter a Conference Server"), _("Enter a Conference Server"), + purple_request_input_with_hint(gc, _("Enter a Conference Server"), _("Enter a Conference Server"), _("Select a conference server to query"), js->chat_servers ? js->chat_servers->data : NULL, FALSE, FALSE, NULL, diff --git a/libpurple/protocols/jabber/jabber.c b/libpurple/protocols/jabber/jabber.c index a1d05ee46f..925d17468d 100644 --- a/libpurple/protocols/jabber/jabber.c +++ b/libpurple/protocols/jabber/jabber.c @@ -1002,7 +1002,7 @@ void jabber_register_parse(JabberStream *js, xmlnode *packet) cbdata->who = g_strdup(from); if(js->registration) - purple_request_fields(js->gc, _("Register New XMPP Account"), + purple_request_fields_with_hint(js->gc, _("Register New XMPP Account"), _("Register New XMPP Account"), instructions, fields, _("Register"), G_CALLBACK(jabber_register_cb), _("Cancel"), G_CALLBACK(jabber_register_cancel_cb), @@ -1011,12 +1011,12 @@ void jabber_register_parse(JabberStream *js, xmlnode *packet) else { char *title = registered?g_strdup_printf(_("Change Account Registration at %s"), from) :g_strdup_printf(_("Register New Account at %s"), from); - purple_request_fields(js->gc, title, + purple_request_fields_with_hint(js->gc, title, title, instructions, fields, registered?_("Change Registration"):_("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); g_free(title); } @@ -1731,7 +1731,7 @@ static void jabber_password_change(PurplePluginAction *action) purple_request_field_set_required(field, TRUE); purple_request_field_group_add_field(group, field); - purple_request_fields(js->gc, _("Change XMPP Password"), + purple_request_fields_with_hint(js->gc, _("Change XMPP Password"), _("Change XMPP Password"), _("Please enter your new password"), fields, _("OK"), G_CALLBACK(jabber_password_change_cb), _("Cancel"), NULL, diff --git a/libpurple/protocols/jabber/presence.c b/libpurple/protocols/jabber/presence.c index d8ebe5b711..d6d0a326a6 100644 --- a/libpurple/protocols/jabber/presence.c +++ b/libpurple/protocols/jabber/presence.c @@ -499,7 +499,7 @@ void jabber_presence_parse(JabberStream *js, xmlnode *packet) if((chat = jabber_chat_find(js, jid->node, jid->domain))) { chat->config_dialog_type = PURPLE_REQUEST_ACTION; chat->config_dialog_handle = - purple_request_action(js->gc, + purple_request_action_with_hint(js->gc, _("Create New Room"), _("Create New Room"), _("You are creating a new room. Would" diff --git a/libpurple/protocols/jabber/si.c b/libpurple/protocols/jabber/si.c index 273f4c3a97..068b8b0601 100644 --- a/libpurple/protocols/jabber/si.c +++ b/libpurple/protocols/jabber/si.c @@ -870,7 +870,7 @@ static void jabber_si_xfer_init(PurpleXfer *xfer) purple_request_fields_add_group(fields, group); - purple_request_fields(jsx->js->gc, _("Select a Resource"), msg, NULL, fields, + purple_request_fields_with_hint(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", xfer); diff --git a/libpurple/protocols/jabber/usermood.c b/libpurple/protocols/jabber/usermood.c index bd30e52dea..5cf6e25d55 100644 --- a/libpurple/protocols/jabber/usermood.c +++ b/libpurple/protocols/jabber/usermood.c @@ -176,7 +176,7 @@ static void do_mood_set_mood(PurplePluginAction *action) { FALSE); purple_request_field_group_add_field(group, field); - purple_request_fields(gc, _("Edit User Mood"), + purple_request_fields_with_hint(gc, _("Edit User Mood"), _("Edit User Mood"), _("Please select your mood from the list."), fields, diff --git a/libpurple/protocols/jabber/usernick.c b/libpurple/protocols/jabber/usernick.c index 618d493aed..230a3a7db2 100644 --- a/libpurple/protocols/jabber/usernick.c +++ b/libpurple/protocols/jabber/usernick.c @@ -73,10 +73,10 @@ static void do_nick_got_own_nick_cb(JabberStream *js, const char *from, xmlnode oldnickname = xmlnode_get_data(nick); } - purple_request_input(js->gc, _("Set User Nickname"), _("Please specify a new nickname for you."), + purple_request_input_with_hint(js->gc, _("Set User Nickname"), _("Please specify a new nickname for you."), _("This information is visible to all contacts on your contact list, so choose something appropriate."), oldnickname, FALSE, FALSE, NULL, _("Set"), PURPLE_CALLBACK(do_nick_set), _("Cancel"), NULL, - purple_connection_get_account(js->gc), NULL, NULL, js); + purple_connection_get_account(js->gc), NULL, NULL, "blist", js); g_free(oldnickname); } diff --git a/libpurple/protocols/jabber/xdata.c b/libpurple/protocols/jabber/xdata.c index cbc5cf7f8d..800b573f63 100644 --- a/libpurple/protocols/jabber/xdata.c +++ b/libpurple/protocols/jabber/xdata.c @@ -395,7 +395,7 @@ void *jabber_x_data_request_with_actions(JabberStream *js, xmlnode *packet, GLis if((x = xmlnode_get_child(packet, "instructions"))) instructions = xmlnode_get_data(x); - handle = purple_request_fields(js->gc, title, title, instructions, fields, + handle = purple_request_fields_with_hint(js->gc, title, title, instructions, fields, _("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, diff --git a/libpurple/protocols/msn/dialog.c b/libpurple/protocols/msn/dialog.c index 5a6d3ef88f..519eabb5f7 100644 --- a/libpurple/protocols/msn/dialog.c +++ b/libpurple/protocols/msn/dialog.c @@ -135,7 +135,7 @@ msn_show_sync_issue(MsnSession *session, const char *passport, passport); } - purple_request_action(gc, NULL, msg, reason, PURPLE_DEFAULT_ACTION_NONE, + purple_request_action_with_hint(gc, NULL, msg, reason, PURPLE_DEFAULT_ACTION_NONE, purple_connection_get_account(gc), data->who, NULL, "blist", data, 2, _("Yes"), G_CALLBACK(msn_add_cb), diff --git a/libpurple/protocols/msn/msn.c b/libpurple/protocols/msn/msn.c index b7c706618e..ebc66e6702 100644 --- a/libpurple/protocols/msn/msn.c +++ b/libpurple/protocols/msn/msn.c @@ -282,7 +282,7 @@ msn_show_set_friendly_name(PurplePluginAction *action) gc = (PurpleConnection *) action->context; - purple_request_input(gc, NULL, _("Set your friendly name."), + purple_request_input_with_hint(gc, NULL, _("Set your friendly name."), _("This is the name that other MSN buddies will " "see you as."), purple_connection_get_display_name(gc), FALSE, FALSE, NULL, @@ -301,7 +301,7 @@ msn_show_set_home_phone(PurplePluginAction *action) gc = (PurpleConnection *) action->context; session = gc->proto_data; - purple_request_input(gc, NULL, _("Set your home phone number."), NULL, + purple_request_input_with_hint(gc, NULL, _("Set your home phone number."), NULL, msn_user_get_home_phone(session->user), FALSE, FALSE, NULL, _("OK"), G_CALLBACK(msn_set_home_phone_cb), _("Cancel"), NULL, @@ -318,7 +318,7 @@ msn_show_set_work_phone(PurplePluginAction *action) gc = (PurpleConnection *) action->context; session = gc->proto_data; - purple_request_input(gc, NULL, _("Set your work phone number."), NULL, + purple_request_input_with_hint(gc, NULL, _("Set your work phone number."), NULL, msn_user_get_work_phone(session->user), FALSE, FALSE, NULL, _("OK"), G_CALLBACK(msn_set_work_phone_cb), _("Cancel"), NULL, @@ -335,7 +335,7 @@ msn_show_set_mobile_phone(PurplePluginAction *action) gc = (PurpleConnection *) action->context; session = gc->proto_data; - purple_request_input(gc, NULL, _("Set your mobile phone number."), NULL, + purple_request_input_with_hint(gc, NULL, _("Set your mobile phone number."), NULL, msn_user_get_mobile_phone(session->user), FALSE, FALSE, NULL, _("OK"), G_CALLBACK(msn_set_mobile_phone_cb), _("Cancel"), NULL, @@ -350,7 +350,7 @@ msn_show_set_mobile_pages(PurplePluginAction *action) gc = (PurpleConnection *) action->context; - purple_request_action(gc, NULL, _("Allow MSN Mobile pages?"), + purple_request_action_with_hint(gc, NULL, _("Allow MSN Mobile pages?"), _("Do you want to allow or disallow people on " "your buddy list to send you MSN Mobile pages " "to your cell phone or other mobile device?"), @@ -400,7 +400,7 @@ show_send_to_mobile_cb(PurpleBlistNode *node, gpointer ignored) data->gc = gc; data->passport = buddy->name; - purple_request_input(gc, NULL, _("Send a mobile message."), NULL, + purple_request_input_with_hint(gc, NULL, _("Send a mobile message."), NULL, NULL, TRUE, FALSE, NULL, _("Page"), G_CALLBACK(send_to_mobile_cb), _("Close"), G_CALLBACK(close_mobile_page_cb), diff --git a/libpurple/protocols/novell/novell.c b/libpurple/protocols/novell/novell.c index 1d4408a1eb..d4b7258aae 100644 --- a/libpurple/protocols/novell/novell.c +++ b/libpurple/protocols/novell/novell.c @@ -1912,7 +1912,7 @@ _evt_conference_invite(NMUser * user, NMEvent * event) /* Prompt the user */ gc = purple_account_get_connection(user->client_data); - purple_request_action(gc, title, primary, secondary, + purple_request_action_with_hint(gc, title, primary, secondary, PURPLE_DEFAULT_ACTION_NONE, purple_connection_get_account(gc), name, NULL, "chat", parms, 2, @@ -2165,7 +2165,7 @@ novell_login(PurpleAccount * account) if (server == NULL || *server == '\0') { /* TODO: Would be nice to prompt if not set! - * purple_request_fields(gc, _("Server Address"),...); + * purple_request_fields_with_hint(gc, _("Server Address"),...); */ /* ...but for now just error out with a nice message. */ diff --git a/libpurple/protocols/oscar/oscar.c b/libpurple/protocols/oscar/oscar.c index 56df52112d..0535df98e6 100644 --- a/libpurple/protocols/oscar/oscar.c +++ b/libpurple/protocols/oscar/oscar.c @@ -1444,7 +1444,7 @@ purple_parse_auth_securid_request(OscarData *od, FlapConnection *conn, FlapFrame purple_debug_info("oscar", "Got SecurID request\n"); primary = g_strdup_printf("Enter the SecurID key for %s.", purple_account_get_username(account)); - purple_request_input(gc, NULL, _("Enter SecurID"), primary, + purple_request_input_with_hint(gc, NULL, _("Enter SecurID"), primary, _("Enter the 6 digit number from the digital display."), FALSE, FALSE, NULL, _("_OK"), G_CALLBACK(purple_parse_auth_securid_request_yes_cb), @@ -2220,7 +2220,7 @@ purple_auth_sendrequest(PurpleConnection *gc, const char *name) data->gc = gc; data->name = g_strdup(name); - purple_request_input(data->gc, NULL, _("Authorization Request Message:"), + purple_request_input_with_hint(data->gc, NULL, _("Authorization Request Message:"), NULL, _("Please authorize me!"), TRUE, FALSE, NULL, _("_OK"), G_CALLBACK(purple_auth_request), _("_Cancel"), G_CALLBACK(purple_auth_dontrequest), @@ -2269,7 +2269,7 @@ static void purple_auth_dontgrant_msgprompt(gpointer cbdata) { struct name_data *data = cbdata; - purple_request_input(data->gc, NULL, _("Authorization Denied Message:"), + purple_request_input_with_hint(data->gc, NULL, _("Authorization Denied Message:"), NULL, _("No reason given."), TRUE, FALSE, NULL, _("_OK"), G_CALLBACK(purple_auth_dontgrant), _("_Cancel"), G_CALLBACK(oscar_free_name_data), @@ -2455,7 +2455,7 @@ incomingim_chan4(OscarData *od, FlapConnection *conn, aim_userinfo_t *userinfo, data->name = g_strdup(text[i*2+1]); data->nick = g_strdup(text[i*2+2]); - purple_request_action(gc, NULL, message, + purple_request_action_with_hint(gc, NULL, message, _("Do you want to add this buddy " "to your buddy list?"), PURPLE_DEFAULT_ACTION_NONE, @@ -5167,7 +5167,7 @@ static int purple_ssi_authgiven(OscarData *od, FlapConnection *conn, FlapFrame * data->name = g_strdup(sn); data->nick = (buddy ? g_strdup(purple_buddy_get_alias_only(buddy)) : NULL); - purple_request_yes_no(gc, NULL, _("Authorization Given"), dialog_msg, + purple_request_yes_no_with_hint(gc, NULL, _("Authorization Given"), dialog_msg, PURPLE_DEFAULT_ACTION_NONE, purple_connection_get_account(gc), sn, NULL, "blist", data, @@ -5866,7 +5866,7 @@ static void oscar_buddycb_edit_comment(PurpleBlistNode *node, gpointer ignore) { data->nick = g_strdup(purple_buddy_get_alias_only(buddy)); title = g_strdup_printf(_("Buddy Comment for %s"), data->name); - purple_request_input(gc, title, _("Buddy Comment:"), NULL, + purple_request_input_with_hint(gc, title, _("Buddy Comment:"), NULL, comment_utf8, TRUE, FALSE, NULL, _("_OK"), G_CALLBACK(oscar_ssi_editcomment), _("_Cancel"), G_CALLBACK(oscar_free_name_data), @@ -5916,7 +5916,7 @@ oscar_ask_directim(gpointer object, gpointer ignored) buf = g_strdup_printf(_("You have selected to open a Direct IM connection with %s."), buddy->name); - purple_request_action(gc, NULL, buf, + purple_request_action_with_hint(gc, NULL, buf, _("Because this reveals your IP address, it " "may be considered a security risk. Do you " "wish to continue?"), @@ -6074,7 +6074,7 @@ oscar_show_icq_privacy_opts(PurplePluginAction *action) purple_request_fields_add_group(fields, g); - purple_request_fields(gc, _("ICQ Privacy Options"), _("ICQ Privacy Options"), + purple_request_fields_with_hint(gc, _("ICQ Privacy Options"), _("ICQ Privacy Options"), NULL, fields, _("OK"), G_CALLBACK(oscar_icq_privacy_opts), _("Cancel"), NULL, @@ -6147,7 +6147,7 @@ static void oscar_change_email(PurpleConnection *gc, const char *email) static void oscar_show_change_email(PurplePluginAction *action) { PurpleConnection *gc = (PurpleConnection *) action->context; - purple_request_input(gc, NULL, _("Change Address To:"), NULL, NULL, + purple_request_input_with_hint(gc, NULL, _("Change Address To:"), NULL, NULL, FALSE, FALSE, NULL, _("_OK"), G_CALLBACK(oscar_change_email), _("_Cancel"), NULL, @@ -6214,7 +6214,7 @@ static void search_by_email_cb(PurpleConnection *gc, const char *email) static void oscar_show_find_email(PurplePluginAction *action) { PurpleConnection *gc = (PurpleConnection *) action->context; - purple_request_input(gc, _("Find Buddy by E-Mail"), + purple_request_input_with_hint(gc, _("Find Buddy by E-Mail"), _("Search for a buddy by e-mail address"), _("Type the e-mail address of the buddy you are " "searching for."), diff --git a/libpurple/protocols/oscar/peer.c b/libpurple/protocols/oscar/peer.c index d08b123738..5d92de31ae 100644 --- a/libpurple/protocols/oscar/peer.c +++ b/libpurple/protocols/oscar/peer.c @@ -1033,7 +1033,7 @@ peer_connection_got_proposition(OscarData *od, const gchar *sn, const gchar *mes buf = g_strdup_printf(_("%s has just asked to directly connect to %s"), sn, purple_account_get_username(account)); - purple_request_action(conn, NULL, buf, + purple_request_action_with_hint(conn, NULL, buf, _("This requires a direct connection between " "the two computers and is necessary for IM " "Images. Because your IP address will be " diff --git a/libpurple/protocols/qq/buddy_info.c b/libpurple/protocols/qq/buddy_info.c index 7166548d7f..7bd4586431 100644 --- a/libpurple/protocols/qq/buddy_info.c +++ b/libpurple/protocols/qq/buddy_info.c @@ -478,7 +478,7 @@ static void create_modify_info_dialogue(PurpleConnection *gc, const contact_info mid->info->qq_show = g_strdup(info->qq_show); mid->info->unknown6 = g_strdup(info->unknown6); - purple_request_fields(gc, _("Modify my information"), + purple_request_fields_with_hint(gc, _("Modify my information"), _("Modify my information"), NULL, fields, _("Update my information"), G_CALLBACK(modify_info_ok_cb), _("Cancel"), G_CALLBACK(modify_info_cancel_cb), diff --git a/libpurple/protocols/qq/buddy_opt.c b/libpurple/protocols/qq/buddy_opt.c index c66f5298e0..4eceefa3ab 100644 --- a/libpurple/protocols/qq/buddy_opt.c +++ b/libpurple/protocols/qq/buddy_opt.c @@ -209,7 +209,7 @@ void qq_reject_add_request_with_gc_and_uid(gc_and_uid *g) msg2 = g_strdup(_("Input your reason:")); nombre = uid_to_purple_name(uid); - purple_request_input(gc, _("Reject request"), msg1, msg2, + purple_request_input_with_hint(gc, _("Reject request"), msg1, msg2, _("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, @@ -402,7 +402,7 @@ void qq_process_add_buddy_reply(guint8 *buf, gint buf_len, guint16 seq, PurpleCo g->gc = gc; g->uid = for_uid; msg = g_strdup_printf(_("User %d needs authentication"), for_uid); - purple_request_input(gc, NULL, msg, + purple_request_input_with_hint(gc, NULL, msg, _("Input request here"), /* TODO: Awkward string to fix post string freeze - standardize auth dialogues? -evands */ _("Would you be my friend?"), TRUE, FALSE, NULL, _("Send"), diff --git a/libpurple/protocols/qq/group.c b/libpurple/protocols/qq/group.c index 245be55bc8..715ac4866e 100644 --- a/libpurple/protocols/qq/group.c +++ b/libpurple/protocols/qq/group.c @@ -116,7 +116,7 @@ PurpleRoomlist *qq_roomlist_get_list(PurpleConnection *gc) purple_roomlist_set_fields(rl, fields); purple_roomlist_set_in_progress(qd->roomlist, TRUE); - purple_request_input(gc, _("QQ Qun"), + purple_request_input_with_hint(gc, _("QQ Qun"), _("Please enter external group ID"), _("You can only search for permanent QQ groups\n"), NULL, FALSE, FALSE, NULL, diff --git a/libpurple/protocols/qq/group_im.c b/libpurple/protocols/qq/group_im.c index b2a35f721c..b1885ca482 100644 --- a/libpurple/protocols/qq/group_im.c +++ b/libpurple/protocols/qq/group_im.c @@ -133,7 +133,7 @@ void qq_process_recv_group_im_apply_join nombre = uid_to_purple_name(user_uid); - purple_request_action(gc, _("QQ Qun Operation"), + purple_request_action_with_hint(gc, _("QQ Qun Operation"), msg, reason, 2, purple_connection_get_account(gc), nombre, NULL, diff --git a/libpurple/protocols/qq/group_join.c b/libpurple/protocols/qq/group_join.c index f346ece8b3..7ef53ec27e 100644 --- a/libpurple/protocols/qq/group_join.c +++ b/libpurple/protocols/qq/group_join.c @@ -132,7 +132,7 @@ static void _qq_group_join_auth(PurpleConnection *gc, qq_group *group) g = g_new0(gc_and_uid, 1); g->gc = gc; g->uid = group->internal_group_id; - purple_request_input(gc, NULL, msg, + purple_request_input_with_hint(gc, NULL, msg, _("Input request here"), _("Would you be my friend?"), TRUE, FALSE, NULL, _("Send"), @@ -356,7 +356,7 @@ void qq_group_exit(PurpleConnection *gc, GHashTable *data) g->gc = gc; g->uid = internal_group_id; - purple_request_action(gc, _("QQ Qun Operation"), + purple_request_action_with_hint(gc, _("QQ Qun Operation"), _("Are you sure you want to leave this Qun?"), _ ("Note, if you are the creator, \nthis operation will eventually remove this Qun."), diff --git a/libpurple/protocols/qq/group_opt.c b/libpurple/protocols/qq/group_opt.c index 97d65b3921..0d9bde5710 100644 --- a/libpurple/protocols/qq/group_opt.c +++ b/libpurple/protocols/qq/group_opt.c @@ -121,7 +121,7 @@ void qq_group_search_application_with_struct(group_member_opt *g) g_return_if_fail(g != NULL && g->gc != NULL && g->member > 0); 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_request_action_with_hint(g->gc, NULL, _("Do you want to approve the request?"), "", 2, purple_connection_get_account(g->gc), NULL, NULL, "chat", g, 2, _("Reject"), G_CALLBACK(qq_group_reject_application_with_struct), @@ -137,7 +137,7 @@ void qq_group_reject_application_with_struct(group_member_opt *g) msg2 = g_strdup(_("Enter your reason:")); nombre = uid_to_purple_name(g->member); - purple_request_input(g->gc, /* title */ NULL, msg1, msg2, + purple_request_input_with_hint(g->gc, /* title */ NULL, msg1, msg2, _("Sorry, you are not my type..."), /* multiline */ TRUE, /* masked */ FALSE, /* hint */ NULL, _("Send"), G_CALLBACK(_qq_group_reject_application_real), @@ -388,7 +388,7 @@ void qq_group_process_create_group_reply(guint8 *data, guint8 **cursor, gint len g->gc = gc; g->uid = internal_group_id; - purple_request_action(gc, _("QQ Qun Operation"), + purple_request_action_with_hint(gc, _("QQ Qun Operation"), _("You have successfully created a Qun"), _ ("Would you like to set up the Qun details now?"), diff --git a/libpurple/protocols/qq/qq.c b/libpurple/protocols/qq/qq.c index 55d19113e1..8a5298160f 100644 --- a/libpurple/protocols/qq/qq.c +++ b/libpurple/protocols/qq/qq.c @@ -417,9 +417,9 @@ static void _qq_menu_block_buddy(PurpleBlistNode * node) g->gc = gc; g->uid = uid; - purple_request_action(gc, _("Block Buddy"), + purple_request_action_with_hint(gc, _("Block Buddy"), _("Are you sure you want to block this buddy?"), NULL, - 1, g, 2, + 1, g, "blist", 2, _("Cancel"), G_CALLBACK(qq_do_nothing_with_gc_and_uid), _("Block"), G_CALLBACK(qq_block_buddy_with_gc_and_uid)); @@ -470,11 +470,11 @@ static void _qq_menu_search_or_add_permanent_group(PurplePluginAction *action) static void _qq_menu_create_permanent_group(PurplePluginAction * action) { PurpleConnection *gc = (PurpleConnection *) action->context; - purple_request_input(gc, _("Create QQ Qun"), + purple_request_input_with_hint(gc, _("Create QQ Qun"), _("Input Qun name here"), _("Only QQ members can create permanent Qun"), "OpenQ", FALSE, FALSE, NULL, - _("Create"), G_CALLBACK(qq_group_create_with_name), _("Cancel"), NULL, gc); + _("Create"), G_CALLBACK(qq_group_create_with_name), _("Cancel"), NULL, "blist", gc); } */ diff --git a/libpurple/protocols/qq/sys_msg.c b/libpurple/protocols/qq/sys_msg.c index 1bfddffd05..8d15c75d82 100644 --- a/libpurple/protocols/qq/sys_msg.c +++ b/libpurple/protocols/qq/sys_msg.c @@ -165,7 +165,7 @@ static void _qq_process_msg_sys_being_added(PurpleConnection *gc, gchar *from, g g->uid = uid; /* only need to get value */ message = g_strdup_printf(_("You have been added by %s"), from); _qq_sys_msg_log_write(gc, message, from); - purple_request_action(gc, NULL, message, + purple_request_action_with_hint(gc, NULL, message, _("Would you like to add him?"), 2, purple_connection_get_account(gc), name, NULL, "buddy", g, 3, @@ -259,7 +259,7 @@ static void _qq_process_msg_sys_add_contact_request(PurpleConnection *gc, gchar g2->gc = gc; g2->uid = strtol(from, NULL, 10); message = g_strdup_printf(_("%s is not in your buddy list"), from); - purple_request_action(gc, NULL, message, + purple_request_action_with_hint(gc, NULL, message, _("Would you like to add him?"), 2, purple_connection_get_account(gc), name, NULL, "blist", g2, 3, diff --git a/libpurple/protocols/sametime/sametime.c b/libpurple/protocols/sametime/sametime.c index 4ef0cdb105..b8aca73c2c 100644 --- a/libpurple/protocols/sametime/sametime.c +++ b/libpurple/protocols/sametime/sametime.c @@ -3382,7 +3382,7 @@ static void blist_menu_conf_create(PurpleBuddy *buddy, const char *msg) { " message to be sent to %s"); msg1 = g_strdup_printf(msgB, buddy->name); - purple_request_fields(gc, _("New Conference"), + purple_request_fields_with_hint(gc, _("New Conference"), msgA, msg1, fields, _("Create"), G_CALLBACK(conf_create_prompt_join), _("Cancel"), G_CALLBACK(conf_create_prompt_cancel), @@ -3468,7 +3468,7 @@ static void blist_menu_conf_list(PurpleBuddy *buddy, " create a new conference to invite this user to."); msg = g_strdup_printf(msgB, buddy->name); - purple_request_fields(gc, _("Invite to Conference"), + purple_request_fields_with_hint(gc, _("Invite to Conference"), msgA, msg, fields, _("Invite"), G_CALLBACK(conf_select_prompt_invite), _("Cancel"), G_CALLBACK(conf_select_prompt_cancel), @@ -3638,7 +3638,7 @@ static void prompt_host(PurpleConnection *gc) { " continue logging in."); msg = g_strdup_printf(msgA, NSTR(purple_account_get_username(acct))); - purple_request_input(gc, _("Meanwhile Connection Setup"), + purple_request_input_with_hint(gc, _("Meanwhile Connection Setup"), _("No Sametime Community Server Specified"), msg, MW_PLUGIN_DEFAULT_HOST, FALSE, FALSE, NULL, _("Connect"), G_CALLBACK(prompt_host_ok_cb), @@ -5215,7 +5215,7 @@ static void st_import_action(PurplePluginAction *act) { title = g_strdup_printf(_("Import Sametime List for Account %s"), purple_account_get_username(account)); - purple_request_file(gc, title, NULL, FALSE, + purple_request_file_with_hint(gc, title, NULL, FALSE, G_CALLBACK(st_import_action_cb), NULL, account, NULL, NULL, "blist", gc); @@ -5255,7 +5255,7 @@ static void st_export_action(PurplePluginAction *act) { title = g_strdup_printf(_("Export Sametime List for Account %s"), purple_account_get_username(account)); - purple_request_file(gc, title, NULL, TRUE, + purple_request_file_with_hint(gc, title, NULL, TRUE, G_CALLBACK(st_export_action_cb), NULL, account, NULL, NULL, "blist", gc); @@ -5391,7 +5391,7 @@ static void remote_group_multi(struct mwResolveResult *result, " the list below to add it to your buddy list."); msg = g_strdup_printf(msgB, result->name); - purple_request_fields(gc, _("Select Notes Address Book"), + purple_request_fields_with_hint(gc, _("Select Notes Address Book"), msgA, msg, fields, _("Add Group"), G_CALLBACK(remote_group_multi_cb), _("Cancel"), G_CALLBACK(remote_group_multi_cleanup), @@ -5481,7 +5481,7 @@ static void remote_group_action(PurplePluginAction *act) { msgB = _("Enter the name of a Notes Address Book group in the field below" " to add the group and its members to your buddy list."); - purple_request_input(gc, _("Add Group"), msgA, msgB, NULL, + purple_request_input_with_hint(gc, _("Add Group"), msgA, msgB, NULL, FALSE, FALSE, NULL, _("Add"), G_CALLBACK(remote_group_action_cb), _("Cancel"), NULL, @@ -5606,7 +5606,7 @@ static void search_action(PurplePluginAction *act) { msgB = _("Enter a name or partial ID in the field below to search" " for matching users in your Sametime community."); - purple_request_input(gc, _("User Search"), msgA, msgB, NULL, + purple_request_input_with_hint(gc, _("User Search"), msgA, msgB, NULL, FALSE, FALSE, NULL, _("Search"), G_CALLBACK(search_action_cb), _("Cancel"), NULL, diff --git a/libpurple/protocols/silc/buddy.c b/libpurple/protocols/silc/buddy.c index 4688a68c44..c566ed1e8a 100644 --- a/libpurple/protocols/silc/buddy.c +++ b/libpurple/protocols/silc/buddy.c @@ -312,9 +312,9 @@ void silcpurple_buddy_keyagr_request(SilcClient client, a->hostname = strdup(hostname); a->port = port; - purple_request_action(client->application, _("Key Agreement Request"), tmp, + purple_request_action_with_hint(client->application, _("Key Agreement Request"), tmp, hostname ? tmp2 : NULL, 1, gc->account, client_entry->nickname, - NULL, a, 2, _("Yes"), G_CALLBACK(silcpurple_buddy_keyagr_request_cb), + NULL, "blist", a, 2, _("Yes"), G_CALLBACK(silcpurple_buddy_keyagr_request_cb), _("No"), G_CALLBACK(silcpurple_buddy_keyagr_request_cb)); } @@ -449,11 +449,11 @@ silcpurple_buddy_privkey(PurpleConnection *gc, const char *name) p->client = sg->client; p->conn = sg->conn; p->client_id = client_entry->id; - purple_request_input(gc, _("IM With Password"), NULL, + purple_request_input_with_hint(gc, _("IM With Password"), NULL, _("Set IM Password"), NULL, FALSE, TRUE, NULL, _("OK"), G_CALLBACK(silcpurple_buddy_privkey_cb), _("Cancel"), G_CALLBACK(silcpurple_buddy_privkey_cb), - gc->account, NULL, NULL, p); + gc->account, NULL, NULL, "blist", p); silc_client_list_free(sg->client, sg->conn, clients); } @@ -1056,10 +1056,10 @@ silcpurple_add_buddy_ask_pk_cb(SilcPurpleBuddyRes r, gint id) } /* Open file selector to select the public key. */ - purple_request_file(r->client->application, _("Open..."), NULL, FALSE, + purple_request_file_with_hint(r->client->application, _("Open..."), NULL, FALSE, G_CALLBACK(silcpurple_add_buddy_ask_import), G_CALLBACK(silcpurple_add_buddy_ask_pk_cancel), - purple_buddy_get_account(r->b), purple_buddy_get_name(r->b), NULL, r); + purple_buddy_get_account(r->b), purple_buddy_get_name(r->b), NULL, "blist", r); } @@ -1069,10 +1069,10 @@ silcpurple_add_buddy_ask_pk(SilcPurpleBuddyRes r) char tmp[512]; g_snprintf(tmp, sizeof(tmp), _("The %s buddy is not present in the network"), r->b->name); - purple_request_action(r->client->application, _("Add Buddy"), tmp, + purple_request_action_with_hint(r->client->application, _("Add Buddy"), tmp, _("To add the buddy you must import his/her public key. " "Press Import to import a public key."), 0, - purple_buddy_get_account(r->b), purple_buddy_get_name(r->b), NULL, r, 2, + purple_buddy_get_account(r->b), purple_buddy_get_name(r->b), NULL, "blist", r, 2, _("Cancel"), G_CALLBACK(silcpurple_add_buddy_ask_pk_cb), _("_Import..."), G_CALLBACK(silcpurple_add_buddy_ask_pk_cb)); } @@ -1179,7 +1179,7 @@ silcpurple_add_buddy_select(SilcPurpleBuddyRes r, SilcDList clients) silc_free(fingerprint); } - purple_request_fields(r->client->application, _("Add Buddy"), + purple_request_fields_with_hint(r->client->application, _("Add Buddy"), _("Select correct user"), r->pubkey_search ? _("More than one user was found with the same public key. Select " @@ -1189,7 +1189,7 @@ silcpurple_add_buddy_select(SilcPurpleBuddyRes r, SilcDList clients) fields, _("OK"), G_CALLBACK(silcpurple_add_buddy_select_cb), _("Cancel"), G_CALLBACK(silcpurple_add_buddy_select_cancel), - purple_buddy_get_account(r->b), purple_buddy_get_name(r->b), NULL, r); + purple_buddy_get_account(r->b), purple_buddy_get_name(r->b), NULL, "blist", r); } static void diff --git a/libpurple/protocols/silc/chat.c b/libpurple/protocols/silc/chat.c index c50abcf220..abb97ab3c1 100644 --- a/libpurple/protocols/silc/chat.c +++ b/libpurple/protocols/silc/chat.c @@ -301,10 +301,10 @@ silcpurple_chat_chpk_cb(SilcPurpleChauth sgc, PurpleRequestFields *fields) f = purple_request_fields_get_field(fields, "list"); if (!purple_request_field_list_get_selected(f)) { /* Add new public key */ - purple_request_file(sg->gc, _("Open Public Key..."), NULL, FALSE, + purple_request_file)with_hint(sg->gc, _("Open Public Key..."), NULL, FALSE, G_CALLBACK(silcpurple_chat_chpk_add), G_CALLBACK(silcpurple_chat_chpk_cancel), - purple_connection_get_account(sg->gc), NULL, NULL, sgc); + purple_connection_get_account(sg->gc), NULL, NULL, "conversation", sgc); return; } @@ -441,11 +441,11 @@ void silcpurple_chat_chauth_show(SilcPurple sg, SilcChannelEntry channel, if (!channel_pubkeys || !silc_dlist_count(channel_pubkeys)) { f = purple_request_field_list_new("list", NULL); purple_request_field_group_add_field(g, f); - purple_request_fields(sg->gc, _("Channel Authentication"), + purple_request_fields_with_hint(sg->gc, _("Channel Authentication"), _("Channel Authentication"), t, fields, _("Add / Remove"), G_CALLBACK(silcpurple_chat_chpk_cb), _("OK"), G_CALLBACK(silcpurple_chat_chauth_ok), - purple_connection_get_account(sg->gc), NULL, NULL, sgc); + purple_connection_get_account(sg->gc), NULL, NULL, "conversation", sgc); if (channel_pubkeys) silc_dlist_uninit(channel_pubkeys); return; @@ -476,11 +476,11 @@ void silcpurple_chat_chauth_show(SilcPurple sg, SilcChannelEntry channel, } purple_request_field_list_set_multi_select(f, FALSE); - purple_request_fields(sg->gc, _("Channel Authentication"), + purple_request_fields_with_hint(sg->gc, _("Channel Authentication"), _("Channel Authentication"), t, fields, _("Add / Remove"), G_CALLBACK(silcpurple_chat_chpk_cb), _("OK"), G_CALLBACK(silcpurple_chat_chauth_ok), - purple_connection_get_account(sg->gc), NULL, NULL, sgc); + purple_connection_get_account(sg->gc), NULL, NULL, "conversation", sgc); } static void @@ -611,10 +611,10 @@ silcpurple_chat_prv(PurpleBlistNode *node, gpointer data) g_snprintf(tmp, sizeof(tmp), _("Please enter the %s channel private group name and passphrase."), p->channel); - purple_request_fields(gc, _("Add Channel Private Group"), NULL, tmp, fields, + purple_request_fields_with_hint(gc, _("Add Channel Private Group"), NULL, tmp, fields, _("Add"), G_CALLBACK(silcpurple_chat_prv_add), _("Cancel"), G_CALLBACK(silcpurple_chat_prv_cancel), - purple_connection_get_account(gc), NULL, NULL, p); + purple_connection_get_account(gc), NULL, NULL, "conversation", p); } @@ -739,12 +739,12 @@ silcpurple_chat_ulimit(PurpleBlistNode *node, gpointer data) s->channel = ch; s->sg = sg; g_snprintf(tmp, sizeof(tmp), "%d", (int)channel->user_limit); - purple_request_input(gc, _("User Limit"), NULL, + purple_request_input_with_hint(gc, _("User Limit"), NULL, _("Set user limit on channel. Set to zero to reset user limit."), tmp, FALSE, FALSE, NULL, _("OK"), G_CALLBACK(silcpurple_chat_ulimit_cb), _("Cancel"), G_CALLBACK(silcpurple_chat_ulimit_cb), - purple_connection_get_account(gc), NULL, NULL, s); + purple_connection_get_account(gc), NULL, NULL, "conversation", s); } static void diff --git a/libpurple/protocols/silc/ops.c b/libpurple/protocols/silc/ops.c index 80fc90fadf..fca3dad9ca 100644 --- a/libpurple/protocols/silc/ops.c +++ b/libpurple/protocols/silc/ops.c @@ -1810,11 +1810,11 @@ silc_ask_passphrase(SilcClient client, SilcClientConnection conn, return; internal->u.ask_pass = completion; internal->context = context; - purple_request_input(gc, _("Passphrase"), NULL, + purple_request_input_with_hint(gc, _("Passphrase"), NULL, _("Passphrase required"), NULL, FALSE, TRUE, NULL, _("OK"), G_CALLBACK(silc_ask_passphrase_cb), _("Cancel"), G_CALLBACK(silc_ask_passphrase_cb), - purple_connection_get_account(gc), NULL, NULL, internal); + purple_connection_get_account(gc), NULL, NULL, "blist", internal); } diff --git a/libpurple/protocols/silc/pk.c b/libpurple/protocols/silc/pk.c index 41be306679..376e7a26d8 100644 --- a/libpurple/protocols/silc/pk.c +++ b/libpurple/protocols/silc/pk.c @@ -107,9 +107,9 @@ static void silcpurple_verify_ask(const char *entity, _("Fingerprint and babbleprint for the %s key are:\n\n" "%s\n%s\n"), entity, fingerprint, babbleprint); - purple_request_action(gc, _("Verify Public Key"), tmp, tmp2, + purple_request_action_with_hint(gc, _("Verify Public Key"), tmp, tmp2, PURPLE_DEFAULT_ACTION_NONE, - purple_connection_get_account(gc), entity, NULL, verify, 3, + purple_connection_get_account(gc), entity, NULL, "blist", verify, 3, _("Yes"), G_CALLBACK(silcpurple_verify_cb), _("No"), G_CALLBACK(silcpurple_verify_cb), _("_View..."), G_CALLBACK(silcpurple_verify_details)); diff --git a/libpurple/protocols/silc/silc.c b/libpurple/protocols/silc/silc.c index cc3774b2ec..7209cf3858 100644 --- a/libpurple/protocols/silc/silc.c +++ b/libpurple/protocols/silc/silc.c @@ -813,7 +813,7 @@ silcpurple_attrs(PurplePluginAction *action) purple_request_field_group_add_field(g, f); purple_request_fields_add_group(fields, g); - purple_request_fields(gc, _("User Online Status Attributes"), + purple_request_fields_with_hint(gc, _("User Online Status Attributes"), _("User Online Status Attributes"), _("You can let other users see your online status information " "and your personal information. Please fill the information " @@ -821,7 +821,7 @@ silcpurple_attrs(PurplePluginAction *action) fields, _("OK"), G_CALLBACK(silcpurple_attrs_cb), _("Cancel"), G_CALLBACK(silcpurple_attrs_cancel), - gc->account, NULL, NULL, gc); + gc->account, NULL, NULL, "blist", gc); } static void @@ -1025,11 +1025,11 @@ silcpurple_create_keypair(PurplePluginAction *action) purple_request_field_group_add_field(g, f); purple_request_fields_add_group(fields, g); - purple_request_fields(gc, _("Create New SILC Key Pair"), + purple_request_fields_with_hint(gc, _("Create New SILC Key Pair"), _("Create New SILC Key Pair"), NULL, fields, _("Generate Key Pair"), G_CALLBACK(silcpurple_create_keypair_cb), _("Cancel"), G_CALLBACK(silcpurple_create_keypair_cancel), - gc->account, NULL, NULL, gc); + gc->account, NULL, NULL, "blist", gc); g_strfreev(u); silc_free(hostname); diff --git a/libpurple/protocols/silc/util.c b/libpurple/protocols/silc/util.c index 2ba28a9ba0..f296b959f5 100644 --- a/libpurple/protocols/silc/util.c +++ b/libpurple/protocols/silc/util.c @@ -376,10 +376,10 @@ void silcpurple_show_public_key(SilcPurple sg, buf = g_string_free(s, FALSE); - purple_request_action(sg->gc, _("Public Key Information"), + purple_request_action_with_hint(sg->gc, _("Public Key Information"), _("Public Key Information"), buf, 0, purple_connection_get_account(sg->gc), - NULL, NULL, context, 1, _("Close"), callback); + NULL, NULL, "blist", context, 1, _("Close"), callback); g_free(buf); silc_free(fingerprint); diff --git a/libpurple/protocols/silc/wb.c b/libpurple/protocols/silc/wb.c index 636d82bd14..4b64e0ffd0 100644 --- a/libpurple/protocols/silc/wb.c +++ b/libpurple/protocols/silc/wb.c @@ -299,8 +299,8 @@ silcpurple_wb_request(SilcClient client, const unsigned char *message, req->channel = channel; req->sg = sg; - purple_request_action(gc, _("Whiteboard"), tmp, NULL, 1, - sg->account, sender->nickname, NULL, req, 2, + purple_request_action_with_hint(gc, _("Whiteboard"), tmp, NULL, 1, + sg->account, sender->nickname, NULL, "blist", req, 2, _("Yes"), G_CALLBACK(silcpurple_wb_request_cb), _("No"), G_CALLBACK(silcpurple_wb_request_cb)); } diff --git a/libpurple/protocols/silc10/buddy.c b/libpurple/protocols/silc10/buddy.c index fffeba63a1..4225dd1daf 100644 --- a/libpurple/protocols/silc10/buddy.c +++ b/libpurple/protocols/silc10/buddy.c @@ -309,9 +309,9 @@ void silcpurple_buddy_keyagr_request(SilcClient client, a->hostname = strdup(hostname); a->port = port; - purple_request_action(client->application, _("Key Agreement Request"), tmp, + purple_request_action_with_hint(client->application, _("Key Agreement Request"), tmp, hostname ? tmp2 : NULL, 1, gc->account, client_entry->nickname, - NULL, a, 2, _("Yes"), G_CALLBACK(silcpurple_buddy_keyagr_request_cb), + NULL, a, "blist", 2, _("Yes"), G_CALLBACK(silcpurple_buddy_keyagr_request_cb), _("No"), G_CALLBACK(silcpurple_buddy_keyagr_request_cb)); } @@ -462,11 +462,11 @@ silcpurple_buddy_privkey(PurpleConnection *gc, const char *name) p->client = sg->client; p->conn = sg->conn; p->client_id = *clients[0]->id; - purple_request_input(gc, _("IM With Password"), NULL, + purple_request_input_with_hint(gc, _("IM With Password"), NULL, _("Set IM Password"), NULL, FALSE, TRUE, NULL, _("OK"), G_CALLBACK(silcpurple_buddy_privkey_cb), _("Cancel"), G_CALLBACK(silcpurple_buddy_privkey_cb), - gc->account, NULL, NULL, p); + gc->account, NULL, NULL, "blist", p); silc_free(clients); silc_free(nickname); @@ -1064,10 +1064,10 @@ silcpurple_add_buddy_ask_pk_cb(SilcPurpleBuddyRes r, gint id) } /* Open file selector to select the public key. */ - purple_request_file(r->client->application, _("Open..."), NULL, FALSE, + purple_request_file_with_hint(r->client->application, _("Open..."), NULL, FALSE, G_CALLBACK(silcpurple_add_buddy_ask_import), G_CALLBACK(silcpurple_add_buddy_ask_pk_cancel), - purple_buddy_get_account(r->b), purple_buddy_get_name(r->b), NULL, r); + purple_buddy_get_account(r->b), purple_buddy_get_name(r->b), NULL, "blist", r); } @@ -1077,10 +1077,10 @@ silcpurple_add_buddy_ask_pk(SilcPurpleBuddyRes r) char tmp[512]; g_snprintf(tmp, sizeof(tmp), _("The %s buddy is not present in the network"), r->b->name); - purple_request_action(r->client->application, _("Add Buddy"), tmp, + purple_request_action_with_hint(r->client->application, _("Add Buddy"), tmp, _("To add the buddy you must import his/her public key. " "Press Import to import a public key."), 0, - purple_buddy_get_account(r->b), purple_buddy_get_name(r->b), NULL, r, 2, + purple_buddy_get_account(r->b), purple_buddy_get_name(r->b), NULL, "blist", r, 2, _("Cancel"), G_CALLBACK(silcpurple_add_buddy_ask_pk_cb), _("_Import..."), G_CALLBACK(silcpurple_add_buddy_ask_pk_cb)); } @@ -1177,7 +1177,7 @@ silcpurple_add_buddy_select(SilcPurpleBuddyRes r, silc_free(fingerprint); } - purple_request_fields(r->client->application, _("Add Buddy"), + purple_request_fields_with_hint(r->client->application, _("Add Buddy"), _("Select correct user"), r->pubkey_search ? _("More than one user was found with the same public key. Select " @@ -1187,7 +1187,7 @@ silcpurple_add_buddy_select(SilcPurpleBuddyRes r, fields, _("OK"), G_CALLBACK(silcpurple_add_buddy_select_cb), _("Cancel"), G_CALLBACK(silcpurple_add_buddy_select_cancel), - purple_buddy_get_account(r->b), purple_buddy_get_name(r->b), NULL, r); + purple_buddy_get_account(r->b), purple_buddy_get_name(r->b), NULL, "blist", r); } static void diff --git a/libpurple/protocols/silc10/chat.c b/libpurple/protocols/silc10/chat.c index c7951bf998..498277e0e1 100644 --- a/libpurple/protocols/silc10/chat.c +++ b/libpurple/protocols/silc10/chat.c @@ -288,10 +288,10 @@ silcpurple_chat_chpk_cb(SilcPurpleChauth sgc, PurpleRequestFields *fields) f = purple_request_fields_get_field(fields, "list"); if (!purple_request_field_list_get_selected(f)) { /* Add new public key */ - purple_request_file(sg->gc, _("Open Public Key..."), NULL, FALSE, + purple_request_file_with_hint(sg->gc, _("Open Public Key..."), NULL, FALSE, G_CALLBACK(silcpurple_chat_chpk_add), G_CALLBACK(silcpurple_chat_chpk_cancel), - purple_connection_get_account(sg->gc), NULL, NULL, sgc); + purple_connection_get_account(sg->gc), NULL, NULL, "conversation", sgc); return; } @@ -419,11 +419,11 @@ void silcpurple_chat_chauth_show(SilcPurple sg, SilcChannelEntry channel, if (!channel_pubkeys) { f = purple_request_field_list_new("list", NULL); purple_request_field_group_add_field(g, f); - purple_request_fields(sg->gc, _("Channel Authentication"), + purple_request_fields_with_hint(sg->gc, _("Channel Authentication"), _("Channel Authentication"), t, fields, _("Add / Remove"), G_CALLBACK(silcpurple_chat_chpk_cb), _("OK"), G_CALLBACK(silcpurple_chat_chauth_ok), - purple_connection_get_account(sg->gc), NULL, NULL, sgc); + purple_connection_get_account(sg->gc), NULL, NULL, "conversation", sgc); return; } sgc->pubkeys = silc_buffer_copy(channel_pubkeys); @@ -458,11 +458,11 @@ void silcpurple_chat_chauth_show(SilcPurple sg, SilcChannelEntry channel, } purple_request_field_list_set_multi_select(f, FALSE); - purple_request_fields(sg->gc, _("Channel Authentication"), + purple_request_fields_with_hint(sg->gc, _("Channel Authentication"), _("Channel Authentication"), t, fields, _("Add / Remove"), G_CALLBACK(silcpurple_chat_chpk_cb), _("OK"), G_CALLBACK(silcpurple_chat_chauth_ok), - purple_connection_get_account(sg->gc), NULL, NULL, sgc); + purple_connection_get_account(sg->gc), NULL, NULL, "cnoversation", sgc); silc_argument_payload_free(chpks); } @@ -595,10 +595,10 @@ silcpurple_chat_prv(PurpleBlistNode *node, gpointer data) g_snprintf(tmp, sizeof(tmp), _("Please enter the %s channel private group name and passphrase."), p->channel); - purple_request_fields(gc, _("Add Channel Private Group"), NULL, tmp, fields, + purple_request_fields_with_hint(gc, _("Add Channel Private Group"), NULL, tmp, fields, _("Add"), G_CALLBACK(silcpurple_chat_prv_add), _("Cancel"), G_CALLBACK(silcpurple_chat_prv_cancel), - purple_connection_get_account(gc), NULL, NULL, p); + purple_connection_get_account(gc), NULL, NULL, "conversation", p); } @@ -723,12 +723,12 @@ silcpurple_chat_ulimit(PurpleBlistNode *node, gpointer data) s->channel = ch; s->sg = sg; g_snprintf(tmp, sizeof(tmp), "%d", (int)channel->user_limit); - purple_request_input(gc, _("User Limit"), NULL, + purple_request_input_with_hint(gc, _("User Limit"), NULL, _("Set user limit on channel. Set to zero to reset user limit."), tmp, FALSE, FALSE, NULL, _("OK"), G_CALLBACK(silcpurple_chat_ulimit_cb), _("Cancel"), G_CALLBACK(silcpurple_chat_ulimit_cb), - purple_connection_get_account(gc), NULL, NULL, s); + purple_connection_get_account(gc), NULL, NULL, "conversation", s); } static void diff --git a/libpurple/protocols/silc10/ops.c b/libpurple/protocols/silc10/ops.c index 777c9c587d..d75584f504 100644 --- a/libpurple/protocols/silc10/ops.c +++ b/libpurple/protocols/silc10/ops.c @@ -1291,9 +1291,9 @@ silc_command_reply(SilcClient client, SilcClientConnection conn, #if 0 /* XXX for now, let's not show attrs here */ if (client_entry->attrs) - purple_request_action(gc, _("User Information"), + purple_request_action_with_hint(gc, _("User Information"), _("User Information"), - buf, 1, client_entry, 2, + buf, 1, "blist", client_entry, 2, _("OK"), G_CALLBACK(silcpurple_whois_more), _("_More..."), G_CALLBACK(silcpurple_whois_more), gc->account, NULL, NULL); else @@ -1898,11 +1898,11 @@ silc_ask_passphrase(SilcClient client, SilcClientConnection conn, return; internal->completion = completion; internal->context = context; - purple_request_input(gc, _("Passphrase"), NULL, + purple_request_input_with_hint(gc, _("Passphrase"), NULL, _("Passphrase required"), NULL, FALSE, TRUE, NULL, _("OK"), G_CALLBACK(silc_ask_passphrase_cb), _("Cancel"), G_CALLBACK(silc_ask_passphrase_cb), - purple_connection_get_account(gc), NULL, NULL, internal); + purple_connection_get_account(gc), NULL, NULL, "blist", internal); } diff --git a/libpurple/protocols/silc10/pk.c b/libpurple/protocols/silc10/pk.c index 0bd399d6d5..405ca0a211 100644 --- a/libpurple/protocols/silc10/pk.c +++ b/libpurple/protocols/silc10/pk.c @@ -113,9 +113,9 @@ static void silcpurple_verify_ask(const char *entity, _("Fingerprint and babbleprint for the %s key are:\n\n" "%s\n%s\n"), entity, fingerprint, babbleprint); - purple_request_action(gc, _("Verify Public Key"), tmp, tmp2, + purple_request_action_with_hint(gc, _("Verify Public Key"), tmp, tmp2, PURPLE_DEFAULT_ACTION_NONE, - purple_connection_get_account(gc), entity, NULL, verify, 3, + purple_connection_get_account(gc), entity, NULL, verify, "blist", 3, _("Yes"), G_CALLBACK(silcpurple_verify_cb), _("No"), G_CALLBACK(silcpurple_verify_cb), _("_View..."), G_CALLBACK(silcpurple_verify_details)); diff --git a/libpurple/protocols/silc10/silc.c b/libpurple/protocols/silc10/silc.c index 7b455b2a77..3b7c8feae6 100644 --- a/libpurple/protocols/silc10/silc.c +++ b/libpurple/protocols/silc10/silc.c @@ -726,7 +726,7 @@ silcpurple_attrs(PurplePluginAction *action) purple_request_field_group_add_field(g, f); purple_request_fields_add_group(fields, g); - purple_request_fields(gc, _("User Online Status Attributes"), + purple_request_fields_with_hint(gc, _("User Online Status Attributes"), _("User Online Status Attributes"), _("You can let other users see your online status information " "and your personal information. Please fill the information " @@ -734,7 +734,7 @@ silcpurple_attrs(PurplePluginAction *action) fields, _("OK"), G_CALLBACK(silcpurple_attrs_cb), _("Cancel"), G_CALLBACK(silcpurple_attrs_cancel), - gc->account, NULL, NULL, gc); + gc->account, NULL, NULL, "blist", gc); } static void @@ -940,7 +940,7 @@ silcpurple_create_keypair(PurplePluginAction *action) _("Create New SILC Key Pair"), NULL, fields, _("Generate Key Pair"), G_CALLBACK(silcpurple_create_keypair_cb), _("Cancel"), G_CALLBACK(silcpurple_create_keypair_cancel), - gc->account, NULL, NULL, gc); + gc->account, NULL, NULL, "blist", gc); g_strfreev(u); silc_free(hostname); diff --git a/libpurple/protocols/silc10/util.c b/libpurple/protocols/silc10/util.c index 5310424ee0..95aa912ba9 100644 --- a/libpurple/protocols/silc10/util.c +++ b/libpurple/protocols/silc10/util.c @@ -371,10 +371,10 @@ void silcpurple_show_public_key(SilcPurple sg, buf = g_string_free(s, FALSE); - purple_request_action(sg->gc, _("Public Key Information"), + purple_request_action_with_hint(sg->gc, _("Public Key Information"), _("Public Key Information"), buf, 0, purple_connection_get_account(sg->gc), - NULL, NULL, context, 1, _("Close"), callback); + NULL, NULL, context, "blist", 1, _("Close"), callback); g_free(buf); silc_free(fingerprint); diff --git a/libpurple/protocols/silc10/wb.c b/libpurple/protocols/silc10/wb.c index 1c3b49cd45..86414bc161 100644 --- a/libpurple/protocols/silc10/wb.c +++ b/libpurple/protocols/silc10/wb.c @@ -299,8 +299,8 @@ silcpurple_wb_request(SilcClient client, const unsigned char *message, req->channel = channel; req->sg = sg; - purple_request_action(gc, _("Whiteboard"), tmp, NULL, 1, - sg->account, sender->nickname, NULL, req, 2, + purple_request_action_with_hint(gc, _("Whiteboard"), tmp, NULL, 1, + sg->account, sender->nickname, NULL, "conversation", req, 2, _("Yes"), G_CALLBACK(silcpurple_wb_request_cb), _("No"), G_CALLBACK(silcpurple_wb_request_cb)); } diff --git a/libpurple/protocols/toc/toc.c b/libpurple/protocols/toc/toc.c index 6570ce019a..34c421b046 100644 --- a/libpurple/protocols/toc/toc.c +++ b/libpurple/protocols/toc/toc.c @@ -2216,8 +2216,8 @@ static void accept_file_dialog(struct ft_request *ft) { g_snprintf(buf, sizeof(buf), _("%s requests you to send them a file"), ft->user); } - purple_request_accept_cancel(ft->gc, NULL, buf, NULL, - PURPLE_DEFAULT_ACTION_NONE, ft, + purple_request_accept_cancel_with_hint(ft->gc, NULL, buf, NULL, + PURPLE_DEFAULT_ACTION_NONE, "xfer", ft, G_CALLBACK(toc_accept_ft), G_CALLBACK(toc_reject_ft)); } diff --git a/libpurple/protocols/yahoo/yahoo.c b/libpurple/protocols/yahoo/yahoo.c index 7a807cb2f9..3150dbd49d 100644 --- a/libpurple/protocols/yahoo/yahoo.c +++ b/libpurple/protocols/yahoo/yahoo.c @@ -1025,7 +1025,7 @@ yahoo_buddy_add_deny_noreason_cb(struct yahoo_add_request *add_req, const char*m static void yahoo_buddy_add_deny_reason_cb(gpointer data) { struct yahoo_add_request *add_req = data; - purple_request_input(add_req->gc, NULL, _("Authorization denied message:"), + purple_request_input_with_hint(add_req->gc, NULL, _("Authorization denied message:"), NULL, _("No reason given."), TRUE, FALSE, NULL, _("OK"), G_CALLBACK(yahoo_buddy_add_deny_cb), _("Cancel"), G_CALLBACK(yahoo_buddy_add_deny_noreason_cb), @@ -2062,7 +2062,7 @@ static void yahoo_process_ignore(PurpleConnection *gc, struct yahoo_packet *pkt) g_snprintf(buf, sizeof(buf), _("You have tried to ignore %s, but the " "user is on your buddy list. Clicking \"Yes\" " "will remove and ignore the buddy."), who); - purple_request_yes_no(gc, NULL, _("Ignore buddy?"), buf, 0, + purple_request_yes_no_with_hint(gc, NULL, _("Ignore buddy?"), buf, 0, gc->account, who, NULL, "blist", b, G_CALLBACK(ignore_buddy), @@ -3491,7 +3491,7 @@ static void yahoo_show_inbox(PurplePluginAction *action) static void yahoo_show_act_id(PurplePluginAction *action) { PurpleConnection *gc = (PurpleConnection *) action->context; - purple_request_input(gc, NULL, _("Activate which ID?"), NULL, + purple_request_input_with_hint(gc, NULL, _("Activate which ID?"), NULL, purple_connection_get_display_name(gc), FALSE, FALSE, NULL, _("OK"), G_CALLBACK(yahoo_act_id), _("Cancel"), NULL, @@ -3502,7 +3502,7 @@ static void yahoo_show_act_id(PurplePluginAction *action) static void yahoo_show_chat_goto(PurplePluginAction *action) { PurpleConnection *gc = (PurpleConnection *) action->context; - purple_request_input(gc, NULL, _("Join who in chat?"), NULL, + purple_request_input_with_hint(gc, NULL, _("Join who in chat?"), NULL, "", FALSE, FALSE, NULL, _("OK"), G_CALLBACK(yahoo_chat_goto), _("Cancel"), NULL, diff --git a/libpurple/request.c b/libpurple/request.c index fe3c7cefde..5860f44b0c 100644 --- a/libpurple/request.c +++ b/libpurple/request.c @@ -1140,6 +1140,20 @@ purple_request_input(void *handle, const char *title, const char *primary, const char *ok_text, GCallback ok_cb, const char *cancel_text, GCallback cancel_cb, PurpleAccount *account, const char *who, PurpleConversation *conv, + void *user_data) +{ + return purple_request_input_with_hint( + handle, title, primary, secondary, default_value, multiline, masked, hint, ok_text, ok_cb, + cancel_text, cancel_cb, account, who, conv, "blist", user_data); +} + +void * +purple_request_input_with_hint(void *handle, const char *title, const char *primary, + const char *secondary, const char *default_value, + gboolean multiline, gboolean masked, gchar *hint, + const char *ok_text, GCallback ok_cb, + const char *cancel_text, GCallback cancel_cb, + PurpleAccount *account, const char *who, PurpleConversation *conv, const char *ui_hint, void *user_data) { PurpleRequestUiOps *ops; @@ -1177,6 +1191,30 @@ purple_request_choice(void *handle, const char *title, const char *primary, const char *ok_text, GCallback ok_cb, const char *cancel_text, GCallback cancel_cb, PurpleAccount *account, const char *who, PurpleConversation *conv, + void *user_data, ...) +{ + void *ui_handle; + va_list args; + + g_return_val_if_fail(ok_text != NULL, NULL); + g_return_val_if_fail(ok_cb != NULL, NULL); + + va_start(args, user_data); + ui_handle = purple_request_choice_varg_with_hint(handle, title, primary, secondary, + default_value, ok_text, ok_cb, + cancel_text, cancel_cb, + account, who, conv, "blist", user_data, args); + va_end(args); + + return ui_handle; +} + +void * +purple_request_choice_with_hint(void *handle, 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, const char *ui_hint, void *user_data, ...) { void *ui_handle; @@ -1186,7 +1224,7 @@ purple_request_choice(void *handle, const char *title, const char *primary, g_return_val_if_fail(ok_cb != NULL, NULL); va_start(args, user_data); - ui_handle = purple_request_choice_varg(handle, title, primary, secondary, + ui_handle = purple_request_choice_varg_with_hint(handle, title, primary, secondary, default_value, ok_text, ok_cb, cancel_text, cancel_cb, account, who, conv, ui_hint, user_data, args); @@ -1204,6 +1242,20 @@ purple_request_choice_varg(void *handle, const char *title, PurpleAccount *account, const char *who, PurpleConversation *conv, const char *ui_hint, void *user_data, va_list choices) { + return purple_choice_varg_with_hint( + handle, title, primary, secondary, default_value, ok_text, ok_cb, + cancel_text, cancel_cb, account, who, conv, "blist", user_data, choices); +} + +void * +purple_request_choice_varg_with_hint(void *handle, 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, + const char *ui_hint, void *user_data, va_list choices) +{ PurpleRequestUiOps *ops; g_return_val_if_fail(ok_text != NULL, NULL); @@ -1236,6 +1288,26 @@ void * 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, ...) +{ + void *ui_handle; + va_list args; + + g_return_val_if_fail(action_count > 0, NULL); + + va_start(args, action_count); + ui_handle = purple_request_action_with_hint_varg(handle, title, primary, secondary, + default_action, account, who, conv, + "blist", user_data, action_count, args); + va_end(args); + + return ui_handle; +} + +void * +purple_request_action_with_hint(void *handle, const char *title, const char *primary, + const char *secondary, int default_action, + PurpleAccount *account, const char *who, PurpleConversation *conv, const char *ui_hint, void *user_data, size_t action_count, ...) { void *ui_handle; @@ -1244,7 +1316,7 @@ purple_request_action(void *handle, const char *title, const char *primary, g_return_val_if_fail(action_count > 0, NULL); va_start(args, action_count); - ui_handle = purple_request_action_varg(handle, title, primary, secondary, + ui_handle = purple_request_action_with_hint_varg(handle, title, primary, secondary, default_action, account, who, conv, ui_hint, user_data, action_count, args); va_end(args); @@ -1257,6 +1329,18 @@ purple_request_action_varg(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, va_list actions) +{ + return purple_request_action_with_hint_varg( + handle, title, primary, secondary, default_action, account, who, conv, + "blist", user_data, action_count, actions); +} + +void * +purple_request_action_with_hint_varg(void *handle, const char *title, + const char *primary, const char *secondary, + int default_action, + PurpleAccount *account, const char *who, PurpleConversation *conv, const char *ui_hint, void *user_data, size_t action_count, va_list actions) { PurpleRequestUiOps *ops; @@ -1291,6 +1375,19 @@ purple_request_fields(void *handle, const char *title, const char *primary, PurpleAccount *account, const char *who, PurpleConversation *conv, const char *ui_hint, void *user_data) { + return purple_request_fields_with_hint( + handle, title, primary, secondary, fields, ok_text, ok_cb, + cancel_text, cancel_cb, account, who, conv, "blist", user_data); +} + +void * +purple_request_fields_with_hint(void *handle, 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, + const char *ui_hint, void *user_data) +{ PurpleRequestUiOps *ops; g_return_val_if_fail(fields != NULL, NULL); @@ -1320,7 +1417,18 @@ purple_request_fields(void *handle, const char *title, const char *primary, } void * -purple_request_file(void *handle, const char *title, const char *filename, +purple_request_file_with_hint(void *handle, const char *title, const char *filename, + gboolean savedialog, + GCallback ok_cb, GCallback cancel_cb, + PurpleAccount *account, const char *who, PurpleConversation *conv, + void *user_data) +{ + return purple_request_file_with_hint( + handle, title, filename, savedialog ok_cb, cancel_cb, account, who, conv, "blist", user_data); +} + +void * +purple_request_file_with_hint(void *handle, const char *title, const char *filename, gboolean savedialog, GCallback ok_cb, GCallback cancel_cb, PurpleAccount *account, const char *who, PurpleConversation *conv, @@ -1350,6 +1458,16 @@ void * 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) +{ + return purple_request_folder_with_hint( + handle, title, dirname, ok_cb, cancel_cb, account, who, conv, "blist", user_data); +} + +void * +purple_request_folder_with_hint(void *handle, const char *title, const char *dirname, + GCallback ok_cb, GCallback cancel_cb, + PurpleAccount *account, const char *who, PurpleConversation *conv, const char *ui_hint, void *user_data) { PurpleRequestUiOps *ops; diff --git a/libpurple/request.h b/libpurple/request.h index 4afe82148b..c3754d1e66 100644 --- a/libpurple/request.h +++ b/libpurple/request.h @@ -1192,7 +1192,7 @@ PurpleFilterAccountFunc purple_request_field_account_get_filter( * * @return A UI-specific handle. */ -void *purple_request_input(void *handle, const char *title, +void *purple_request_input_with_hint(void *handle, const char *title, const char *primary, const char *secondary, const char *default_value, gboolean multiline, gboolean masked, gchar *hint, @@ -1202,6 +1202,18 @@ void *purple_request_input(void *handle, const char *title, const char *ui_hint, void *user_data); /** + * @deprecated Please use purple_request_input_with_hint() instead. + */ +void *purple_request_input(void *handle, const char *title, + const char *primary, const char *secondary, + const char *default_value, + gboolean multiline, gboolean masked, gchar *hint, + const char *ok_text, GCallback ok_cb, + const char *cancel_text, GCallback cancel_cb, + PurpleAccount *account, const char *who, PurpleConversation *conv, + void *user_data); + +/** * Prompts the user for multiple-choice input. * * @param handle The plugin or connection handle. For some @@ -1225,7 +1237,7 @@ void *purple_request_input(void *handle, const char *title, * * @return A UI-specific handle. */ -void *purple_request_choice(void *handle, const char *title, +void *purple_request_choice_with_hint(void *handle, const char *title, const char *primary, const char *secondary, int default_value, const char *ok_text, GCallback ok_cb, @@ -1234,6 +1246,17 @@ void *purple_request_choice(void *handle, const char *title, const char *ui_hint, void *user_data, ...) G_GNUC_NULL_TERMINATED; /** + * @deprecated Please use purple_request_choice_with_hint() instead. + */ +void *purple_request_choice(void *handle, 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, ...) G_GNUC_NULL_TERMINATED; + +/** * Prompts the user for multiple-choice input. * * @param handle The plugin or connection handle. For some @@ -1257,7 +1280,7 @@ void *purple_request_choice(void *handle, const char *title, * * @return A UI-specific handle. */ -void *purple_request_choice_varg(void *handle, const char *title, +void *purple_request_choice_varg_with_hint(void *handle, const char *title, const char *primary, const char *secondary, int default_value, const char *ok_text, GCallback ok_cb, @@ -1266,6 +1289,17 @@ void *purple_request_choice_varg(void *handle, const char *title, const char *ui_hint, void *user_data, va_list choices); /** + * @deprecated Please use purple_request_choice_varg_with_hint() instead. + */ +void *purple_request_choice_varg(void *handle, 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); + +/** * Prompts the user for an action. * * This is often represented as a dialog with a button for each action. @@ -1293,13 +1327,22 @@ void *purple_request_choice_varg(void *handle, const char *title, * * @return A UI-specific handle. */ -void *purple_request_action(void *handle, const char *title, +void *purple_request_action_with_hint(void *handle, const char *title, const char *primary, const char *secondary, int default_action, PurpleAccount *account, const char *who, PurpleConversation *conv, const char *ui_hint, void *user_data, size_t action_count, ...); /** + * @deprecated Please use purple_request_action_with_hint() instead. + */ +void *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, ...); + +/** * Prompts the user for an action. * * This is often represented as a dialog with a button for each action. @@ -1321,7 +1364,7 @@ void *purple_request_action(void *handle, const char *title, * * @return A UI-specific handle. */ -void *purple_request_action_varg(void *handle, const char *title, +void *purple_request_action_varg_with_hint(void *handle, const char *title, const char *primary, const char *secondary, int default_action, PurpleAccount *account, const char *who, PurpleConversation *conv, @@ -1329,6 +1372,16 @@ void *purple_request_action_varg(void *handle, const char *title, va_list actions); /** + * @deprecated Please use purple_request_action_varg_with_hint() instead. + */ +void *purple_request_action_varg(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, + va_list actions); + +/** * Displays groups of fields for the user to fill in. * * @param handle The plugin or connection handle. For some @@ -1350,7 +1403,7 @@ void *purple_request_action_varg(void *handle, const char *title, * * @return A UI-specific handle. */ -void *purple_request_fields(void *handle, const char *title, +void *purple_request_fields_with_hint(void *handle, const char *title, const char *primary, const char *secondary, PurpleRequestFields *fields, const char *ok_text, GCallback ok_cb, @@ -1359,6 +1412,17 @@ void *purple_request_fields(void *handle, const char *title, const char *ui_hint, void *user_data); /** + * @deprecated Please use purple_request_fields_with_hint() instead. + */ +void *purple_request_fields(void *handle, 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); + +/** * Closes a request. * * @param type The request type. @@ -1376,34 +1440,64 @@ void purple_request_close_with_handle(void *handle); /** * A wrapper for purple_request_action() that uses @c Yes and @c No buttons. */ -#define purple_request_yes_no(handle, title, primary, secondary, \ +#define purple_request_yes_no_with_hint(handle, title, primary, secondary, \ default_action, account, who, conv, \ ui_hint, user_data, yes_cb, no_cb) \ - purple_request_action((handle), (title), (primary), (secondary), \ + purple_request_action_with_hint((handle), (title), (primary), (secondary), \ (default_action), account, who, conv, (ui_hint), (user_data), 2, \ _("_Yes"), (yes_cb), _("_No"), (no_cb)) /** + * @deprecated Please use purple_request_yes_no_with_hint instead. + */ +#define purple_request_yes_no(handle, title, primary, secondary, \ + default_action, account, who, conv, \ + user_data, yes_cb, no_cb) \ + purple_request_action((handle), (title), (primary), (secondary), \ + (default_action), account, who, conv, (user_data), 2, \ + _("_Yes"), (yes_cb), _("_No"), (no_cb)) + +/** * A wrapper for purple_request_action() that uses @c OK and @c Cancel buttons. */ -#define purple_request_ok_cancel(handle, title, primary, secondary, \ +#define purple_request_ok_cancel_with_hint(handle, title, primary, secondary, \ default_action, account, who, conv, \ ui_hint, user_data, ok_cb, cancel_cb) \ - purple_request_action((handle), (title), (primary), (secondary), \ + purple_request_action_with_hint((handle), (title), (primary), (secondary), \ (default_action), account, who, conv, (ui_hint), (user_data), 2, \ _("_OK"), (ok_cb), _("_Cancel"), (cancel_cb)) /** + * @deprecated Please use purple_request_ok_cancel_with_hint instead. + */ +#define purple_request_ok_cancel(handle, title, primary, secondary, \ + default_action, account, who, conv, \ + user_data, ok_cb, cancel_cb) \ + purple_request_action((handle), (title), (primary), (secondary), \ + (default_action), account, who, conv, (user_data), 2, \ + _("_OK"), (ok_cb), _("_Cancel"), (cancel_cb)) + +/** * A wrapper for purple_request_action() that uses Accept and Cancel buttons. */ -#define purple_request_accept_cancel(handle, title, primary, secondary, \ +#define purple_request_accept_cancel_with_hint(handle, title, primary, secondary, \ default_action, account, who, conv, \ ui_hint, user_data, accept_cb, cancel_cb) \ - purple_request_action((handle), (title), (primary), (secondary), \ + purple_request_action_with_hint((handle), (title), (primary), (secondary), \ (default_action), account, who, conv, (ui_hint), (user_data), 2, \ _("_Accept"), (accept_cb), _("_Cancel"), (cancel_cb)) /** + * @deprecated Please use purple_request_accept_cancel_with_hint instead. + */ +#define purple_request_accept_cancel(handle, title, primary, secondary, \ + default_action, account, who, conv, \ + user_data, accept_cb, cancel_cb) \ + purple_request_action((handle), (title), (primary), (secondary), \ + (default_action), account, who, conv, (user_data), 2, \ + _("_Accept"), (accept_cb), _("_Cancel"), (cancel_cb)) + +/** * Displays a file selector request dialog. Returns the selected filename to * the callback. Can be used for either opening a file or saving a file. * @@ -1424,13 +1518,22 @@ void purple_request_close_with_handle(void *handle); * * @return A UI-specific handle. */ -void *purple_request_file(void *handle, const char *title, const char *filename, +void *purple_request_file_with_hint(void *handle, const char *title, const char *filename, gboolean savedialog, GCallback ok_cb, GCallback cancel_cb, PurpleAccount *account, const char *who, PurpleConversation *conv, const char *ui_hint, void *user_data); /** + * @deprecated Please use purple_request_file_with_hint() instead. + */ +void *purple_request_file(void *handle, const char *title, const char *filename, + gboolean savedialog, + GCallback ok_cb, GCallback cancel_cb, + PurpleAccount *account, const char *who, PurpleConversation *conv, + void *user_data); + +/** * Displays a folder select dialog. Returns the selected filename to * the callback. * @@ -1449,6 +1552,14 @@ void *purple_request_file(void *handle, const char *title, const char *filename, * * @return A UI-specific handle. */ +void *purple_request_folder_with_hint(void *handle, const char *title, const char *dirname, + GCallback ok_cb, GCallback cancel_cb, + PurpleAccount *account, const char *who, PurpleConversation *conv, + const char *ui_hint, void *user_data); + +/** + * @deprecated Please use purple_request_folder_with_hint() instead. + */ void *purple_request_folder(void *handle, const char *title, const char *dirname, GCallback ok_cb, GCallback cancel_cb, PurpleAccount *account, const char *who, PurpleConversation *conv, diff --git a/libpurple/server.c b/libpurple/server.c index c7698e96b4..20ba34c02f 100644 --- a/libpurple/server.c +++ b/libpurple/server.c @@ -799,7 +799,7 @@ void serv_got_chat_invite(PurpleConnection *gc, const char *name, who, purple_account_get_username(account), name); - purple_request_accept_cancel(gc, NULL, _("Accept chat invitation?"), buf2, + purple_request_accept_cancel_with_hint(gc, NULL, _("Accept chat invitation?"), buf2, PURPLE_DEFAULT_ACTION_NONE, account, who, NULL, "chat", cid, G_CALLBACK(chat_invite_accept), G_CALLBACK(chat_invite_reject)); diff --git a/pidgin/gtkaccount.c b/pidgin/gtkaccount.c index 35e1a57a5c..84776b1e8e 100644 --- a/pidgin/gtkaccount.c +++ b/pidgin/gtkaccount.c @@ -1901,7 +1901,7 @@ ask_delete_account_sel(GtkTreeModel *model, GtkTreePath *path, purple_account_get_username(account)); purple_request_close_with_handle(account); - purple_request_action(account, NULL, buf, NULL, 0, + purple_request_action_with_hint(account, NULL, buf, NULL, 0, account, NULL, NULL, "accounts", account, 2, _("Delete"), delete_account_cb, diff --git a/pidgin/gtkblist.c b/pidgin/gtkblist.c index dcee487243..bdd37daf86 100644 --- a/pidgin/gtkblist.c +++ b/pidgin/gtkblist.c @@ -522,9 +522,9 @@ gtk_blist_auto_personize(PurpleBlistNode *group, const char *alias) if (i > 1) { char *msg = g_strdup_printf(ngettext("You have %d contact named %s. Would you like to merge them?", "You currently have %d contacts named %s. Would you like to merge them?", i), i, alias); - purple_request_action(NULL, NULL, msg, _("Merging these contacts will cause them to share a single entry on the buddy list and use a single conversation window. " + purple_request_action_with_hint(NULL, NULL, msg, _("Merging these contacts will cause them to share a single entry on the buddy list and use a single conversation window. " "You can separate them again by choosing 'Expand' from the contact's context menu"), 0, NULL, NULL, NULL, - merges, 2, _("_Merge"), PURPLE_CALLBACK(gtk_blist_do_personize), _("_Cancel"), PURPLE_CALLBACK(g_list_free)); + "blist", merges, 2, _("_Merge"), PURPLE_CALLBACK(gtk_blist_do_personize), _("_Cancel"), PURPLE_CALLBACK(g_list_free)); g_free(msg); } else g_list_free(merges); @@ -4315,7 +4315,7 @@ connection_error_button_clicked_cb(GtkButton *widget, gpointer user_data) text = g_hash_table_lookup(gtkblist->connection_errors, account); enabled = purple_account_get_enabled(account, purple_core_get_ui()); - purple_request_action(account, _("Connection Error"), primary, text, 2, + purple_request_action_with_hint(account, _("Connection Error"), primary, text, 2, account, NULL, NULL, "account", account, 3, _("OK"), NULL, @@ -6260,7 +6260,7 @@ add_group_cb(PurpleConnection *gc, const char *group_name) static void pidgin_blist_request_add_group(void) { - purple_request_input(NULL, _("Add Group"), NULL, + purple_request_input_with_hint(NULL, _("Add Group"), NULL, _("Please enter the name of the group to be added."), NULL, FALSE, FALSE, NULL, _("Add"), G_CALLBACK(add_group_cb), diff --git a/pidgin/gtkcertmgr.c b/pidgin/gtkcertmgr.c index 5f2e0114ac..fdf4ccd4c3 100644 --- a/pidgin/gtkcertmgr.c +++ b/pidgin/gtkcertmgr.c @@ -184,7 +184,7 @@ tls_peers_mgmt_import_ok_cb(gpointer data, const char *filename) if the window gets closed unusually, such as by handle deletion */ /* TODO: Display some more information on the certificate? */ - purple_request_input(tpm_dat, + purple_request_input_with_hint(tpm_dat, _("Certificate Import"), _("Specify a hostname"), _("Type the host name this certificate is for."), @@ -220,7 +220,7 @@ static void tls_peers_mgmt_import_cb(GtkWidget *button, gpointer data) { /* TODO: need to tell the user that we want a .PEM file! */ - purple_request_file(tpm_dat, + purple_request_file_with_hint(tpm_dat, _("Select a PEM certificate"), "certificate.pem", FALSE, /* Not a save dialog */ @@ -295,7 +295,7 @@ tls_peers_mgmt_export_cb(GtkWidget *button, gpointer data) /* TODO: inform user that it will be a PEM? */ - purple_request_file(tpm_dat, + purple_request_file_with_hint(tpm_dat, _("PEM X.509 Certificate Export"), "certificate.pem", TRUE, /* Is a save dialog */ @@ -371,7 +371,7 @@ tls_peers_mgmt_delete_cb(GtkWidget *button, gpointer data) primary = g_strdup_printf( _("Really delete certificate for %s?"), id ); - purple_request_yes_no(tpm_dat, _("Confirm certificate delete"), + purple_request_yes_no_with_hint(tpm_dat, _("Confirm certificate delete"), primary, NULL, /* Can this be NULL? */ 2, /* NO is default action */ NULL, NULL, NULL, diff --git a/pidgin/gtkconv.c b/pidgin/gtkconv.c index 56125f2a51..69e180065d 100644 --- a/pidgin/gtkconv.c +++ b/pidgin/gtkconv.c @@ -1029,7 +1029,7 @@ menu_save_as_cb(gpointer data, guint action, GtkWidget *widget) if (*c == '/' || *c == '\\') *c = ' '; } - purple_request_file(PIDGIN_CONVERSATION(conv), _("Save Conversation"), + purple_request_file_with_hint(PIDGIN_CONVERSATION(conv), _("Save Conversation"), buf, TRUE, G_CALLBACK(savelog_writefile_cb), NULL, NULL, NULL, conv, @@ -2713,7 +2713,7 @@ icon_menu_save_cb(GtkWidget *widget, PidginConversation *gtkconv) buf = g_strdup_printf("%s.%s", purple_normalize(conv->account, conv->name), ext); - purple_request_file(gtkconv, _("Save Icon"), buf, TRUE, + purple_request_file_with_hint(gtkconv, _("Save Icon"), buf, TRUE, G_CALLBACK(saveicon_writefile_cb), NULL, conv->account, NULL, conv, "conversation", gtkconv); diff --git a/pidgin/gtkdebug.c b/pidgin/gtkdebug.c index ab0abc2112..213074597b 100644 --- a/pidgin/gtkdebug.c +++ b/pidgin/gtkdebug.c @@ -231,7 +231,7 @@ save_writefile_cb(void *user_data, const char *filename) static void save_cb(GtkWidget *w, DebugWindow *win) { - purple_request_file(win, _("Save Debug Log"), "purple-debug.log", TRUE, + purple_request_file_with_hint(win, _("Save Debug Log"), "purple-debug.log", TRUE, G_CALLBACK(save_writefile_cb), NULL, NULL, NULL, NULL, "blist", win); diff --git a/pidgin/gtkdialogs.c b/pidgin/gtkdialogs.c index 3931b01d0a..533064948e 100644 --- a/pidgin/gtkdialogs.c +++ b/pidgin/gtkdialogs.c @@ -762,7 +762,7 @@ pidgin_dialogs_im(void) purple_request_field_set_required(field, TRUE); purple_request_field_group_add_field(group, field); - purple_request_fields(purple_get_blist(), _("New Instant Message"), + purple_request_fields_with_hint(purple_get_blist(), _("New Instant Message"), NULL, _("Please enter the screen name or alias of the person " "you would like to IM."), @@ -901,7 +901,7 @@ pidgin_dialogs_info(void) purple_request_field_set_required(field, TRUE); purple_request_field_group_add_field(group, field); - purple_request_fields(purple_get_blist(), _("Get User Info"), + purple_request_fields_with_hint(purple_get_blist(), _("Get User Info"), NULL, _("Please enter the screen name or alias of the person " "whose info you would like to view."), @@ -993,7 +993,7 @@ pidgin_dialogs_log(void) purple_request_field_set_required(field, TRUE); purple_request_field_group_add_field(group, field); - purple_request_fields(purple_get_blist(), _("View User Log"), + purple_request_fields_with_hint(purple_get_blist(), _("View User Log"), NULL, _("Please enter the screen name or alias of the person " "whose log you would like to view."), @@ -1015,7 +1015,7 @@ pidgin_dialogs_alias_contact(PurpleContact *contact) { g_return_if_fail(contact != NULL); - purple_request_input(NULL, _("Alias Contact"), NULL, + purple_request_input_with_hint(NULL, _("Alias Contact"), NULL, _("Enter an alias for this contact."), contact->alias, FALSE, FALSE, NULL, _("Alias"), G_CALLBACK(pidgin_dialogs_alias_contact_cb), @@ -1040,7 +1040,7 @@ pidgin_dialogs_alias_buddy(PurpleBuddy *buddy) secondary = g_strdup_printf(_("Enter an alias for %s."), buddy->name); - purple_request_input(NULL, _("Alias Buddy"), NULL, + purple_request_input_with_hint(NULL, _("Alias Buddy"), NULL, secondary, buddy->alias, FALSE, FALSE, NULL, _("Alias"), G_CALLBACK(pidgin_dialogs_alias_buddy_cb), _("Cancel"), NULL, @@ -1061,7 +1061,7 @@ pidgin_dialogs_alias_chat(PurpleChat *chat) { g_return_if_fail(chat != NULL); - purple_request_input(NULL, _("Alias Chat"), NULL, + purple_request_input_with_hint(NULL, _("Alias Chat"), NULL, _("Enter an alias for this chat."), chat->alias, FALSE, FALSE, NULL, _("Alias"), G_CALLBACK(pidgin_dialogs_alias_chat_cb), @@ -1109,7 +1109,7 @@ pidgin_dialogs_remove_contact(PurpleContact *contact) "want to continue?", contact->totalsize - 1), buddy->name, contact->totalsize - 1); - purple_request_action(contact, NULL, _("Remove Contact"), text, 0, + purple_request_action_with_hint(contact, NULL, _("Remove Contact"), text, 0, NULL, purple_contact_get_alias(contact), NULL, "blist", contact, 2, _("_Remove Contact"), G_CALLBACK(pidgin_dialogs_remove_contact_cb), @@ -1150,7 +1150,7 @@ pidgin_dialogs_merge_groups(PurpleGroup *source, const char *new_name) ggp->parent = source; ggp->new_name = g_strdup(new_name); - purple_request_action(source, NULL, _("Merge Groups"), text, 0, + purple_request_action_with_hint(source, NULL, _("Merge Groups"), text, 0, NULL, NULL, NULL, "blist", ggp, 2, _("_Merge Groups"), G_CALLBACK(pidgin_dialogs_merge_groups_cb), @@ -1206,7 +1206,7 @@ pidgin_dialogs_remove_group(PurpleGroup *group) text = g_strdup_printf(_("You are about to remove the group %s and all its members from your buddy list. Do you want to continue?"), group->name); - purple_request_action(group, NULL, _("Remove Group"), text, 0, + purple_request_action_with_hint(group, NULL, _("Remove Group"), text, 0, NULL, NULL, NULL, "blist", group, 2, _("_Remove Group"), G_CALLBACK(pidgin_dialogs_remove_group_cb), @@ -1245,7 +1245,7 @@ pidgin_dialogs_remove_buddy(PurpleBuddy *buddy) text = g_strdup_printf(_("You are about to remove %s from your buddy list. Do you want to continue?"), buddy->name); - purple_request_action(buddy, NULL, _("Remove Buddy"), text, 0, + purple_request_action_with_hint(buddy, NULL, _("Remove Buddy"), text, 0, purple_buddy_get_account(buddy), purple_buddy_get_name(buddy), NULL, "blist", buddy, 2, _("_Remove Buddy"), G_CALLBACK(pidgin_dialogs_remove_buddy_cb), @@ -1272,7 +1272,7 @@ pidgin_dialogs_remove_chat(PurpleChat *chat) text = g_strdup_printf(_("You are about to remove the chat %s from your buddy list. Do you want to continue?"), name ? name : ""); - purple_request_action(chat, NULL, _("Remove Chat"), text, 0, + purple_request_action_with_hint(chat, NULL, _("Remove Chat"), text, 0, chat->account, NULL, NULL, "blist", chat, 2, _("_Remove Chat"), G_CALLBACK(pidgin_dialogs_remove_chat_cb), diff --git a/pidgin/gtkimhtmltoolbar.c b/pidgin/gtkimhtmltoolbar.c index c0ce841203..383d1c97b3 100644 --- a/pidgin/gtkimhtmltoolbar.c +++ b/pidgin/gtkimhtmltoolbar.c @@ -429,13 +429,13 @@ insert_link_cb(GtkWidget *w, GtkIMHtmlToolbar *toolbar) } toolbar->link_dialog = - purple_request_fields(toolbar, _("Insert Link"), + purple_request_fields_with_hint(toolbar, _("Insert Link"), NULL, - msg, + msg, fields, _("_Insert"), G_CALLBACK(do_insert_link_cb), _("Cancel"), G_CALLBACK(cancel_link_cb), - NULL, NULL, NULL, + NULL, NULL, NULL, "conversation", toolbar); g_free(msg); g_free(desc); diff --git a/pidgin/gtklog.c b/pidgin/gtklog.c index b0365578b3..e9aed85388 100644 --- a/pidgin/gtklog.c +++ b/pidgin/gtklog.c @@ -321,7 +321,7 @@ static void log_delete_log_cb(GtkWidget *menuitem, gpointer *data) data2[0] = lv->treestore; data2[1] = data[3]; /* iter */ data2[2] = log; - purple_request_action(lv, NULL, "Delete Log?", tmp, 0, + purple_request_action_with_hint(lv, NULL, "Delete Log?", tmp, 0, NULL, NULL, NULL, "log_viewer", data2, 2, _("Delete"), delete_log_cb, diff --git a/pidgin/gtkplugin.c b/pidgin/gtkplugin.c index d50ac3aaa7..387ded5960 100644 --- a/pidgin/gtkplugin.c +++ b/pidgin/gtkplugin.c @@ -280,11 +280,11 @@ static void plugin_toggled(GtkCellRendererToggle *cell, gchar *pth, gpointer dat cb_data[1] = model; cb_data[2] = iter; - purple_request_action(plugin_dialog, NULL, + purple_request_action_with_hint(plugin_dialog, NULL, _("Multiple plugins will be unloaded."), tmp->str, 0, - NULL, NULL, NULL, - "plugins", cb_data, 2, + NULL, NULL, NULL, + "plugins", cb_data, 2, _("Unload Plugins"), G_CALLBACK(plugin_unload_confirm_cb), _("Cancel"), g_free); g_string_free(tmp, TRUE); diff --git a/pidgin/gtkpounce.c b/pidgin/gtkpounce.c index 7c884ceebd..66cc05bbdd 100644 --- a/pidgin/gtkpounce.c +++ b/pidgin/gtkpounce.c @@ -154,7 +154,7 @@ filesel(GtkWidget *widget, gpointer data) entry = (GtkWidget *)data; name = gtk_entry_get_text(GTK_ENTRY(entry)); - purple_request_file(entry, _("Select a file"), name, FALSE, + purple_request_file_with_hint(entry, _("Select a file"), name, FALSE, G_CALLBACK(pounce_update_entry_fields), NULL, NULL, NULL, NULL, "buddy_pounce", entry); @@ -1094,7 +1094,7 @@ pounces_manager_delete_foreach(GtkTreeModel *model, GtkTreePath *path, pouncee = purple_pounce_get_pouncee(pounce); 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, + purple_request_action_with_hint(pounce, NULL, buf, NULL, 0, account, pouncee, NULL, "pounces", pounce, 2, _("Delete"), pounces_manager_delete_confirm_cb, diff --git a/pidgin/gtkprefs.c b/pidgin/gtkprefs.c index e0a104a7dd..7cc57cf4cb 100644 --- a/pidgin/gtkprefs.c +++ b/pidgin/gtkprefs.c @@ -641,7 +641,7 @@ request_theme_file_name_cb(gpointer data, char *theme_file_name) static void add_theme_button_clicked_cb(GtkWidget *widget, gpointer null) { - purple_request_file(NULL, _("Install Theme"), NULL, FALSE, + purple_request_file_with_hint(NULL, _("Install Theme"), NULL, FALSE, (GCallback)request_theme_file_name_cb, NULL, NULL, NULL, NULL, "preferences", NULL) ; } @@ -1625,7 +1625,7 @@ static void select_sound(GtkWidget *button, gpointer being_NULL_is_fun) if (*filename == '\0') filename = NULL; - purple_request_file(prefs, _("Sound Selection"), filename, FALSE, + purple_request_file_with_hint(prefs, _("Sound Selection"), filename, FALSE, G_CALLBACK(sound_chosen_cb), NULL, NULL, NULL, NULL, "preferences", GINT_TO_POINTER(sound_row_sel)); diff --git a/pidgin/gtkprivacy.c b/pidgin/gtkprivacy.c index f1eacf7826..5a300e4d3f 100644 --- a/pidgin/gtkprivacy.c +++ b/pidgin/gtkprivacy.c @@ -554,7 +554,7 @@ pidgin_request_add_permit(PurpleAccount *account, const char *name) data->block = FALSE; if (name == NULL) { - purple_request_input(account, _("Permit User"), + purple_request_input_with_hint(account, _("Permit User"), _("Type a user you permit to contact you."), _("Please enter the name of the user you wish to be " "able to contact you."), @@ -571,7 +571,7 @@ pidgin_request_add_permit(PurpleAccount *account, const char *name) "%s to contact you?"), name); - purple_request_action(account, _("Permit User"), primary, secondary, + purple_request_action_with_hint(account, _("Permit User"), primary, secondary, 0, account, name, NULL, "privacy", data, 2, @@ -596,7 +596,7 @@ pidgin_request_add_block(PurpleAccount *account, const char *name) data->block = TRUE; if (name == NULL) { - purple_request_input(account, _("Block User"), + purple_request_input_with_hint(account, _("Block User"), _("Type a user to block."), _("Please enter the name of the user you wish to block."), NULL, FALSE, FALSE, NULL, @@ -610,7 +610,7 @@ pidgin_request_add_block(PurpleAccount *account, const char *name) char *secondary = g_strdup_printf(_("Are you sure you want to block %s?"), name); - purple_request_action(account, _("Block User"), primary, secondary, + purple_request_action_with_hint(account, _("Block User"), primary, secondary, 0, account, name, NULL, "privacy", data, 2, diff --git a/pidgin/gtkrequest.c b/pidgin/gtkrequest.c index f3d6eb6465..2061fee8ce 100644 --- a/pidgin/gtkrequest.c +++ b/pidgin/gtkrequest.c @@ -1560,7 +1560,7 @@ file_ok_check_if_exists_cb(GtkWidget *button, PidginRequestData *data) if ((data->u.file.savedialog == TRUE) && (g_file_test(data->u.file.name, G_FILE_TEST_EXISTS))) { - purple_request_action(data, NULL, _("That file already exists"), + purple_request_action_with_hint(data, NULL, _("That file already exists"), _("Would you like to overwrite it?"), 0, NULL, NULL, NULL, "pidgin-request-file", data, 2, diff --git a/pidgin/gtksavedstatuses.c b/pidgin/gtksavedstatuses.c index 1a0f3a3bd2..13cac6d90c 100644 --- a/pidgin/gtksavedstatuses.c +++ b/pidgin/gtksavedstatuses.c @@ -338,7 +338,7 @@ status_window_delete_cb(GtkButton *button, gpointer user_data) handle = dialog; } - purple_request_action(handle, NULL, title, NULL, 0, + purple_request_action_with_hint(handle, NULL, title, NULL, 0, NULL, NULL, NULL, "statuses", sel_titles, 2, _("Delete"), status_window_delete_confirm_cb, diff --git a/pidgin/gtkstatusbox.c b/pidgin/gtkstatusbox.c index 938213edb5..b3a075840f 100644 --- a/pidgin/gtkstatusbox.c +++ b/pidgin/gtkstatusbox.c @@ -1567,7 +1567,7 @@ tree_view_delete_current_selection(PidginStatusBox *status_box, GtkTreePath *pat msg = g_strdup_printf(_("Are you sure you want to delete %s?"), purple_savedstatus_get_title(saved)); - purple_request_action(saved, NULL, msg, NULL, 0, + purple_request_action_with_hint(saved, NULL, msg, NULL, 0, NULL, NULL, NULL, "pidgin-statusbox", data, 2, _("Delete"), tree_view_delete_current_selection_cb, diff --git a/pidgin/gtkutils.c b/pidgin/gtkutils.c index ca5da8ff7c..fbbc959a5a 100644 --- a/pidgin/gtkutils.c +++ b/pidgin/gtkutils.c @@ -1527,7 +1527,7 @@ pidgin_dnd_file_manage(GtkSelectionData *sd, PurpleAccount *account, const char ft = prpl_info->can_receive_file(gc, who); if (im && ft) - purple_request_choice(NULL, NULL, + purple_request_choice_with_hint(NULL, NULL, _("You have dragged an image"), _("You can send this image as a file transfer, " "embed it into this message, or use it as the buddy icon for this user."), @@ -1540,13 +1540,13 @@ pidgin_dnd_file_manage(GtkSelectionData *sd, PurpleAccount *account, const char _("Insert in message"), DND_IM_IMAGE, NULL); else if (!(im || ft)) - purple_request_yes_no(NULL, NULL, _("You have dragged an image"), + purple_request_yes_no_with_hint(NULL, NULL, _("You have dragged an image"), _("Would you like to set it as the buddy icon for this user?"), 0, account, who, NULL, "conversation", data, (GCallback)dnd_set_icon_ok_cb, (GCallback)dnd_set_icon_cancel_cb); else - purple_request_choice(NULL, NULL, + purple_request_choice_with_hint(NULL, NULL, _("You have dragged an image"), (ft ? _("You can send this image as a file transfer, or use it as the buddy icon for this user.") : _("You can insert this image into this message, or use it as the buddy icon for this user")), |