mirror of
https://github.com/labwc/labwc.git
synced 2025-11-07 13:30:06 -05:00
desktop-entry: separate icon and app_id icon lookup
This patch splits desktop_entry_icon_lookup() into two separate functions - desktop_entry_load_icon(): load a icon from the configured icon theme - desktop_entry_load_icon_from_app_id(): load a icon name from a .desktop file based on the given app_id and supply it to _load_icon(). The _load_icon() function will be used in a future menu icon implementation whereas the _load_icon_from_app_id() function is used within the SSD titlebar window icon lookup routine.
This commit is contained in:
parent
d53cf642f5
commit
4ecedcdb3b
3 changed files with 51 additions and 35 deletions
|
|
@ -609,7 +609,7 @@ ssd_update_window_icon(struct ssd *ssd)
|
|||
*/
|
||||
float icon_scale = output_max_scale(ssd->view->server);
|
||||
|
||||
struct lab_img *icon_img = desktop_entry_icon_lookup(
|
||||
struct lab_img *icon_img = desktop_entry_load_icon_from_app_id(
|
||||
ssd->view->server, app_id, icon_size, icon_scale);
|
||||
if (!icon_img) {
|
||||
wlr_log(WLR_DEBUG, "icon could not be loaded for %s", app_id);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue