+ /// Called when the output is transformed
+ static Eina_Bool EcoreEventOutputTransform( void* data, int type, void* event )
+ {
+ Ecore_Wl_Event_Output_Transform* transformEvent( static_cast< Ecore_Wl_Event_Output_Transform* >( event ) );
+ EventHandler* handler( static_cast< EventHandler* >( data ) );
+
+ if ( handler && handler->mWindow && transformEvent->output == ecore_wl_window_output_find( handler->mEcoreWindow ) )
+ {
+ DALI_LOG_INFO( gWindowLogFilter, Debug::General, "Window (%p) EcoreEventOutputTransform\n", handler->mEcoreWindow );
+
+ ECore::WindowRenderSurface* wlSurface( dynamic_cast< ECore::WindowRenderSurface * >( handler->mWindow->mSurface ) );
+ if( wlSurface )
+ {
+ wlSurface->OutputTransformed();
+
+ PositionSize positionSize = wlSurface->GetPositionSize();
+ handler->mWindow->mAdaptor->SurfaceResizePrepare( Adaptor::SurfaceSize( positionSize.width, positionSize.height ) );
+ handler->mWindow->mAdaptor->SurfaceResizeComplete( Adaptor::SurfaceSize( positionSize.width, positionSize.height ) );
+ }
+ }
+
+ return ECORE_CALLBACK_PASS_ON;
+ }
+
+ /// Called when the output transform should be ignored
+ static Eina_Bool EcoreEventIgnoreOutputTransform( void* data, int type, void* event )
+ {
+ Ecore_Wl_Event_Ignore_Output_Transform* ignoreTransformEvent( static_cast< Ecore_Wl_Event_Ignore_Output_Transform* >( event ) );
+ EventHandler* handler( static_cast< EventHandler* >( data ) );
+
+ if ( handler && handler->mWindow && ignoreTransformEvent->win == handler->mEcoreWindow )
+ {
+ DALI_LOG_INFO( gWindowLogFilter, Debug::General, "Window (%p) EcoreEventIgnoreOutputTransform\n", handler->mEcoreWindow );
+
+ ECore::WindowRenderSurface* wlSurface( dynamic_cast< ECore::WindowRenderSurface * >( handler->mWindow->mSurface ) );
+ if( wlSurface )
+ {
+ wlSurface->OutputTransformed();
+
+ PositionSize positionSize = wlSurface->GetPositionSize();
+ handler->mWindow->mAdaptor->SurfaceResizePrepare( Adaptor::SurfaceSize( positionSize.width, positionSize.height ) );
+ handler->mWindow->mAdaptor->SurfaceResizeComplete( Adaptor::SurfaceSize( positionSize.width, positionSize.height ) );
+ }
+ }
+
+ return ECORE_CALLBACK_PASS_ON;
+ }
+