comparison console/gntdebug.c @ 14010:7573bd40a190

[gaim-migrate @ 16602] Allow plugins to be loaded and unloaded. Remember the window positions and sizes. All turning on/off shadow from ~/.gntrc (off by default). committer: Tailor Script <tailor@pidgin.im>
author Sadrul Habib Chowdhury <imadil@gmail.com>
date Mon, 31 Jul 2006 23:19:12 +0000
parents a7b1d2ab9cb0
children 2d1b41e3cf0d
comparison
equal deleted inserted replaced
14009:1e283c3566ab 14010:7573bd40a190
37 37
38 static void 38 static void
39 gg_debug_print(GaimDebugLevel level, const char *category, 39 gg_debug_print(GaimDebugLevel level, const char *category,
40 const char *args) 40 const char *args)
41 { 41 {
42 if (debug.window == NULL) 42 if (debug.window)
43 fprintf(stderr, "%s: %s\n", category, args);
44 else
45 { 43 {
46 GntTextFormatFlags flag = GNT_TEXT_FLAG_NORMAL; 44 GntTextFormatFlags flag = GNT_TEXT_FLAG_NORMAL;
47 45
48 gnt_text_view_append_text_with_flags(GNT_TEXT_VIEW(debug.tview), 46 gnt_text_view_append_text_with_flags(GNT_TEXT_VIEW(debug.tview),
49 category, GNT_TEXT_FLAG_BOLD); 47 category, GNT_TEXT_FLAG_BOLD);
103 gnt_widget_show(debug.window); 101 gnt_widget_show(debug.window);
104 } 102 }
105 103
106 void gg_debug_init() 104 void gg_debug_init()
107 { 105 {
108 gg_debug_window_show(); 106 if (gaim_debug_is_enabled())
107 gg_debug_window_show();
109 } 108 }
110 109
111 void gg_debug_uninit() 110 void gg_debug_uninit()
112 { 111 {
113 } 112 }