Refresh menu correctly after loading skin: Restore multi-state buttons, which buttons are highlighted, and current paintbrush in top left icon.
git-svn-id: svn://pulkomandy.tk/GrafX2/trunk@1499 416bcca6-2ee7-4201-b75f-2eb2f807beb1
This commit is contained in:
parent
575d9e3be5
commit
8c5e4fa730
@ -1258,6 +1258,7 @@ void Button_Skins(void)
|
|||||||
byte separatecolors = Config.Separate_colors;
|
byte separatecolors = Config.Separate_colors;
|
||||||
byte showlimits = Config.Display_image_limits;
|
byte showlimits = Config.Display_image_limits;
|
||||||
byte need_load=1;
|
byte need_load=1;
|
||||||
|
int button;
|
||||||
|
|
||||||
word x, y, x_pos, offs_y;
|
word x, y, x_pos, offs_y;
|
||||||
|
|
||||||
@ -1485,6 +1486,22 @@ void Button_Skins(void)
|
|||||||
|
|
||||||
// Raffichage du menu pour que les inscriptions qui y figurent soient retracées avec la nouvelle fonte
|
// Raffichage du menu pour que les inscriptions qui y figurent soient retracées avec la nouvelle fonte
|
||||||
Display_menu();
|
Display_menu();
|
||||||
|
// Redraw all buttons, to ensure all specific sprites are in place.
|
||||||
|
// This is necessary for multi-state buttons, for example Freehand.
|
||||||
|
for (button=0; button<NB_BUTTONS; button++)
|
||||||
|
{
|
||||||
|
byte state=Buttons_Pool[button].Pressed;
|
||||||
|
switch(button)
|
||||||
|
{
|
||||||
|
case BUTTON_MAGNIFIER:
|
||||||
|
state|=Main_magnifier_mode;
|
||||||
|
break;
|
||||||
|
case BUTTON_EFFECTS:
|
||||||
|
state|=(Shade_mode||Quick_shade_mode||Colorize_mode||Smooth_mode||Tiling_mode||Smear_mode||Stencil_mode||Mask_mode||Sieve_mode||Snap_mode);
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
Draw_menu_button(button,state);
|
||||||
|
}
|
||||||
Display_cursor();
|
Display_cursor();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user