Mercurial > pidgin
comparison src/dialogs.c @ 5205:fefad67de2c7
[gaim-migrate @ 5573]
I had a damn good commit message, but it was eaten. Let's try it again.
Announcing, Gaim Plugin API version 2.0, or GPAPIV2.0 for short.
There are lots'a cool thingies here.
Okay now, this isn't as cool as the previous message, but:
1) There's now a single entry function for all plugin types. It returns a
detailed information structure on the plugin. This removes a lot of the
ugliness from old plugins. Oh yeah, libicq wasn't converted to this, so
if you use it, well, you shouldn't have used it anyway, but now you
can't! bwahahaha. Use AIM/ICQ.
2) There are now 3 types of plugins: Standard, Loader, and Protocol
plugins.
Standard plugins are, well, standard, compiled plugins.
Loader plugins load other plugins. For example, the perl support is now
a loader plugin. It loads perl scripts. In the future, we'll have
Ruby and Python loader plugins.
Protocol plugins are, well, protocol plugins... yeah...
3) Plugins have unique IDs, so they can be referred to or automatically
updated from a plugin database in the future. Neat, huh?
4) Plugins will have dependency support in the future, and can be hidden,
so if you have, say, a logging core plugin, it won't have to show up,
but then you load the GTK+ logging plugin and it'll auto-load the core
plugin. Core/UI split plugins!
5) There will eventually be custom plugin signals and RPC of some sort, for
the core/ui split plugins.
So, okay, back up .gaimrc.
I'd like to thank my parents for their support, javabsp for helping convert
a bunch of protocol plugins, and Etan for helping convert a bunch of
standard plugins.
Have fun. If you have any problems, please let me know, but you probably
won't have anything major happen. You will have to convert your plugins,
though, and I'm not guaranteeing that all perl scripts will still work.
I'll end up changing the perl script API eventually, so I know they won't
down the road. Don't worry, though. It'll be mass cool.
faceprint wants me to just commit the damn code already. So, here we go!!!
..
..
I need a massage. From a young, cute girl. Are there any young, cute girls
in the audience? IM me plz k thx.
committer: Tailor Script <tailor@pidgin.im>
| author | Christian Hammond <chipx86@chipx86.com> |
|---|---|
| date | Fri, 25 Apr 2003 06:47:33 +0000 |
| parents | 381da05cb5ed |
| children | 1cf4eb75e3ee |
comparison
equal
deleted
inserted
replaced
| 5204:44de70702205 | 5205:fefad67de2c7 |
|---|---|
| 731 | 731 |
| 732 menu = gtk_menu_new(); | 732 menu = gtk_menu_new(); |
| 733 | 733 |
| 734 while (g) { | 734 while (g) { |
| 735 c = (struct gaim_connection *)g->data; | 735 c = (struct gaim_connection *)g->data; |
| 736 if (!c->prpl->send_im) { | 736 |
| 737 if (!GAIM_PLUGIN_PROTOCOL_INFO(c->prpl)->send_im) { | |
| 737 g = g->next; | 738 g = g->next; |
| 738 continue; | 739 continue; |
| 739 } | 740 } |
| 740 g_snprintf(buf, sizeof(buf), "%s (%s)", c->username, c->prpl->name); | 741 g_snprintf(buf, sizeof(buf), "%s (%s)", |
| 742 c->username, c->prpl->info->name); | |
| 741 opt = gtk_menu_item_new_with_label(buf); | 743 opt = gtk_menu_item_new_with_label(buf); |
| 742 g_object_set_data(G_OBJECT(opt), "getuserinfo", info); | 744 g_object_set_data(G_OBJECT(opt), "getuserinfo", info); |
| 743 | 745 |
| 744 g_signal_connect(GTK_OBJECT(opt), "activate", | 746 g_signal_connect(GTK_OBJECT(opt), "activate", |
| 745 G_CALLBACK(show_info_select_account), c); | 747 G_CALLBACK(show_info_select_account), c); |
| 831 | 833 |
| 832 menu = gtk_menu_new(); | 834 menu = gtk_menu_new(); |
| 833 | 835 |
| 834 while (g) { | 836 while (g) { |
| 835 c = (struct gaim_connection *)g->data; | 837 c = (struct gaim_connection *)g->data; |
| 836 if (!c->prpl->get_info) { | 838 |
| 839 if (!GAIM_PLUGIN_PROTOCOL_INFO(c->prpl)->get_info) { | |
| 837 g = g->next; | 840 g = g->next; |
| 838 continue; | 841 continue; |
| 839 } | 842 } |
| 840 g_snprintf(buf, sizeof(buf), "%s (%s)", c->username, c->prpl->name); | 843 g_snprintf(buf, sizeof(buf), "%s (%s)", |
| 844 c->username, c->prpl->info->name); | |
| 841 opt = gtk_menu_item_new_with_label(buf); | 845 opt = gtk_menu_item_new_with_label(buf); |
| 842 g_object_set_data(G_OBJECT(opt), "getuserinfo", info); | 846 g_object_set_data(G_OBJECT(opt), "getuserinfo", info); |
| 843 | 847 |
| 844 g_signal_connect(GTK_OBJECT(opt), "activate", | 848 g_signal_connect(GTK_OBJECT(opt), "activate", |
| 845 G_CALLBACK(show_info_select_account), c); | 849 G_CALLBACK(show_info_select_account), c); |
| 1031 menu = gtk_menu_new(); | 1035 menu = gtk_menu_new(); |
| 1032 | 1036 |
| 1033 while (g) { | 1037 while (g) { |
| 1034 c = (struct gaim_connection *)g->data; | 1038 c = (struct gaim_connection *)g->data; |
| 1035 g_snprintf(buf, sizeof(buf), "%s (%s)", | 1039 g_snprintf(buf, sizeof(buf), "%s (%s)", |
| 1036 c->username, c->prpl->name); | 1040 c->username, c->prpl->info->name); |
| 1037 opt = gtk_menu_item_new_with_label(buf); | 1041 opt = gtk_menu_item_new_with_label(buf); |
| 1038 g_object_set_data(G_OBJECT(opt), "addbuddy", b); | 1042 g_object_set_data(G_OBJECT(opt), "addbuddy", b); |
| 1039 g_signal_connect(GTK_OBJECT(opt), "activate", | 1043 g_signal_connect(GTK_OBJECT(opt), "activate", |
| 1040 G_CALLBACK(addbuddy_select_account), | 1044 G_CALLBACK(addbuddy_select_account), |
| 1041 c); | 1045 c); |
| 1326 menu = gtk_menu_new(); | 1330 menu = gtk_menu_new(); |
| 1327 | 1331 |
| 1328 while (c) { | 1332 while (c) { |
| 1329 gc = (struct gaim_connection *)c->data; | 1333 gc = (struct gaim_connection *)c->data; |
| 1330 c = c->next; | 1334 c = c->next; |
| 1331 if (!gc->prpl->set_permit_deny) | 1335 |
| 1336 if (!GAIM_PLUGIN_PROTOCOL_INFO(gc->prpl)->set_permit_deny) | |
| 1332 continue; | 1337 continue; |
| 1333 g_snprintf(buf, sizeof buf, "%s (%s)", gc->username, gc->prpl->name); | 1338 |
| 1339 g_snprintf(buf, sizeof buf, "%s (%s)", | |
| 1340 gc->username, gc->prpl->info->name); | |
| 1334 opt = gtk_menu_item_new_with_label(buf); | 1341 opt = gtk_menu_item_new_with_label(buf); |
| 1335 g_signal_connect(GTK_OBJECT(opt), "activate", G_CALLBACK(deny_gc_opt), gc); | 1342 g_signal_connect(GTK_OBJECT(opt), "activate", G_CALLBACK(deny_gc_opt), gc); |
| 1336 gtk_widget_show(opt); | 1343 gtk_widget_show(opt); |
| 1337 gtk_menu_shell_append(GTK_MENU_SHELL(menu), opt); | 1344 gtk_menu_shell_append(GTK_MENU_SHELL(menu), opt); |
| 1338 if (gc == current_deny_gc) | 1345 if (gc == current_deny_gc) |
| 1432 if (!privacy_win) | 1439 if (!privacy_win) |
| 1433 return; | 1440 return; |
| 1434 | 1441 |
| 1435 while (c) { | 1442 while (c) { |
| 1436 gc = c->data; | 1443 gc = c->data; |
| 1437 if (gc->prpl->set_permit_deny) | 1444 if (GAIM_PLUGIN_PROTOCOL_INFO(gc->prpl)->set_permit_deny) |
| 1438 break; | 1445 break; |
| 1439 gc = NULL; | 1446 gc = NULL; |
| 1440 c = c->next; | 1447 c = c->next; |
| 1441 } | 1448 } |
| 1442 needdeny = (gc != NULL); | 1449 needdeny = (gc != NULL); |
| 3209 return; | 3216 return; |
| 3210 | 3217 |
| 3211 if(c->account) | 3218 if(c->account) |
| 3212 smileys = get_proto_smileys(c->account->protocol); | 3219 smileys = get_proto_smileys(c->account->protocol); |
| 3213 else | 3220 else |
| 3214 smileys = get_proto_smileys(DEFAULT_PROTO); | 3221 smileys = get_proto_smileys(GAIM_PROTO_DEFAULT); |
| 3215 | 3222 |
| 3216 while(smileys) { | 3223 while(smileys) { |
| 3217 GtkIMHtmlSmiley *smiley = smileys->data; | 3224 GtkIMHtmlSmiley *smiley = smileys->data; |
| 3218 if(!smiley->hidden) { | 3225 if(!smiley->hidden) { |
| 3219 if(smiley_is_unique(unique_smileys, smiley)) | 3226 if(smiley_is_unique(unique_smileys, smiley)) |
