Merge lp:~bratsche/xsplash/improve-logging into lp:xsplash

Proposed by Cody Russell
Status: Merged
Merged at revision: not available
Proposed branch: lp:~bratsche/xsplash/improve-logging
Merge into: lp:xsplash
Diff against target: 205 lines
1 file modified
src/xsplash.c (+29/-29)
To merge this branch: bzr merge lp:~bratsche/xsplash/improve-logging
Reviewer Review Type Date Requested Status
Ted Gould (community) Approve
Review via email: mp+12552@code.launchpad.net
To post a comment you must log in.
Revision history for this message
Ted Gould (ted) :
review: Approve

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1=== modified file 'src/xsplash.c'
2--- src/xsplash.c 2009-09-28 16:30:02 +0000
3+++ src/xsplash.c 2009-09-28 21:35:19 +0000
4@@ -328,26 +328,26 @@
5 width = gdk_screen_get_width (screen);
6 height = gdk_screen_get_height (screen);
7
8- g_debug ("get_background_filename(): looking for appropriate resolution...");
9+ g_message ("get_background_filename(): looking for appropriate resolution...");
10 for (i = 0; i < (sizeof (widths) / sizeof (gint)); i++)
11 {
12 if (widths[i] > width && heights[i] && height)
13 {
14- g_debug (" ** %dx%d will work.", widths[i], heights[i]);
15+ g_message (" ** %dx%d will work.", widths[i], heights[i]);
16 last_good = i;
17 }
18 else
19 {
20- g_debug (" ** %dx%d is too small, using last good size.", widths[i], heights[i]);
21+ g_message (" ** %dx%d is too small, using last good size.", widths[i], heights[i]);
22 break;
23 }
24 }
25
26- g_debug (" ** Found a resolution: %dx%d", widths[last_good], heights[last_good]);
27+ g_message (" ** Found a resolution: %dx%d", widths[last_good], heights[last_good]);
28
29 ret = g_strdup_printf (DATADIR "/images/xsplash/bg_%dx%d.jpg", widths[last_good], heights[last_good]);
30
31- g_debug (" ** filename: %s", ret);
32+ g_message (" ** filename: %s", ret);
33
34 return ret;
35 }
36@@ -377,18 +377,18 @@
37
38 if (throbber_image != NULL)
39 {
40- g_debug ("get_throbber_filename(): user provided a throbber on the command line; using that");
41+ g_message ("get_throbber_filename(): user provided a throbber on the command line; using that");
42
43 return g_strdup (throbber_image);
44 }
45
46- g_debug ("get_throbber_filename(): looking for the best throbber for screen width...");
47+ g_message ("get_throbber_filename(): looking for the best throbber for screen width...");
48
49 ret = g_strdup_printf (DATADIR "/images/xsplash/throbber_%s.png",
50 get_filename_size_modifier (width));
51
52- g_debug (" ** Chose `%s'", get_filename_size_modifier (width));
53- g_debug (" ** throbber filename is: %s", ret);
54+ g_message (" ** Chose `%s'", get_filename_size_modifier (width));
55+ g_message (" ** throbber filename is: %s", ret);
56
57 return ret;
58 }
59@@ -405,18 +405,18 @@
60
61 if (logo_image != NULL)
62 {
63- g_debug ("get_logo_filename(): user provided a logo on the command line; using that");
64+ g_message ("get_logo_filename(): user provided a logo on the command line; using that");
65
66 return g_strdup (logo_image);
67 }
68
69- g_debug ("get_logo_filename(): looking for the best logo for screen width...");
70+ g_message ("get_logo_filename(): looking for the best logo for screen width...");
71
72 ret = g_strdup_printf (DATADIR "/images/xsplash/logo_%s.png",
73 get_filename_size_modifier (width));
74
75- g_debug (" ** Chose `%s'", get_filename_size_modifier (width));
76- g_debug (" ** logo filename is: %s", ret);
77+ g_message (" ** Chose `%s'", get_filename_size_modifier (width));
78+ g_message (" ** logo filename is: %s", ret);
79
80 return ret;
81 }
82@@ -578,7 +578,7 @@
83 }
84 else
85 {
86- g_debug ("couldn't load throbber image from file (%s); "
87+ g_message ("couldn't load throbber image from file (%s); "
88 "disabling throbber", throbber_image);
89 }
90 }
91@@ -648,7 +648,7 @@
92
93 gty_timeline_start (timeline);
94
95- g_debug ("throbber started (%d frames)", throbber_frames);
96+ g_message ("throbber started (%d frames)", throbber_frames);
97 }
98
99 static void
100@@ -696,7 +696,7 @@
101 switch (event->keyval)
102 {
103 case GDK_Escape:
104- g_debug ("ESC interrupt");
105+ g_message ("ESC interrupt");
106 begin_fade (server, TRUE);
107
108 /* else queue another fade? */
109@@ -761,7 +761,7 @@
110
111 anim_context_free (context);
112
113- g_debug ("fade finished");
114+ g_message ("fade finished");
115
116 if (context->exit_on_finish)
117 {
118@@ -798,7 +798,7 @@
119 {
120 XsplashServer *server = (XsplashServer *)user_data;
121
122- g_debug ("** timeout **");
123+ g_message ("** timeout **");
124
125 begin_fade (server, TRUE);
126
127@@ -813,13 +813,13 @@
128 if ((strcmp (name, ".") == 0) || strcmp (name, "..") == 0)
129 return;
130
131- g_debug ("adding signal `%s'", name);
132+ g_message ("adding signal `%s'", name);
133
134 for (tmp = signal_list; tmp != NULL; tmp = g_slist_next (signal_list))
135 {
136 if (strcmp (tmp->data, name) == 0)
137 {
138- g_debug (" ** that signal is already being listened for; skipping");
139+ g_message (" ** that signal is already being listened for; skipping");
140 return;
141 }
142 }
143@@ -841,7 +841,7 @@
144 void
145 sig_handler (int signum)
146 {
147- g_debug ("** interrupted **");
148+ g_message ("** interrupted **");
149 gtk_main_quit ();
150 }
151
152@@ -919,9 +919,9 @@
153 if (throbber_image == NULL)
154 throbber_image = get_throbber_filename ();
155
156- g_debug ("background_image = %s", background_image);
157- g_debug ("logo_image = %s", logo_image);
158- g_debug ("throbber_image = %s", throbber_image);
159+ g_message ("background_image = %s", background_image);
160+ g_message ("logo_image = %s", logo_image);
161+ g_message ("throbber_image = %s", throbber_image);
162
163 system_bus = dbus_g_bus_get (DBUS_BUS_SYSTEM, NULL);
164
165@@ -956,7 +956,7 @@
166
167 gtk_main ();
168
169- g_debug ("exiting...");
170+ g_message ("exiting...");
171
172 if (background_image != NULL)
173 g_free (background_image);
174@@ -982,7 +982,7 @@
175 gchar *waitfor,
176 GError **error)
177 {
178- g_debug ("received a new signal to wait for: %s", waitfor);
179+ g_message ("received a new signal to wait for: %s", waitfor);
180
181 if (waitfor)
182 {
183@@ -997,11 +997,11 @@
184 gchar *app,
185 GError **error)
186 {
187- g_debug ("received signal: %s", app);
188+ g_message ("received signal: %s", app);
189
190 if (gdm_session)
191 {
192- g_debug ("gdm mode: fading out");
193+ g_message ("gdm mode: fading out");
194 begin_fade (server, TRUE);
195 }
196 else
197@@ -1013,7 +1013,7 @@
198 {
199 if (strcmp (app, (gchar *)l->data) == 0)
200 {
201- g_debug ("received signal %s", (gchar*)l->data);
202+ g_message ("received signal %s", (gchar*)l->data);
203
204 g_free (l->data);
205 signal_list = g_slist_delete_link (signal_list, l);

Subscribers

People subscribed via source and target branches