diff --git a/data/skins/Ocean.stkskin b/data/skins/Ocean.stkskin
index f3808d440..890138cc0 100644
--- a/data/skins/Ocean.stkskin
+++ b/data/skins/Ocean.stkskin
@@ -237,8 +237,10 @@ when the border that intersect at this corner are enabled.
+
+
diff --git a/data/skins/Peach.stkskin b/data/skins/Peach.stkskin
index 9848f0032..5951a560c 100644
--- a/data/skins/Peach.stkskin
+++ b/data/skins/Peach.stkskin
@@ -235,8 +235,10 @@ when the border that intersect at this corner are enabled.
+
+
diff --git a/src/guiengine/skin.cpp b/src/guiengine/skin.cpp
index b7cb3f4e7..1cb72945d 100644
--- a/src/guiengine/skin.cpp
+++ b/src/guiengine/skin.cpp
@@ -691,7 +691,6 @@ X##_yflip.LowerRightCorner.Y = w->m_skin_dest_y + \
void Skin::drawButton(Widget* w, const core::recti &rect,
const bool pressed, const bool focused)
{
-
// if within an appearing dialog, grow
if (m_dialog && m_dialog_size < 1.0f && w->m_parent != NULL &&
w->m_parent->getType() == gui::EGUIET_WINDOW)
@@ -2101,8 +2100,10 @@ void Skin::draw3DSunkenPane (IGUIElement *element, video::SColor bgcolor,
{
SColor& bg_color = SkinConfig::m_colors["text_field::background"];
SColor& bg_color_focused = SkinConfig::m_colors["text_field::background_focused"];
+ SColor& bg_color_deactivated = SkinConfig::m_colors["text_field::background_deactivated"];
SColor& border_color = SkinConfig::m_colors["text_field::neutral"];
SColor& border_color_focus = SkinConfig::m_colors["text_field::focused"];
+ SColor& border_color_deactivated = SkinConfig::m_colors["text_field::deactivated"];
core::recti borderArea = rect;
//borderArea.UpperLeftCorner -= position2d< s32 >( 2, 2 );
@@ -2128,12 +2129,22 @@ void Skin::draw3DSunkenPane (IGUIElement *element, video::SColor bgcolor,
center.Y + (int)(((int)rect.LowerRightCorner.Y
- (int)center.Y)*texture_size);
}
- GL32_draw2DRectangle(focused ? border_color_focus : border_color, borderArea);
+ if(widget->m_deactivated)
+ GL32_draw2DRectangle(border_color_deactivated, borderArea);
+ else if(focused)
+ GL32_draw2DRectangle(border_color_focus, borderArea);
+ else
+ GL32_draw2DRectangle(border_color, borderArea);
core::recti innerArea = borderArea;
innerArea.UpperLeftCorner += position2d< s32 >( 3, 3 );
innerArea.LowerRightCorner -= position2d< s32 >( 3, 3 );
- GL32_draw2DRectangle(focused ? bg_color_focused : bg_color, innerArea);
+ if(widget->m_deactivated)
+ GL32_draw2DRectangle(bg_color_deactivated, innerArea);
+ else if(focused)
+ GL32_draw2DRectangle(bg_color_focused, innerArea);
+ else
+ GL32_draw2DRectangle(bg_color, innerArea);
return;
}
else if (type == WTYPE_LIST)