diff --git a/shell/platform/tizen/tizen_window_elementary.cc b/shell/platform/tizen/tizen_window_elementary.cc index bdd8b3c51c046..a0a7c5e18c7c4 100644 --- a/shell/platform/tizen/tizen_window_elementary.cc +++ b/shell/platform/tizen/tizen_window_elementary.cc @@ -173,7 +173,7 @@ void TizenWindowElementary::RegisterEventHandlers() { [](void* data, Evas* evas, Evas_Object* object, void* event_info) { auto* self = reinterpret_cast(data); if (self->view_delegate_) { - if (self->elm_win_ == object) { + if (self->image_ == object) { auto* mouse_event = reinterpret_cast(event_info); self->view_delegate_->OnPointerDown( @@ -184,7 +184,7 @@ void TizenWindowElementary::RegisterEventHandlers() { } }; evas_object_event_callback_add( - elm_win_, EVAS_CALLBACK_MOUSE_DOWN, + image_, EVAS_CALLBACK_MOUSE_DOWN, evas_object_callbacks_[EVAS_CALLBACK_MOUSE_DOWN], this); evas_object_callbacks_[EVAS_CALLBACK_MOUSE_UP] = [](void* data, Evas* evas, @@ -192,7 +192,7 @@ void TizenWindowElementary::RegisterEventHandlers() { void* event_info) { auto* self = reinterpret_cast(data); if (self->view_delegate_) { - if (self->elm_win_ == object) { + if (self->image_ == object) { auto* mouse_event = reinterpret_cast(event_info); self->view_delegate_->OnPointerUp( mouse_event->canvas.x, mouse_event->canvas.y, @@ -201,7 +201,7 @@ void TizenWindowElementary::RegisterEventHandlers() { } } }; - evas_object_event_callback_add(elm_win_, EVAS_CALLBACK_MOUSE_UP, + evas_object_event_callback_add(image_, EVAS_CALLBACK_MOUSE_UP, evas_object_callbacks_[EVAS_CALLBACK_MOUSE_UP], this); @@ -209,7 +209,7 @@ void TizenWindowElementary::RegisterEventHandlers() { [](void* data, Evas* evas, Evas_Object* object, void* event_info) { auto* self = reinterpret_cast(data); if (self->view_delegate_) { - if (self->elm_win_ == object) { + if (self->image_ == object) { auto* mouse_event = reinterpret_cast(event_info); self->view_delegate_->OnPointerMove( @@ -220,14 +220,14 @@ void TizenWindowElementary::RegisterEventHandlers() { } }; evas_object_event_callback_add( - elm_win_, EVAS_CALLBACK_MOUSE_MOVE, + image_, EVAS_CALLBACK_MOUSE_MOVE, evas_object_callbacks_[EVAS_CALLBACK_MOUSE_MOVE], this); evas_object_callbacks_[EVAS_CALLBACK_MOUSE_WHEEL] = [](void* data, Evas* evas, Evas_Object* object, void* event_info) { auto* self = reinterpret_cast(data); if (self->view_delegate_) { - if (self->elm_win_ == object) { + if (self->image_ == object) { auto* wheel_event = reinterpret_cast(event_info); double delta_x = 0.0; @@ -247,7 +247,7 @@ void TizenWindowElementary::RegisterEventHandlers() { } }; evas_object_event_callback_add( - elm_win_, EVAS_CALLBACK_MOUSE_WHEEL, + image_, EVAS_CALLBACK_MOUSE_WHEEL, evas_object_callbacks_[EVAS_CALLBACK_MOUSE_WHEEL], this); evas_object_callbacks_[EVAS_CALLBACK_KEY_DOWN] = [](void* data, Evas* evas, @@ -305,17 +305,18 @@ void TizenWindowElementary::UnregisterEventHandlers() { rotation_changed_callback_); evas_object_event_callback_del( - elm_win_, EVAS_CALLBACK_MOUSE_DOWN, + image_, EVAS_CALLBACK_MOUSE_DOWN, evas_object_callbacks_[EVAS_CALLBACK_MOUSE_DOWN]); evas_object_event_callback_del( - elm_win_, EVAS_CALLBACK_MOUSE_UP, + image_, EVAS_CALLBACK_MOUSE_UP, evas_object_callbacks_[EVAS_CALLBACK_MOUSE_UP]); evas_object_event_callback_del( - elm_win_, EVAS_CALLBACK_MOUSE_MOVE, + image_, EVAS_CALLBACK_MOUSE_MOVE, evas_object_callbacks_[EVAS_CALLBACK_MOUSE_MOVE]); evas_object_event_callback_del( - elm_win_, EVAS_CALLBACK_MOUSE_WHEEL, + image_, EVAS_CALLBACK_MOUSE_WHEEL, evas_object_callbacks_[EVAS_CALLBACK_MOUSE_WHEEL]); + evas_object_event_callback_del( elm_win_, EVAS_CALLBACK_KEY_DOWN, evas_object_callbacks_[EVAS_CALLBACK_KEY_DOWN]); @@ -359,7 +360,8 @@ int32_t TizenWindowElementary::GetDpi() { } uintptr_t TizenWindowElementary::GetWindowId() { - return elm_win_window_id_get(elm_win_); + return ecore_evas_window_get( + ecore_evas_ecore_evas_get(evas_object_evas_get(elm_win_))); } void TizenWindowElementary::SetPreferredOrientations(