mirror of
https://github.com/CTCaer/hekate
synced 2024-12-22 11:21:23 +00:00
nyx: Allow hue icons from section names
This commit is contained in:
parent
c7ab404fc1
commit
f56d1bad04
2 changed files with 13 additions and 10 deletions
|
@ -1293,7 +1293,7 @@ static lv_res_t _win_launch_close_action(lv_obj_t * btn)
|
|||
lv_img_dsc_t *src = (lv_img_dsc_t *)lv_img_get_src(img);
|
||||
|
||||
// Avoid freeing base icons.
|
||||
if ((src != icon_switch) && (src != icon_payload) && (src != icon_lakka))
|
||||
if ((src != icon_switch) && (src != icon_payload))
|
||||
free(src);
|
||||
}
|
||||
}
|
||||
|
@ -1576,9 +1576,13 @@ ini_parsing:
|
|||
bmp = bmp_to_lvimg_obj(tmp_path);
|
||||
if (!bmp)
|
||||
{
|
||||
if (!strcmp(ini_sec->name, "Lakka"))
|
||||
bmp = icon_lakka;
|
||||
else if (payload)
|
||||
s_printf(tmp_path, "bootloader/res/%s_hue.bmp", ini_sec->name);
|
||||
bmp = bmp_to_lvimg_obj(tmp_path);
|
||||
if (bmp)
|
||||
img_colorize = true;
|
||||
}
|
||||
|
||||
if (!bmp && payload)
|
||||
{
|
||||
bmp = icon_payload;
|
||||
|
||||
|
@ -1586,7 +1590,6 @@ ini_parsing:
|
|||
img_colorize = true;
|
||||
}
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
bmp = bmp_to_lvimg_obj(icon_path);
|
||||
|
|
|
@ -373,7 +373,7 @@ void nyx_init_load_res()
|
|||
else
|
||||
icon_payload = bmp_to_lvimg_obj("bootloader/res/icon_payload_custom.bmp");
|
||||
|
||||
icon_lakka = bmp_to_lvimg_obj("bootloader/res/icon_lakka.bmp");
|
||||
// Load background resource if any.
|
||||
hekate_bg = bmp_to_lvimg_obj("bootloader/res/background.bmp");
|
||||
|
||||
sd_unmount(false);
|
||||
|
|
Loading…
Reference in a new issue