Use the correct color for the tab border for inactive windows.

Before this the active window border color was used, resulting in ugly inactive
window tabs if the active and inactive border colors were quite different.

This was not noticed before because the defaults are two very similar grays.
This commit is contained in:
Ryan Leavengood 2012-06-09 22:27:29 -04:00
parent 20b3f78f8d
commit 70a5df3878

View File

@ -1490,17 +1490,21 @@ DefaultDecorator::GetComponentColors(Component component, uint8 highlight,
DefaultDecorator::Tab* tab = static_cast<DefaultDecorator::Tab*>(_tab);
switch (component) {
case COMPONENT_TAB:
_colors[COLOR_TAB_FRAME_LIGHT]
= tint_color(kFocusFrameColor, B_DARKEN_2_TINT);
_colors[COLOR_TAB_FRAME_DARK]
= tint_color(kFocusFrameColor, B_DARKEN_3_TINT);
if (tab && tab->buttonFocus) {
_colors[COLOR_TAB_FRAME_LIGHT]
= tint_color(kFocusFrameColor, B_DARKEN_2_TINT);
_colors[COLOR_TAB_FRAME_DARK]
= tint_color(kFocusFrameColor, B_DARKEN_3_TINT);
_colors[COLOR_TAB] = kFocusTabColor;
_colors[COLOR_TAB_LIGHT] = kFocusTabColorLight;
_colors[COLOR_TAB_BEVEL] = kFocusTabColorBevel;
_colors[COLOR_TAB_SHADOW] = kFocusTabColorShadow;
_colors[COLOR_TAB_TEXT] = kFocusTextColor;
} else {
_colors[COLOR_TAB_FRAME_LIGHT]
= tint_color(kNonFocusFrameColor, B_DARKEN_2_TINT);
_colors[COLOR_TAB_FRAME_DARK]
= tint_color(kNonFocusFrameColor, B_DARKEN_3_TINT);
_colors[COLOR_TAB] = kNonFocusTabColor;
_colors[COLOR_TAB_LIGHT] = kNonFocusTabColorLight;
_colors[COLOR_TAB_BEVEL] = kNonFocusTabColorBevel;