all repos — openbox @ da5f4e08f5e77fe6fe54d65b668aa129150b281b

openbox fork - make it a bit more like ryudo

Don't need to hang on to the hilite_rgba pointer any more.
Mikael Magnusson mikachu@comhem.se
commit

da5f4e08f5e77fe6fe54d65b668aa129150b281b

parent

23f3d6e34fcb4714c58e55b2528f897e2f0effe4

1 files changed, 4 insertions(+), 10 deletions(-)

jump to
M openbox/focus_cycle_popup.copenbox/focus_cycle_popup.c

@@ -63,8 +63,6 @@ RrAppearance *a_bg;

RrAppearance *a_text; RrAppearance *a_icon; - RrPixel32 *hilite_rgba; - gboolean mapped; };

@@ -94,6 +92,7 @@

void focus_cycle_popup_startup(gboolean reconfig) { XSetWindowAttributes attrib; + RrPixel32 *p; single_popup = icon_popup_new();

@@ -122,8 +121,8 @@ /* set up the hilite texture for the icon */

popup.a_icon->texture[1].data.rgba.width = ICON_SIZE; popup.a_icon->texture[1].data.rgba.height = ICON_SIZE; popup.a_icon->texture[1].data.rgba.alpha = 0xff; - popup.hilite_rgba = g_new(RrPixel32, ICON_SIZE * ICON_SIZE); - popup.a_icon->texture[1].data.rgba.data = popup.hilite_rgba; + p = g_new(RrPixel32, ICON_SIZE * ICON_SIZE); + popup.a_icon->texture[1].data.rgba.data = p; /* create the hilite under the target icon */ {

@@ -152,11 +151,9 @@ /* the background of the target */

a = 0x22; } - popup.hilite_rgba[o++] = - color + (a << RrDefaultAlphaOffset); + p[o++] = color + (a << RrDefaultAlphaOffset); } } - stacking_add(INTERNAL_AS_WINDOW(&popup)); window_add(&popup.bg, INTERNAL_AS_WINDOW(&popup));

@@ -178,9 +175,6 @@ XDestroyWindow(obt_display, t->textwin);

popup.targets = g_list_delete_link(popup.targets, popup.targets); } - - g_free(popup.hilite_rgba); - popup.hilite_rgba = NULL; XDestroyWindow(obt_display, popup.bg);