Tiling2: E_Client already has a property for sticky, use it.

Before this change, I duplicated this in extra.
This commit is contained in:
Tom Hacohen 2014-01-23 15:09:21 +00:00
parent e2f4596ff7
commit bf69b855b3
1 changed files with 2 additions and 5 deletions

View File

@ -19,7 +19,6 @@ typedef struct Client_Extra {
const char *bordername; const char *bordername;
} orig; } orig;
int last_frame_adjustment; // FIXME: Hack for frame resize bug. int last_frame_adjustment; // FIXME: Hack for frame resize bug.
Eina_Bool sticky : 1;
Eina_Bool floating : 1; Eina_Bool floating : 1;
Eina_Bool tiled : 1; Eina_Bool tiled : 1;
} Client_Extra; } Client_Extra;
@ -130,7 +129,7 @@ desk_should_tile_check(const E_Desk *desk)
static int static int
is_ignored_window(const Client_Extra *extra) is_ignored_window(const Client_Extra *extra)
{ {
if (extra->sticky || extra->floating) if (extra->client->sticky || extra->floating)
return true; return true;
return false; return false;
@ -961,10 +960,8 @@ toggle_sticky(E_Client *ec)
return; return;
} }
extra->sticky = !extra->sticky;
/* This is the new state, act accordingly. */ /* This is the new state, act accordingly. */
if (extra->sticky) if (ec->sticky)
{ {
_restore_client(ec); _restore_client(ec);
_remove_client(ec); _remove_client(ec);