Mercurial > pidgin
comparison src/gtkblist.c @ 12080:3b52d94437f3
[gaim-migrate @ 14377]
The rest of sf patch #1354886, from Sadrul Habib Chowdhury, with
an EXTREME amount of changes from me. Come to me, first, if something
doesn't work.
This allows you to edit the substatuses of a saved status.
committer: Tailor Script <tailor@pidgin.im>
author | Mark Doliner <mark@kingant.net> |
---|---|
date | Mon, 14 Nov 2005 07:20:22 +0000 |
parents | e4666705944b |
children | 875f59f9c0bb |
comparison
equal
deleted
inserted
replaced
12079:15732b01ea3d | 12080:3b52d94437f3 |
---|---|
4839 gaim_gtk_blist_uninit(void) { | 4839 gaim_gtk_blist_uninit(void) { |
4840 gaim_signals_unregister_by_instance(gaim_gtk_blist_get_handle()); | 4840 gaim_signals_unregister_by_instance(gaim_gtk_blist_get_handle()); |
4841 } | 4841 } |
4842 | 4842 |
4843 /********************************************************************* | 4843 /********************************************************************* |
4844 * Public utility functions * | |
4845 *********************************************************************/ | |
4846 | |
4847 GdkPixbuf * | |
4848 gaim_gtk_create_prpl_icon(GaimAccount *account) | |
4849 { | |
4850 GaimPlugin *prpl; | |
4851 GaimPluginProtocolInfo *prpl_info = NULL; | |
4852 GdkPixbuf *status = NULL; | |
4853 char *filename = NULL; | |
4854 const char *protoname = NULL; | |
4855 char buf[256]; | |
4856 | |
4857 g_return_val_if_fail(account != NULL, NULL); | |
4858 | |
4859 prpl = gaim_find_prpl(gaim_account_get_protocol_id(account)); | |
4860 | |
4861 if (prpl != NULL) { | |
4862 prpl_info = GAIM_PLUGIN_PROTOCOL_INFO(prpl); | |
4863 | |
4864 if (prpl_info->list_icon != NULL) | |
4865 protoname = prpl_info->list_icon(account, NULL); | |
4866 } | |
4867 | |
4868 if (protoname == NULL) | |
4869 return NULL; | |
4870 | |
4871 /* | |
4872 * Status icons will be themeable too, and then it will look up | |
4873 * protoname from the theme | |
4874 */ | |
4875 g_snprintf(buf, sizeof(buf), "%s.png", protoname); | |
4876 | |
4877 filename = g_build_filename(DATADIR, "pixmaps", "gaim", "status", | |
4878 "default", buf, NULL); | |
4879 status = gdk_pixbuf_new_from_file(filename, NULL); | |
4880 g_free(filename); | |
4881 | |
4882 return status; | |
4883 } | |
4884 | |
4885 | |
4886 /********************************************************************* | |
4887 * Buddy List sorting functions * | 4844 * Buddy List sorting functions * |
4888 *********************************************************************/ | 4845 *********************************************************************/ |
4889 | 4846 |
4890 GList *gaim_gtk_blist_get_sort_methods() | 4847 GList *gaim_gtk_blist_get_sort_methods() |
4891 { | 4848 { |