Fix Rotation
authorChoi Munseok <ms47.choi@samsung.com>
Sun, 7 Apr 2013 10:18:13 +0000 (19:18 +0900)
committerChoi Munseok <ms47.choi@samsung.com>
Sun, 7 Apr 2013 10:18:13 +0000 (19:18 +0900)
Change-Id: I2392556c122e2b910b978b2eeff6f533edeb38ab
Signed-off-by: Choi Munseok <ms47.choi@samsung.com>
src/ui/FUi_EcoreEvas.cpp

index da45e59..72ba409 100644 (file)
@@ -2335,6 +2335,20 @@ _EcoreEvas::SetWindowAvailabledRotation(const _Window& window, int* rotations, u
                return;
        }
 
+       // Skip available_set if there is not change
+
+       int* prevRotations = null;
+       unsigned int prevCount = 0;
+       Eina_Bool ret = ecore_evas_wm_rotation_available_rotations_get(pLayer->GetEcoreEvas(), &prevRotations, &prevCount);
+
+       if (ret)
+       {
+               if (prevCount == count)
+               {
+                       return;
+               }
+       }
+
        Ecore_X_Window win = (Ecore_X_Window) ecore_evas_window_get(pLayer->GetEcoreEvas());
        SysLog(NID_UI, "[Window Manager Rotation][Window : 0x%x] Set window available rotation(%d).", win, count);
        ecore_evas_wm_rotation_available_rotations_set(pLayer->GetEcoreEvas(), rotations, count);