mirror of
https://github.com/FelixKratz/SketchyBar
synced 2025-02-16 12:38:26 +00:00
properly disable update if no window operation is needed (#507)
This commit is contained in:
parent
4c457077c9
commit
71051799af
1 changed files with 2 additions and 1 deletions
|
@ -149,6 +149,7 @@ void bar_draw(struct bar* bar, bool forced) {
|
|||
background.bounds.origin.y -= background.y_offset;
|
||||
background.shadow.enabled = false;
|
||||
background.enabled = true;
|
||||
windows_freeze();
|
||||
CGContextClearRect(bar->window.context, bar->window.frame);
|
||||
background_draw(&background, bar->window.context);
|
||||
}
|
||||
|
@ -185,8 +186,8 @@ void bar_draw(struct bar* bar, bool forced) {
|
|||
window_assign_mouse_tracking_area(window, window->frame);
|
||||
}
|
||||
|
||||
windows_freeze();
|
||||
CGContextClearRect(window->context, window->frame);
|
||||
|
||||
bar_item_draw(bar_item, window->context);
|
||||
CGContextFlush(window->context);
|
||||
}
|
||||
|
|
Loading…
Add table
Reference in a new issue