client: remove banning_refresh (FS#631)

Signed-off-by: Julien Danjou <julien@danjou.info>
This commit is contained in:
Julien Danjou 2009-09-21 15:01:36 +02:00
parent 7fae0db5ea
commit c5acc8f613
3 changed files with 5 additions and 15 deletions

View File

@ -931,9 +931,8 @@ client_set_minimized(lua_State *L, int cidx, bool s)
if(c->minimized != s) if(c->minimized != s)
{ {
client_need_reban(c);
c->minimized = s; c->minimized = s;
client_need_reban(c); banning_refresh((c)->screen);
if(s) if(s)
window_state_set(c->window, XCB_WM_STATE_ICONIC); window_state_set(c->window, XCB_WM_STATE_ICONIC);
else else
@ -959,9 +958,8 @@ client_set_sticky(lua_State *L, int cidx, bool s)
if(c->sticky != s) if(c->sticky != s)
{ {
client_need_reban(c);
c->sticky = s; c->sticky = s;
client_need_reban(c); banning_refresh((c)->screen);
ewmh_client_update_hints(c); ewmh_client_update_hints(c);
hook_property(c, "sticky"); hook_property(c, "sticky");
luaA_object_emit_signal(L, cidx, "property::sticky", 0); luaA_object_emit_signal(L, cidx, "property::sticky", 0);
@ -1675,9 +1673,8 @@ luaA_client_set_hidden(lua_State *L, client_t *c)
bool b = luaA_checkboolean(L, -1); bool b = luaA_checkboolean(L, -1);
if(b != c->hidden) if(b != c->hidden)
{ {
client_need_reban(c);
c->hidden = b; c->hidden = b;
client_need_reban(c); banning_refresh((c)->screen);
hook_property(c, "hidden"); hook_property(c, "hidden");
if(strut_has_value(&c->strut)) if(strut_has_value(&c->strut))
screen_emit_signal(globalconf.L, c->screen, "property::workarea", 0); screen_emit_signal(globalconf.L, c->screen, "property::workarea", 0);

View File

@ -160,12 +160,6 @@ lua_class_t client_class;
LUA_OBJECT_FUNCS(client_class, client_t, client) LUA_OBJECT_FUNCS(client_class, client_t, client)
#define client_need_reban(c) \
do { \
if(client_isvisible(c, (c)->screen)) \
banning_refresh((c)->screen); \
} while(0)
bool client_maybevisible(client_t *, screen_t *); bool client_maybevisible(client_t *, screen_t *);
client_t * client_getbywin(xcb_window_t); client_t * client_getbywin(xcb_window_t);
void client_ban(client_t *); void client_ban(client_t *);

5
tag.c
View File

@ -226,7 +226,7 @@ tag_client(client_t *c)
client_array_append(&t->clients, c); client_array_append(&t->clients, c);
ewmh_client_update_desktop(c); ewmh_client_update_desktop(c);
client_need_reban(c); banning_refresh((c)->screen);
/* call hook */ /* call hook */
if(globalconf.hooks.tagged != LUA_REFNIL) if(globalconf.hooks.tagged != LUA_REFNIL)
@ -248,9 +248,8 @@ untag_client(client_t *c, tag_t *t)
for(int i = 0; i < t->clients.len; i++) for(int i = 0; i < t->clients.len; i++)
if(t->clients.tab[i] == c) if(t->clients.tab[i] == c)
{ {
client_need_reban(c);
client_array_take(&t->clients, i); client_array_take(&t->clients, i);
client_need_reban(c); banning_refresh((c)->screen);
ewmh_client_update_desktop(c); ewmh_client_update_desktop(c);
/* call hook */ /* call hook */
if(globalconf.hooks.tagged != LUA_REFNIL) if(globalconf.hooks.tagged != LUA_REFNIL)