X-Git-Url: https://git.dogcows.com/gitweb?a=blobdiff_plain;f=openbox%2Faction.c;h=ec5230e44589dda93cd2e1852c51617206aae88a;hb=92d3f2342db3d3bfd5d41a6c3dc165efa7766ffa;hp=41e174d98e65c7b939d17137ef7d23a0752356f5;hpb=16a9ac018ed77e245e873be60729be509fa1ce92;p=chaz%2Fopenbox diff --git a/openbox/action.c b/openbox/action.c index 41e174d9..ec5230e4 100644 --- a/openbox/action.c +++ b/openbox/action.c @@ -1,12 +1,10 @@ #include "client.h" -#include "grab.h" #include "focus.h" #include "moveresize.h" #include "menu.h" #include "prop.h" #include "stacking.h" #include "frame.h" -#include "framerender.h" #include "screen.h" #include "action.h" #include "dispatch.h" @@ -683,49 +681,11 @@ void action_showmenu(union ActionData *data) } } -static void popup_cycle(Client *c, gboolean hide) -{ - XSetWindowAttributes attrib; - static Window coords = None; - - if (coords == None) { - attrib.override_redirect = TRUE; - coords = XCreateWindow(ob_display, ob_root, - 0, 0, 1, 1, 0, render_depth, InputOutput, - render_visual, CWOverrideRedirect, &attrib); - g_assert(coords != None); - - grab_pointer(TRUE, None); - - XMapWindow(ob_display, coords); - } - - if (hide) { - XDestroyWindow(ob_display, coords); - coords = None; - - grab_pointer(FALSE, None); - } else { - Rect *a; - Size s; - - a = screen_area(c->desktop); - - framerender_size_popup_label(c->title, &s); - XMoveResizeWindow(ob_display, coords, - a->x + (a->width - s.width) / 2, - a->y + (a->height - s.height) / 2, - s.width, s.height); - framerender_popup_label(coords, &s, c->title); - } -} - void action_cycle_windows(union ActionData *data) { Client *c; c = focus_cycle(data->cycle.forward, data->cycle.linear, data->cycle.final, data->cycle.cancel); - popup_cycle(c, !c || data->cycle.final || data->cycle.cancel); }