if (pLayer->GetEvas() && pLayer->GetEcoreEvas() && pEvent->win == ecore_evas_window_get(pLayer->GetEcoreEvas()))
{
- int w, h;
+ int w, h, rw, rh;
FloatRectangle bounds = pLayer->GetBounds();
+ int orientation = ecore_evas_rotation_get(pLayer->GetEcoreEvas());
+ Ecore_X_Window win = (Ecore_X_Window) ecore_evas_window_get(pLayer->GetEcoreEvas());
+ Eina_Bool ret = ecore_x_e_window_rotation_geometry_get(win, orientation, null, null, &rw, &rh);
+
evas_output_size_get(pLayer->GetEvas(), &w, &h);
- pLayer->SetConfigured(true);
- //if (w == (int)bounds.width && h == (int)bounds.height)
+ if ( ((orientation % 180) == 0 && pEvent->w == (int)bounds.width && pEvent->h == (int)bounds.height)
+ || ((orientation % 180) == 90 && pEvent->h == (int)bounds.width && pEvent->w == (int)bounds.height)
+ || (ret && rw == pEvent->w && rh == pEvent->h)
+ )
{
+ pLayer->SetConfigured(true);
evas_damage_rectangle_add(pLayer->GetEvas(), 0, 0, w, h);
_DisplayManager* pDisplayManager = _DisplayManager::GetInstance();
if (pDisplayManager)
_isConfigured = true;
}
PRINT("[%#x | %#x] Called SetOrientationChanged(%d->%d) \n", (unsigned int)this, ecore_evas_window_get(_pEcoreEvas), __orientation, orientation);
+
+ if (__orientation % 180 != orientation % 180)
+ {
+ float temp = __bounds.width;
+ __bounds.width = __bounds.height;
+ __bounds.height = temp;
+ }
+
__orientation = orientation;
return E_SUCCESS;
}
evas_object_move(_pWindow, bounds.x, bounds.y);
PRINT("[%#x | %#x] evas_object_move(%f, %f) \n", (unsigned int)this, ecore_evas_window_get(_pEcoreEvas), bounds.x, bounds.y);
- //int w, h;
- //evas_output_size_get(_pEvas, &w, &h);
if ((__bounds.width != bounds.width) || (__bounds.height != bounds.height))
{
- //_isConfigured = false;
+ _isConfigured = false;
evas_object_resize(_pWindow, bounds.width, bounds.height);
PRINT("[%#x | %#x] evas_object_resize(%f, %f) \n", (unsigned int)this, ecore_evas_window_get(_pEcoreEvas), bounds.width, bounds.height);
}