]> Dogcows Code - chaz/tint2/blobdiff - src/tint.c
*add* interval timeouts are aligned to each other
[chaz/tint2] / src / tint.c
index 7c167d8ef3d9f9f8ed3c7ae3c95863c1c27d8b54..5c4ee1693c670dfca81ba8f44d706277fd7375f7 100644 (file)
@@ -139,6 +139,7 @@ void init_X11()
 
 void cleanup()
 {
+       stop_all_timeouts();
        cleanup_systray();
        stop_net();
        cleanup_panel();
@@ -849,9 +850,18 @@ int main (int argc, char *argv[])
                                                break;
 
                                        default:
-                                               if (e.type == XDamageNotify+damage_event)
-                                                       // TODO: update only the damaged icon, not all of them
-                                                       systray.area.redraw = 1;
+                                               if (e.type == XDamageNotify+damage_event) {
+                                                       TrayWindow *traywin;
+                                                       GSList *l;
+                                                       XDamageNotifyEvent* de = (XDamageNotifyEvent*)&e;
+                                                       for (l = systray.list_icons; l ; l = l->next) {
+                                                               traywin = (TrayWindow*)l->data;
+                                                               if ( traywin->id == de->drawable && !de->more ) {
+                                                                       systray_render_icon(traywin);
+                                                                       break;
+                                                               }
+                                                       }
+                                               }
                                }
                        }
                }
This page took 0.024461 seconds and 4 git commands to generate.