X-Git-Url: http://review.tizen.org/git/?a=blobdiff_plain;f=dali%2Finternal%2Fwindow-system%2Ftizen-wayland%2Fecore-wl2%2Fwindow-base-ecore-wl2.cpp;h=de1c76ddae8201933af25b6508f08f2a19a469e4;hb=refs%2Fheads%2Faccepted%2Ftizen_5.5_unified_mobile_hotfix;hp=1eee7a8da0b82086da0f50a311b1d616d34a009e;hpb=72c86ab9cedd7d397acca026e1e6b7e659c2a595;p=platform%2Fcore%2Fuifw%2Fdali-adaptor.git diff --git a/dali/internal/window-system/tizen-wayland/ecore-wl2/window-base-ecore-wl2.cpp b/dali/internal/window-system/tizen-wayland/ecore-wl2/window-base-ecore-wl2.cpp index 1eee7a8..de1c76d 100755 --- a/dali/internal/window-system/tizen-wayland/ecore-wl2/window-base-ecore-wl2.cpp +++ b/dali/internal/window-system/tizen-wayland/ecore-wl2/window-base-ecore-wl2.cpp @@ -432,6 +432,46 @@ static Eina_Bool EcoreEventDataReceive( void* data, int type, void* event ) } ///////////////////////////////////////////////////////////////////////////////////////////////// +// Effect Start/End Callbacks +///////////////////////////////////////////////////////////////////////////////////////////////// + +/** + * Called when transition animation of the window's shown/hidden is started by window manager. + */ +static Eina_Bool EcoreEventEffectStart(void *data, int type, void *event) +{ + WindowBaseEcoreWl2* windowBase = static_cast< WindowBaseEcoreWl2* >( data ); + Ecore_Wl2_Event_Effect_Start *effectStart = static_cast( event ); + DALI_LOG_INFO( gWindowBaseLogFilter, Debug::General, "WindowBaseEcoreWl2::EcoreEventEffectStart, effect type[ %d ]\n", effectStart->type ); + if( windowBase ) + { + if( effectStart->type < 3 ) // only under restack + { + windowBase->OnTransitionEffectEvent( DevelWindow::EffectState::START, static_cast( effectStart->type ) ); + } + } + return ECORE_CALLBACK_PASS_ON; +} + +/** + * Called when transition animation of the window's shown/hidden is ended by window manager. + */ +static Eina_Bool EcoreEventEffectEnd(void *data, int type, void *event) +{ + Ecore_Wl2_Event_Effect_Start *effectEnd = static_cast( event ); + WindowBaseEcoreWl2* windowBase = static_cast< WindowBaseEcoreWl2* >( data ); + DALI_LOG_INFO( gWindowBaseLogFilter, Debug::General, "WindowBaseEcoreWl2::EcoreEventEffectEnd, effect type[ %d ]\n", effectEnd->type ); + if( windowBase ) + { + if( effectEnd->type < 3 ) // only under restack + { + windowBase->OnTransitionEffectEvent( DevelWindow::EffectState::END, static_cast( effectEnd->type ) ); + } + } + return ECORE_CALLBACK_PASS_ON; +} + +///////////////////////////////////////////////////////////////////////////////////////////////// // Font Callbacks ///////////////////////////////////////////////////////////////////////////////////////////////// @@ -707,6 +747,10 @@ void WindowBaseEcoreWl2::Initialize( PositionSize positionSize, Any surface, boo mEcoreEventHandler.PushBack( ecore_event_handler_add( ECORE_WL2_EVENT_DATA_SOURCE_SEND, EcoreEventDataSend, this ) ); mEcoreEventHandler.PushBack( ecore_event_handler_add( ECORE_WL2_EVENT_SELECTION_DATA_READY, EcoreEventDataReceive, this ) ); + // Register Effect Start/End event + mEcoreEventHandler.PushBack( ecore_event_handler_add( ECORE_WL2_EVENT_EFFECT_START, EcoreEventEffectStart, this ) ); + mEcoreEventHandler.PushBack( ecore_event_handler_add( ECORE_WL2_EVENT_EFFECT_END, EcoreEventEffectEnd, this ) ); + // Register Vconf notify - font name and size vconf_notify_key_changed( DALI_VCONFKEY_SETAPPL_ACCESSIBILITY_FONT_NAME, VconfNotifyFontNameChanged, this ); vconf_notify_key_changed( VCONFKEY_SETAPPL_ACCESSIBILITY_FONT_SIZE, VconfNotifyFontSizeChanged, this ); @@ -1147,6 +1191,11 @@ void WindowBaseEcoreWl2::OnEcoreElDBusAccessibilityNotification( void* context, #endif } +void WindowBaseEcoreWl2::OnTransitionEffectEvent( DevelWindow::EffectState state, DevelWindow::EffectType type ) +{ + mTransitionEffectEventSignal.Emit( state, type ); +} + void WindowBaseEcoreWl2::RegistryGlobalCallback( void* data, struct wl_registry *registry, uint32_t name, const char* interface, uint32_t version ) { if( strcmp( interface, tizen_policy_interface.name ) == 0 ) @@ -1251,7 +1300,7 @@ void WindowBaseEcoreWl2::SetEglWindowRotation( int angle ) } case 90: { - rotation = WL_EGL_WINDOW_TIZEN_ROTATION_90; + rotation = WL_EGL_WINDOW_TIZEN_ROTATION_270; break; } case 180: