Also update the ui_color for menu backgrounds, when using set_menu_info.
Update the menu_info neverthless, when setting the ui_color for menu backgrounds. Fixes bug #550. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@23070 a95241bf-73f2-0310-859d-f6bbb57e9c96
This commit is contained in:
@@ -391,7 +391,9 @@ void
|
|||||||
DesktopSettingsPrivate::SetMenuInfo(const menu_info& info)
|
DesktopSettingsPrivate::SetMenuInfo(const menu_info& info)
|
||||||
{
|
{
|
||||||
fMenuInfo = info;
|
fMenuInfo = info;
|
||||||
Save(kAppearanceSettings);
|
// Also update the ui_color
|
||||||
|
SetUIColor(B_MENU_BACKGROUND_COLOR, info.background_color);
|
||||||
|
// SetUIColor already saves the settings
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
@@ -486,6 +488,10 @@ DesktopSettingsPrivate::SetUIColor(color_which which, const rgb_color color)
|
|||||||
if (index < 0 || index >= kNumColors)
|
if (index < 0 || index >= kNumColors)
|
||||||
return;
|
return;
|
||||||
fShared.colors[index] = color;
|
fShared.colors[index] = color;
|
||||||
|
// TODO: deprecate the background_color member of the menu_info struct,
|
||||||
|
// otherwise we have to keep this duplication...
|
||||||
|
if (which == B_MENU_BACKGROUND_COLOR)
|
||||||
|
fMenuInfo.background_color = color;
|
||||||
Save(kAppearanceSettings);
|
Save(kAppearanceSettings);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user