From: Daekwang Ryu Date: Tue, 21 Jul 2020 06:14:58 +0000 (+0900) Subject: [Tizen] Fix screen rotation bug when application is initialized X-Git-Tag: accepted/tizen/unified/20200722.014914~2 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=72395a9162b5c8295a6eae39b8be892ced6d4912;p=platform%2Fcore%2Fuifw%2Fdali-adaptor.git [Tizen] Fix screen rotation bug when application is initialized This reverts commit 5e597a09d30d8d82b6dd56c219d58cd0511c9fa8. Change-Id: I82935fc4af6ada3338792dc543169338b7f58797 --- diff --git a/dali/internal/window-system/common/window-impl.cpp b/dali/internal/window-system/common/window-impl.cpp index dbf04f4..1664ed3 100755 --- a/dali/internal/window-system/common/window-impl.cpp +++ b/dali/internal/window-system/common/window-impl.cpp @@ -807,6 +807,7 @@ void Window::OnOutputTransformed() { forceUpdate = true; } + DALI_LOG_RELEASE_INFO( "Window (%p), WinId (%d), OnOutputTransformed()\n", this, mNativeWindowId ); SurfaceResized( forceUpdate ); PositionSize positionSize = mSurface->GetPositionSize(); diff --git a/dali/internal/window-system/common/window-render-surface.cpp b/dali/internal/window-system/common/window-render-surface.cpp index 7e5808c..4db576f 100644 --- a/dali/internal/window-system/common/window-render-surface.cpp +++ b/dali/internal/window-system/common/window-render-surface.cpp @@ -106,14 +106,6 @@ void WindowRenderSurface::Initialize( Any surface ) // Connect signals mWindowBase->OutputTransformedSignal().Connect( this, &WindowRenderSurface::OutputTransformed ); - - // Check screen rotation - mScreenRotationAngle = mWindowBase->GetScreenRotationAngle(); - if( mScreenRotationAngle != 0 ) - { - mScreenRotationFinished = false; - mResizeFinished = false; - } } Any WindowRenderSurface::GetNativeWindow() @@ -224,20 +216,8 @@ void WindowRenderSurface::CreateSurface() { DALI_LOG_TRACE_METHOD( gWindowRenderSurfaceLogFilter ); - int width, height; - if( mScreenRotationAngle == 0 || mScreenRotationAngle == 180 ) - { - width = mPositionSize.width; - height = mPositionSize.height; - } - else - { - width = mPositionSize.height; - height = mPositionSize.width; - } - // Create the EGL window - EGLNativeWindowType window = mWindowBase->CreateEglWindow( width, height ); + EGLNativeWindowType window = mWindowBase->CreateEglWindow( mPositionSize.width, mPositionSize.height ); auto eglGraphics = static_cast(mGraphics); @@ -578,11 +558,11 @@ void WindowRenderSurface::OutputTransformed() mOutputTransformedSignal.Emit(); - DALI_LOG_INFO( gWindowRenderSurfaceLogFilter, Debug::Verbose, "WindowRenderSurface::OutputTransformed: angle = %d screen rotation = %d\n", mRotationAngle, mScreenRotationAngle ); + DALI_LOG_RELEASE_INFO( "WindowRenderSurface::OutputTransformed: window = %d screen = %d\n", mRotationAngle, mScreenRotationAngle ); } else { - DALI_LOG_INFO( gWindowRenderSurfaceLogFilter, Debug::Verbose, "WindowRenderSurface::OutputTransformed: Ignore output transform [%d]\n", mScreenRotationAngle ); + DALI_LOG_RELEASE_INFO( "WindowRenderSurface::OutputTransformed: Ignore output transform [%d]\n", mScreenRotationAngle ); } }