all repos — tint2 @ 070eb7ba4d2b615af42c9a51cae3fbc1721d218d

fork of the tint2 desktop panel for my custom setup - only minimized windows across all desktops for the taskbar

Revert "Area: do not destroy pixmap when not necessary"

This reverts commit f2922d7dbde35eadcea78e0536f5f61fb9ca4e39.
o9000 mrovi9000@gmail.com
commit

070eb7ba4d2b615af42c9a51cae3fbc1721d218d

parent

57c35549f33ebe3a3f3aac91f324d775a31f772c

1 files changed, 3 insertions(+), 14 deletions(-)

jump to
M src/util/area.csrc/util/area.c

@@ -419,24 +419,13 @@ }

void draw (Area *a) { - if (a->pix) { - unsigned int d1, width, height; - Window d2; - int d3; - XGetGeometry(server.dsp, server.root_win, &d2, &d3, &d3, &width, &height, &d1, &d1); - if (width != a->width || height != a->height) { - XFreePixmap (server.dsp, a->pix); - a->pix = XCreatePixmap(server.dsp, server.root_win, a->width, a->height, server.depth); - } - } else { - a->pix = XCreatePixmap(server.dsp, server.root_win, a->width, a->height, server.depth); - } + if (a->pix) XFreePixmap (server.dsp, a->pix); + a->pix = XCreatePixmap (server.dsp, server.root_win, a->width, a->height, server.depth); // add layer of root pixmap (or clear pixmap if real_transparency==true) if (server.real_transparency) clear_pixmap(a->pix, 0 ,0, a->width, a->height); - else - XCopyArea (server.dsp, ((Panel *)a->panel)->temp_pmap, a->pix, server.gc, a->posx, a->posy, a->width, a->height, 0, 0); + XCopyArea (server.dsp, ((Panel *)a->panel)->temp_pmap, a->pix, server.gc, a->posx, a->posy, a->width, a->height, 0, 0); cairo_surface_t *cs; cairo_t *c;