Skip to content

Commit

Permalink
hotfix for responsiveness
Browse files Browse the repository at this point in the history
  • Loading branch information
FelixKratz committed Sep 4, 2021
1 parent 0254302 commit a02ad0a
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 5 deletions.
5 changes: 2 additions & 3 deletions src/bar.c
Original file line number Diff line number Diff line change
Expand Up @@ -193,11 +193,10 @@ void bar_refresh(struct bar *bar) {

for (int i = 0; i < g_bar_manager.bar_item_count; i++) {
struct bar_item* bar_item = g_bar_manager.bar_items[i];
bar_item->is_shown = false;
if (!bar_item->drawing) continue;
if(bar_item->associated_display > 0 && !(bar_item->associated_display & (1 << did))) continue;
if(bar_item->associated_space > 0 && !(bar_item->associated_space & (1 << sid)) && (strcmp(bar_item->identifier, BAR_COMPONENT_SPACE) != 0)) continue;

bar_item->is_shown = false;
if (!bar_item->drawing) continue;
struct bar_line* label = &bar_item->label_line;
struct bar_line* icon = &bar_item->icon_line;
CGPoint icon_position = bar_align_line(bar, *icon, ALIGN_CENTER, ALIGN_CENTER);
Expand Down
2 changes: 0 additions & 2 deletions src/message.c
Original file line number Diff line number Diff line change
Expand Up @@ -421,12 +421,10 @@ static void handle_domain_set(FILE* rsp, struct token domain, char* message) {
struct token value = get_token(&message);
bar_item->label_highlight = token_equals(value, ARGUMENT_COMMON_VAL_ON) ? true : false;
bar_item_set_label(bar_item, bar_item->label);
bar_manager_refresh(&g_bar_manager);
} else if (token_equals(property, COMMAND_SET_ICON_HIGHLIGHT)) {
struct token value = get_token(&message);
bar_item->icon_highlight = token_equals(value, ARGUMENT_COMMON_VAL_ON) ? true : false;
bar_item_set_icon(bar_item, bar_item->icon);
bar_manager_refresh(&g_bar_manager);
}
// DEPRECATED
else if (token_equals(property, COMMAND_SET_ENABLED)) {
Expand Down

0 comments on commit a02ad0a

Please sign in to comment.