perf(runtime): bar 不可见时跳过更新避免无效重绘
This commit is contained in:
@@ -484,6 +484,8 @@ static void runtime_handle_event(runtime_t *runtime, short int revents) {
|
||||
|
||||
static inline void runtime_update_bar(runtime_t *runtime) {
|
||||
auto bar = &runtime->bar;
|
||||
if (!bar->visible) return;
|
||||
|
||||
bar_update(bar);
|
||||
bar_draw(bar);
|
||||
backend_flush(runtime->backend);
|
||||
|
||||
Reference in New Issue
Block a user