titlebar: fix titlebar rendering in tiled mode
Signed-off-by: Julien Danjou <julien@danjou.info>
This commit is contained in:
parent
1a31d49b3d
commit
7709b22261
3
client.c
3
client.c
|
@ -477,10 +477,7 @@ client_resize(client_t *c, area_t geometry, bool hints)
|
||||||
uint32_t values[5];
|
uint32_t values[5];
|
||||||
|
|
||||||
if(c->titlebar && !c->ismoving && !c->isfloating && layout != layout_floating)
|
if(c->titlebar && !c->ismoving && !c->isfloating && layout != layout_floating)
|
||||||
{
|
|
||||||
titlebar_update_geometry_tiled(c, geometry);
|
|
||||||
geometry = titlebar_geometry_remove(c->titlebar, geometry);
|
geometry = titlebar_geometry_remove(c->titlebar, geometry);
|
||||||
}
|
|
||||||
|
|
||||||
if(hints)
|
if(hints)
|
||||||
geometry = client_geometry_hints(c, geometry);
|
geometry = client_geometry_hints(c, geometry);
|
||||||
|
|
15
titlebar.h
15
titlebar.h
|
@ -33,9 +33,9 @@ void titlebar_init(client_t *);
|
||||||
int luaA_titlebar_userdata_new(titlebar_t *);
|
int luaA_titlebar_userdata_new(titlebar_t *);
|
||||||
|
|
||||||
/** Add the titlebar geometry to a geometry.
|
/** Add the titlebar geometry to a geometry.
|
||||||
* \param t the titlebar
|
* \param t The titlebar
|
||||||
* \param geometry the geometry
|
* \param geometry The geometry
|
||||||
* \return a new geometry bigger if the titlebar is visible
|
* \return A new geometry bigger if the titlebar is visible.
|
||||||
*/
|
*/
|
||||||
static inline area_t
|
static inline area_t
|
||||||
titlebar_geometry_add(titlebar_t *t, area_t geometry)
|
titlebar_geometry_add(titlebar_t *t, area_t geometry)
|
||||||
|
@ -65,9 +65,9 @@ titlebar_geometry_add(titlebar_t *t, area_t geometry)
|
||||||
}
|
}
|
||||||
|
|
||||||
/** Remove the titlebar geometry to a geometry.
|
/** Remove the titlebar geometry to a geometry.
|
||||||
* \param t the titlebar
|
* \param t The titlebar.
|
||||||
* \param geometry the geometry
|
* \param geometry The geometry.
|
||||||
* \return a new geometry smaller if the titlebar is visible
|
* \return A new geometry smaller if the titlebar is visible.
|
||||||
*/
|
*/
|
||||||
static inline area_t
|
static inline area_t
|
||||||
titlebar_geometry_remove(titlebar_t *t, area_t geometry)
|
titlebar_geometry_remove(titlebar_t *t, area_t geometry)
|
||||||
|
@ -97,7 +97,7 @@ titlebar_geometry_remove(titlebar_t *t, area_t geometry)
|
||||||
}
|
}
|
||||||
|
|
||||||
/** Update the titlebar geometry for a floating client.
|
/** Update the titlebar geometry for a floating client.
|
||||||
* \param c the client
|
* \param c The client.
|
||||||
*/
|
*/
|
||||||
static inline void
|
static inline void
|
||||||
titlebar_update_geometry_floating(client_t *c)
|
titlebar_update_geometry_floating(client_t *c)
|
||||||
|
@ -112,7 +112,6 @@ titlebar_update_geometry_floating(client_t *c)
|
||||||
titlebar_draw(c);
|
titlebar_draw(c);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
/** Update the titlebar geometry for a tiled client.
|
/** Update the titlebar geometry for a tiled client.
|
||||||
* \param c The client.
|
* \param c The client.
|
||||||
* \param geometry The geometry the client will receive.
|
* \param geometry The geometry the client will receive.
|
||||||
|
|
Loading…
Reference in New Issue