From 68ef4981e439a44c0e962feaa80b50096b77a922 Mon Sep 17 00:00:00 2001 From: Keuckdo Bang Date: Mon, 20 May 2013 17:10:44 +0900 Subject: [PATCH] Merget from master branch. Change-Id: I1284e43949468153c8631735e0dbf7f75ce93cdf --- src/ui/controls/FUiCtrl_Form.cpp | 56 +++++++++++++++++++++++++++++++++--- src/ui/controls/FUiCtrl_FormImpl.cpp | 14 +++++++++ 2 files changed, 66 insertions(+), 4 deletions(-) diff --git a/src/ui/controls/FUiCtrl_Form.cpp b/src/ui/controls/FUiCtrl_Form.cpp index b2b14f3..fb36501 100644 --- a/src/ui/controls/FUiCtrl_Form.cpp +++ b/src/ui/controls/FUiCtrl_Form.cpp @@ -2708,7 +2708,13 @@ _Form::GetIndicatorBounds(void) const FrameShowMode mode = pFrame->GetShowMode(); if (mode != FRAME_SHOW_MODE_FULL_SCREEN) { - return Rectangle(0, 0, 0, 0); + if (mode == FRAME_SHOW_MODE_MINIMIZED) + { + if (pFrame->GetShowMode(false) != FRAME_SHOW_MODE_FULL_SCREEN) + { + return Rectangle(0, 0, 0, 0); + } + } } } @@ -2742,7 +2748,13 @@ _Form::GetIndicatorBoundsF(void) const FrameShowMode mode = pFrame->GetShowMode(); if (mode != FRAME_SHOW_MODE_FULL_SCREEN) { - return FloatRectangle(0.0f, 0.0f, 0.0f, 0.0f); + if (mode == FRAME_SHOW_MODE_MINIMIZED) + { + if (pFrame->GetShowMode(false) != FRAME_SHOW_MODE_FULL_SCREEN) + { + return FloatRectangle(0.0f, 0.0f, 0.0f, 0.0f); + } + } } } @@ -3031,7 +3043,25 @@ _Form::AdjustClientBounds(void) if (pFrame) { FrameShowMode mode = pFrame->GetShowMode(); - if (mode == FRAME_SHOW_MODE_FULL_SCREEN) + + if (mode != FRAME_SHOW_MODE_FULL_SCREEN) + { + if (mode == FRAME_SHOW_MODE_MINIMIZED) + { + if (pFrame->GetShowMode(false) == FRAME_SHOW_MODE_FULL_SCREEN) + { + if (FORM_STYLE_INDICATOR & __formStyle) + { + if (IsIndicatorVisible() && !IsIndicatorTranslucent()) + { + clientBounds.y += indicatorBounds.height; + clientBounds.height -= indicatorBounds.height; + } + } + } + } + } + else { if (FORM_STYLE_INDICATOR & __formStyle) { @@ -3230,7 +3260,25 @@ _Form::UpdateClientBounds(const FloatDimension& size, FloatRectangle& clientBoun if (pFrame) { FrameShowMode mode = pFrame->GetShowMode(); - if (mode == FRAME_SHOW_MODE_FULL_SCREEN) + + if (mode != FRAME_SHOW_MODE_FULL_SCREEN) + { + if (mode == FRAME_SHOW_MODE_MINIMIZED) + { + if (pFrame->GetShowMode(false) == FRAME_SHOW_MODE_FULL_SCREEN) + { + if (FORM_STYLE_INDICATOR & __formStyle) + { + if (IsIndicatorVisible() && !IsIndicatorTranslucent()) + { + clientBounds.y += indicatorBounds.height; + clientBounds.height -= indicatorBounds.height; + } + } + } + } + } + else { if (FORM_STYLE_INDICATOR & __formStyle) { diff --git a/src/ui/controls/FUiCtrl_FormImpl.cpp b/src/ui/controls/FUiCtrl_FormImpl.cpp index 4d021a3..e864d2e 100644 --- a/src/ui/controls/FUiCtrl_FormImpl.cpp +++ b/src/ui/controls/FUiCtrl_FormImpl.cpp @@ -1272,6 +1272,20 @@ _FormImpl::OnChangeLayout(_ControlOrientation orientation) if (GetCore().IsIndicatorVisible()) { indicatorBounds = GetCore().GetIndicatorBoundsF(); + if (GetCore().IsIndicatorTranslucent()) + { + if (!GetCore().IsHeaderTranslucent()) + { + indicatorBounds.height = 0.0f; + } + else + { + if (orientation == _CONTROL_ORIENTATION_LANDSCAPE) + { + indicatorBounds.height = 0.0f; + } + } + } } float posY = indicatorBounds.height + titleHeight; -- 2.7.4