client: merge lower code

Signed-off-by: Julien Danjou <julien@danjou.info>
This commit is contained in:
Julien Danjou 2009-08-28 17:53:48 +02:00
parent 3a1cbd6e35
commit 17759578fa
2 changed files with 9 additions and 16 deletions

View File

@ -1535,7 +1535,15 @@ static int
luaA_client_lower(lua_State *L) luaA_client_lower(lua_State *L)
{ {
client_t *c = luaA_client_checkudata(L, 1); client_t *c = luaA_client_checkudata(L, 1);
client_lower(c);
stack_client_push(c);
/* Traverse all transient layers. */
for(client_t *tc = c->transient_for; tc; tc = tc->transient_for)
stack_client_push(tc);
client_stack();
return 0; return 0;
} }

View File

@ -245,21 +245,6 @@ client_raise(client_t *c)
client_stack(); client_stack();
} }
/** Put client on the end of the stack.
* \param c The client to lower.
*/
static inline void
client_lower(client_t *c)
{
stack_client_push(c);
/* Traverse all transient layers. */
for(client_t *tc = c->transient_for; tc; tc = tc->transient_for)
stack_client_push(tc);
client_stack();
}
/** Check if a client has fixed size. /** Check if a client has fixed size.
* \param c A client. * \param c A client.
* \return A boolean value, true if the client has a fixed size. * \return A boolean value, true if the client has a fixed size.