Skip to content

Commit

Permalink
[fix]
Browse files Browse the repository at this point in the history
* try to search for an icon on the left hand if the right is empty or it
  returns default
  • Loading branch information
mlthelama committed Jan 14, 2023
1 parent f4c46fc commit c7c4d0e
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 1 deletion.
2 changes: 1 addition & 1 deletion CMakePresets.json
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
"cacheVariables": {
"CMAKE_BUILD_TYPE": {
"type": "STRING",
"value": "Debug"
"value": "Release"
}
},
"errors": {
Expand Down
5 changes: 5 additions & 0 deletions src/handle/page_handle.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -76,6 +76,11 @@ namespace handle {

//TODO for now the right hand or the first setting defines the icon
page->icon_type = get_icon_type(slots->front()->type, slots->front()->form);
if (slots->size() == 2 && page->icon_type == ui::icon_image_type::icon_default) {
logger::debug("Could not find an Icon with first setting, try next");
page->icon_type = get_icon_type(slots->at(1)->type, slots->at(1)->form);
}

page->icon_opacity = a_opacity;

page->key = a_key_pos->get_key_for_position(a_position);
Expand Down

0 comments on commit c7c4d0e

Please sign in to comment.