[statusbar] Remove statusbar_display

Signed-off-by: Julien Danjou <julien@danjou.info>
This commit is contained in:
Julien Danjou 2008-04-09 19:44:27 +02:00
parent e246410126
commit f31517817c
3 changed files with 7 additions and 12 deletions

View File

@ -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;
}

View File

@ -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,14 +161,6 @@ 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);
}

View File

@ -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;