small problem with windows, hope this fixes it
[sgc.git] / main.c
blob409e4fc474a28b033dbb77d5da2f989b37470339
1 #include "sgc.h"
2 #include "praat.h"
3 #include "signals.h"
5 GladeXML *xml = NULL;
7 int main(int argc, char **argv)
9 void * needed;
10 needed = (void *)on_buttonRecord_clicked;
11 needed = (void *)on_treeviewWords_cursor_changed;
12 needed = (void *)on_buttonSaveDistribution_clicked;
13 needed = (void *)paint;
14 needed = (void *)on_menuitemVoice_activate;
15 needed = (void *)on_buttonExample_clicked;
16 needed = (void *)on_Save;
17 needed = (void *)on_buttonSave_clicked;
18 needed = (void *)on_filechooserdialog_realize;
19 needed = (void *)on_treeother;
20 needed = (void *)on_buttonAddAdd_clicked;
21 needed = (void *)on_menuitemShuffle_activate;
22 needed = (void *)remove_entry;
23 needed = (void *)on_buttonPlay_clicked;
24 needed = (void *)on_buttonSaveNew_clicked;
25 needed = (void *)configSave;
26 needed = (void *)on_menuWordlists_realize;
27 needed = (void *)on_buttonOpen_clicked;
29 gtk_init(&argc, &argv);
31 bindtextdomain(g_get_application_name(), LOCALEDIR);
33 /* textdomain(g_get_application_name());
35 * This makes the application use a standard domain,
36 * instead of a changing program name. For example
37 * on win32 it will be sgc.exe
40 textdomain("sgc");
42 xml = glade_xml_new(GLADESOURCE, NULL, g_get_application_name());
44 if (xml == NULL) {
45 g_error(_("Could not open the GUI!"));
46 return -1;
47 } else {
48 if (!g_thread_supported()) {
49 g_thread_init(NULL);
52 /* connect signal handlers */
53 glade_xml_signal_autoconnect(xml);
55 on_windowMain_realize(NULL, NULL);
57 g_thread_create((GThreadFunc)sound_init, NULL, FALSE, NULL);
59 removeRecordings();
61 gtk_main();
63 removeRecordings();
65 setBase(NULL);
66 setFile(NULL);
68 return 0;