ecore_evas_wayland: Make rotation_set common
authorDerek Foreman <derekf@osg.samsung.com>
Tue, 1 Nov 2016 22:16:07 +0000 (17:16 -0500)
committerDerek Foreman <derekf@osg.samsung.com>
Wed, 2 Nov 2016 18:37:01 +0000 (13:37 -0500)
Rotation set can be moved into common now - should be no functional
change.

src/modules/ecore_evas/engines/wayland/ecore_evas_wayland_common.c
src/modules/ecore_evas/engines/wayland/ecore_evas_wayland_egl.c
src/modules/ecore_evas/engines/wayland/ecore_evas_wayland_shm.c

index 63a3cd3..80b1ff9 100644 (file)
@@ -397,19 +397,6 @@ _rotation_do(Ecore_Evas *ee, int rotation, int resize)
      }
 }
 
-void
-_ecore_evas_wl_common_rotation_set(Ecore_Evas *ee, int rotation, int resize)
-{
-   if (ee->in_async_render)
-     {
-        ee->delayed.rotation = rotation;
-        ee->delayed.rotation_resize = resize;
-        ee->delayed.rotation_changed = EINA_TRUE;
-        return;
-     }
-   _rotation_do(ee, rotation, resize);
-}
-
 static Eina_Bool
 _ecore_evas_wl_common_cb_www_drag(void *d EINA_UNUSED, int t EINA_UNUSED, void *event)
 {
@@ -2066,3 +2053,30 @@ _ecore_evas_wl_common_transparent_set(Ecore_Evas *ee, int transparent)
 
    _ecore_evas_wayland_transparent_do(ee, transparent);
 }
+
+void
+_ecore_evas_wl_common_rotation_set(Ecore_Evas *ee, int rotation, int resize)
+{
+   Evas_Engine_Info_Wayland *einfo;
+
+   LOGFN(__FILE__, __LINE__, __FUNCTION__);
+
+   if (ee->rotation == rotation) return;
+
+   if (ee->in_async_render)
+     {
+        ee->delayed.rotation = rotation;
+        ee->delayed.rotation_resize = resize;
+        ee->delayed.rotation_changed = EINA_TRUE;
+     }
+   else
+     _rotation_do(ee, rotation, resize);
+
+   einfo = (Evas_Engine_Info_Wayland *)evas_engine_info_get(ee->evas);
+   if (!einfo) return;
+
+   einfo->info.rotation = rotation;
+
+   if (!evas_engine_info_set(ee->evas, (Evas_Engine_Info *)einfo))
+     ERR("evas_engine_info_set() for engine '%s' failed.", ee->driver);
+}
index 56799c6..366c7d2 100644 (file)
@@ -33,9 +33,6 @@
 extern EAPI Eina_List *_evas_canvas_image_data_unset(Evas *eo_e);
 extern EAPI void _evas_canvas_image_data_regenerate(Eina_List *list);
 
-/* local function prototypes */
-static void _ecore_evas_wl_rotation_set(Ecore_Evas *ee, int rotation, int resize);
-
 static Ecore_Evas_Engine_Func _ecore_wl_engine_func = 
 {
    _ecore_evas_wl_common_free,
@@ -57,7 +54,7 @@ static Ecore_Evas_Engine_Func _ecore_wl_engine_func =
    NULL, // managed_move
    _ecore_evas_wl_common_resize,
    _ecore_evas_wl_common_move_resize,
-   _ecore_evas_wl_rotation_set,
+   _ecore_evas_wl_common_rotation_set,
    NULL, // shaped_set
    _ecore_evas_wl_common_show,
    _ecore_evas_wl_common_hide,
@@ -445,26 +442,6 @@ conn_err:
    return NULL;
 }
 
-static void
-_ecore_evas_wl_rotation_set(Ecore_Evas *ee, int rotation, int resize)
-{
-   Evas_Engine_Info_Wayland *einfo;
-
-   LOGFN(__FILE__, __LINE__, __FUNCTION__);
-
-   if (ee->rotation == rotation) return;
-
-   _ecore_evas_wl_common_rotation_set(ee, rotation, resize);
-
-   einfo = (Evas_Engine_Info_Wayland *)evas_engine_info_get(ee->evas);
-   if (!einfo) return;
-
-   einfo->info.rotation = rotation;
-
-   if (!evas_engine_info_set(ee->evas, (Evas_Engine_Info *)einfo))
-     ERR("evas_engine_info_set() for engine '%s' failed.", ee->driver);
-}
-
 void 
 _ecore_evas_wayland_egl_resize(Ecore_Evas *ee, int location)
 {
index cc9b6b1..662912a 100644 (file)
@@ -30,9 +30,6 @@
 # endif
 #endif /* ! _WIN32 */
 
-/* local function prototypes */
-static void _ecore_evas_wl_rotation_set(Ecore_Evas *ee, int rotation, int resize);
-
 static Ecore_Evas_Engine_Func _ecore_wl_engine_func = 
 {
    _ecore_evas_wl_common_free,
@@ -54,7 +51,7 @@ static Ecore_Evas_Engine_Func _ecore_wl_engine_func =
    NULL, // managed_move
    _ecore_evas_wl_common_resize,
    _ecore_evas_wl_common_move_resize,
-   _ecore_evas_wl_rotation_set,
+   _ecore_evas_wl_common_rotation_set,
    NULL, // shaped_set
    _ecore_evas_wl_common_show,
    _ecore_evas_wl_common_hide,
@@ -374,26 +371,6 @@ conn_err:
    return NULL;
 }
 
-static void
-_ecore_evas_wl_rotation_set(Ecore_Evas *ee, int rotation, int resize)
-{
-   Evas_Engine_Info_Wayland *einfo;
-
-   LOGFN(__FILE__, __LINE__, __FUNCTION__);
-
-   if (ee->rotation == rotation) return;
-
-   _ecore_evas_wl_common_rotation_set(ee, rotation, resize);
-
-   einfo = (Evas_Engine_Info_Wayland *)evas_engine_info_get(ee->evas);
-   if (!einfo) return;
-
-   einfo->info.rotation = rotation;
-
-   if (!evas_engine_info_set(ee->evas, (Evas_Engine_Info *)einfo))
-     ERR("evas_engine_info_set() for engine '%s' failed.", ee->driver);
-}
-
 void 
 _ecore_evas_wayland_shm_resize(Ecore_Evas *ee, int location)
 {