mirror of
https://github.com/awesomeWM/awesome
synced 2024-11-17 07:47:41 +01:00
[statusbar] Remove statusbar_display
Signed-off-by: Julien Danjou <julien@danjou.info>
This commit is contained in:
parent
e246410126
commit
f31517817c
3 changed files with 7 additions and 12 deletions
5
event.c
5
event.c
|
@ -365,9 +365,10 @@ event_handle_expose(void *data __attribute__ ((unused)),
|
|||
{
|
||||
for(screen = 0; screen < globalconf.screens_info->nscreen; screen++)
|
||||
for(statusbar = globalconf.screens[screen].statusbar; statusbar; statusbar = statusbar->next)
|
||||
if(statusbar->sw->window == ev->window)
|
||||
if(statusbar->sw->window == ev->window
|
||||
&& statusbar->position)
|
||||
{
|
||||
statusbar_display(statusbar);
|
||||
simplewindow_refresh_drawable(statusbar->sw);
|
||||
return 0;
|
||||
}
|
||||
|
||||
|
|
13
statusbar.c
13
statusbar.c
|
@ -113,6 +113,9 @@ statusbar_draw(Statusbar *statusbar)
|
|||
int left = 0, right = 0;
|
||||
area_t rectangle = { 0, 0, 0, 0, NULL, NULL };
|
||||
|
||||
if(!statusbar->position)
|
||||
return;
|
||||
|
||||
rectangle.width = statusbar->width;
|
||||
rectangle.height = statusbar->height;
|
||||
draw_rectangle(statusbar->ctx, rectangle, 1.0, true,
|
||||
|
@ -158,15 +161,7 @@ statusbar_draw(Statusbar *statusbar)
|
|||
break;
|
||||
}
|
||||
|
||||
statusbar_display(statusbar);
|
||||
}
|
||||
|
||||
void
|
||||
statusbar_display(Statusbar *statusbar)
|
||||
{
|
||||
/* don't waste our time */
|
||||
if(statusbar->position != Off)
|
||||
simplewindow_refresh_drawable(statusbar->sw);
|
||||
simplewindow_refresh_drawable(statusbar->sw);
|
||||
}
|
||||
|
||||
void
|
||||
|
|
|
@ -27,7 +27,6 @@
|
|||
void statusbar_refresh(void);
|
||||
void statusbar_preinit(Statusbar *);
|
||||
void statusbar_init(Statusbar *);
|
||||
void statusbar_display(Statusbar *);
|
||||
Statusbar * statusbar_getbyname(int, const char *);
|
||||
|
||||
Uicb uicb_statusbar_toggle;
|
||||
|
|
Loading…
Reference in a new issue