Mercurial > pidgin
comparison src/module.c @ 2443:7f2432a87376
[gaim-migrate @ 2456]
it can send ims.
committer: Tailor Script <tailor@pidgin.im>
| author | Eric Warmenhoven <eric@warmenhoven.org> |
|---|---|
| date | Sat, 06 Oct 2001 04:37:34 +0000 |
| parents | 2c2c1f717616 |
| children | 0be6fadaa64f |
comparison
equal
deleted
inserted
replaced
| 2442:895e2469cb3a | 2443:7f2432a87376 |
|---|---|
| 522 g_free(p); | 522 g_free(p); |
| 523 c = c->next; | 523 c = c->next; |
| 524 } | 524 } |
| 525 } | 525 } |
| 526 #endif | 526 #endif |
| 527 | |
| 528 void plugin_handler(struct UI *ui, guchar subtype, guchar *data) | |
| 529 { | |
| 530 guint id; | |
| 531 struct gaim_plugin *p; | |
| 532 | |
| 533 switch (subtype) { | |
| 534 /* | |
| 535 case CUI_PLUGIN_LIST: | |
| 536 break; | |
| 537 */ | |
| 538 case CUI_PLUGIN_LOAD: | |
| 539 p = load_plugin(data); | |
| 540 /* XXX need to broadcast to UIs that plugin has been loaded */ | |
| 541 break; | |
| 542 case CUI_PLUGIN_UNLOAD: | |
| 543 memcpy(&id, data, sizeof(id)); | |
| 544 p = g_list_nth_data(plugins, id); | |
| 545 if (p) { | |
| 546 unload_plugin(p); | |
| 547 /* XXX need to broadcast to UIs that plugin has been unloaded */ | |
| 548 } | |
| 549 break; | |
| 550 case CUI_PLUGIN_RELOAD: | |
| 551 memcpy(&id, data, sizeof(id)); | |
| 552 p = g_list_nth_data(plugins, id); | |
| 553 if (p) { | |
| 554 p = reload_plugin(p); | |
| 555 /* XXX need to broadcast to UIs that plugin has been reloaded */ | |
| 556 } | |
| 557 break; | |
| 558 default: | |
| 559 debug_printf("unhandled plugin subtype %d\n", subtype); | |
| 560 break; | |
| 561 } | |
| 562 } |
