propagate from branch 'im.pidgin.pidgin.mxit' (head 2629bf405a36a13177423301925120fe8...
[pidgin-git.git] / finch / gntui.c
bloba526055d370dab367f2e49102a58a6f46b93049c
1 /**
2 * finch
4 * Finch is the legal property of its developers, whose names are too numerous
5 * to list here. Please refer to the COPYRIGHT file distributed with this
6 * source distribution.
8 * This program is free software; you can redistribute it and/or modify
9 * it under the terms of the GNU General Public License as published by
10 * the Free Software Foundation; either version 2 of the License, or
11 * (at your option) any later version.
13 * This program is distributed in the hope that it will be useful,
14 * but WITHOUT ANY WARRANTY; without even the implied warranty of
15 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
16 * GNU General Public License for more details.
18 * You should have received a copy of the GNU General Public License
19 * along with this program; if not, write to the Free Software
20 * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02111-1301 USA
22 #include "finch.h"
23 #include <internal.h>
25 #include "gntui.h"
27 #include "gntaccount.h"
28 #include "gntblist.h"
29 #include "gntcertmgr.h"
30 #include "gntconn.h"
31 #include "gntconv.h"
32 #include "gntdebug.h"
33 #include "gntft.h"
34 #include "gntlog.h"
35 #include "gntmedia.h"
36 #include "gntnotify.h"
37 #include "gntplugin.h"
38 #include "gntpounce.h"
39 #include "gntprefs.h"
40 #include "gntrequest.h"
41 #include "gntroomlist.h"
42 #include "gntstatus.h"
43 #include "gntsound.h"
45 #include <prefs.h>
47 void gnt_ui_init()
49 #ifdef STANDALONE
50 gnt_init();
51 #endif
53 purple_prefs_add_none("/purple/gnt");
55 /* Accounts */
56 finch_accounts_init();
57 purple_accounts_set_ui_ops(finch_accounts_get_ui_ops());
59 /* Connections */
60 finch_connections_init();
61 purple_connections_set_ui_ops(finch_connections_get_ui_ops());
63 /* Initialize the buddy list */
64 finch_blist_init();
65 purple_blist_set_ui_ops(finch_blist_get_ui_ops());
67 /* Initialize sound */
68 purple_sound_set_ui_ops(finch_sound_get_ui_ops());
70 /* Now the conversations */
71 finch_conversation_init();
72 purple_conversations_set_ui_ops(finch_conv_get_ui_ops());
74 /* Notify */
75 finch_notify_init();
76 purple_notify_set_ui_ops(finch_notify_get_ui_ops());
78 /* Request */
79 finch_request_init();
80 purple_request_set_ui_ops(finch_request_get_ui_ops());
82 /* Pounce */
83 finch_pounces_init();
85 /* Log */
86 finch_log_init();
88 /* File transfer */
89 finch_xfers_init();
90 purple_xfers_set_ui_ops(finch_xfers_get_ui_ops());
92 /* Roomlist */
93 finch_roomlist_init();
94 purple_roomlist_set_ui_ops(finch_roomlist_get_ui_ops());
96 /* Media */
97 finch_media_manager_init();
99 gnt_register_action(_("Accounts"), finch_accounts_show_all);
100 gnt_register_action(_("Buddy List"), finch_blist_show);
101 gnt_register_action(_("Buddy Pounces"), finch_pounces_manager_show);
102 gnt_register_action(_("Certificates"), finch_certmgr_show);
103 gnt_register_action(_("Debug Window"), finch_debug_window_show);
104 gnt_register_action(_("File Transfers"), finch_xfer_dialog_show);
105 gnt_register_action(_("Plugins"), finch_plugins_show_all);
106 gnt_register_action(_("Room List"), finch_roomlist_show_all);
107 gnt_register_action(_("Sounds"), finch_sounds_show_all);
108 gnt_register_action(_("Preferences"), finch_prefs_show_all);
109 gnt_register_action(_("Statuses"), finch_savedstatus_show_all);
111 #ifdef STANDALONE
114 void gnt_ui_uninit()
116 purple_accounts_set_ui_ops(NULL);
117 finch_accounts_uninit();
119 purple_connections_set_ui_ops(NULL);
120 finch_connections_uninit();
122 purple_blist_set_ui_ops(NULL);
123 finch_blist_uninit();
125 purple_conversations_set_ui_ops(NULL);
126 finch_conversation_uninit();
128 purple_notify_set_ui_ops(NULL);
129 finch_notify_uninit();
131 purple_request_set_ui_ops(NULL);
132 finch_request_uninit();
134 finch_pounces_uninit();
136 finch_log_uninit();
138 finch_xfers_uninit();
139 purple_xfers_set_ui_ops(NULL);
141 finch_roomlist_uninit();
142 purple_roomlist_set_ui_ops(NULL);
144 #ifdef USE_VV
145 finch_media_manager_uninit();
146 #endif
148 gnt_quit();
149 #endif