Revision 9d227438376255715d0d778ce0a57734aed4c99a
sadrul at pidgin.im
sadrul at pidgin.im
Mon Mar 19 02:19:20 EDT 2007
o -----------------------------------------------------------------
| Revision: 9d227438376255715d0d778ce0a57734aed4c99a
| Ancestor: c9fdf2f3b93c3b83a38391080a042c1c115eaabc
| Author: sadrul at pidgin.im
| Date: 2007-03-19T06:34:51
| Branch: im.pidgin.pidgin
|
| Modified files:
| finch/gntrequest.c
|
| ChangeLog:
|
| Add auto-complete support in request-entries that have 'screenname' hint set. This can be useful in, for example, 'send im' dialog etc.
|
| ============================================================
| --- finch/gntrequest.c 05cd821ee9fba343add55e6e07af7b80cadf14fa
| +++ finch/gntrequest.c 60f55d9ee4f7bd53d999e105cc03c70f80433aeb
| @@ -384,10 +384,21 @@ finch_request_fields(const char *title,
| }
| else if (type == GAIM_REQUEST_FIELD_STRING)
| {
| + const char *hint = gaim_request_field_get_type_hint(field);
| GntWidget *entry = gnt_entry_new(
| gaim_request_field_string_get_default_value(field));
| gnt_entry_set_masked(GNT_ENTRY(entry),
| gaim_request_field_string_is_masked(field));
| + if (gaim_str_has_prefix(hint, "screenname")) {
| + GaimBlistNode *node = gaim_blist_get_root();
| + gboolean offline = gaim_str_has_suffix(hint, "all");
| + for (; node; node = gaim_blist_node_next(node, offline)) {
| + if (!GAIM_BLIST_NODE_IS_BUDDY(node))
| + continue;
| + gnt_entry_add_suggest(GNT_ENTRY(entry), gaim_buddy_get_name((GaimBuddy*)node));
| + }
| + gnt_entry_set_always_suggest(GNT_ENTRY(entry), TRUE);
| + }
| gnt_box_add_widget(GNT_BOX(hbox), entry);
| field->ui_data = entry;
| }
To get the patch for this revision, please do this:
mtn log --last 1 --diffs --from 9d227438376255715d0d778ce0a57734aed4c99a
More information about the Commits
mailing list