void init_clock()
{
- if(time1_format && clock_timeout==0) {
- if (strchr(time1_format, 'S') || strchr(time1_format, 'T') || strchr(time1_format, 'r'))
+ if((time1_format || time2_format) && clock_timeout==0) {
+ if (strchr(time1_format, 'S') || strchr(time1_format, 'T') || strchr(time1_format, 'r') ||
+ strchr(time2_format, 'S') || strchr(time2_format, 'T') || strchr(time2_format, 'r'))
clock_timeout = add_timeout(10, 1000, update_clocks_sec, 0);
else
clock_timeout = add_timeout(10, 1000, update_clocks_min, 0);
{
Panel *panel =(Panel*)p;
Clock *clock = &panel->clock;
-
+
+ if (clock->area.bg == 0)
+ clock->area.bg = &g_array_index(backgrounds, Background, 0);
clock->area.parent = p;
clock->area.panel = p;
clock->area._draw_foreground = draw_clock;