X-Git-Url: http://review.tizen.org/git/?a=blobdiff_plain;f=dali%2Fintegration-api%2Fadaptor-framework%2Fscene-holder-impl.cpp;h=7aa6f29102ef028cd82b3fc462525db582206e02;hb=6639efb20527a94f0cb5e2660dbb8585c95b07d2;hp=aa033eb8f404da225602022b30ef9cf90476f597;hpb=80fee0d2416ad1f3bf0b0e28ee7c90124610ec3e;p=platform%2Fcore%2Fuifw%2Fdali-adaptor.git diff --git a/dali/integration-api/adaptor-framework/scene-holder-impl.cpp b/dali/integration-api/adaptor-framework/scene-holder-impl.cpp index aa033eb..7aa6f29 100644 --- a/dali/integration-api/adaptor-framework/scene-holder-impl.cpp +++ b/dali/integration-api/adaptor-framework/scene-holder-impl.cpp @@ -1,5 +1,5 @@ /* - * Copyright (c) 2021 Samsung Electronics Co., Ltd. + * Copyright (c) 2022 Samsung Electronics Co., Ltd. * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. @@ -122,6 +122,11 @@ Dali::Layer SceneHolder::GetRootLayer() const return mScene ? mScene.GetRootLayer() : Dali::Layer(); } +Dali::Layer SceneHolder::GetOverlayLayer() +{ + return mScene ? mScene.GetOverlayLayer() : Dali::Layer(); +} + uint32_t SceneHolder::GetId() const { return mId; @@ -212,10 +217,10 @@ void SceneHolder::SetAdaptor(Dali::Adaptor& adaptor) // Create the scene PositionSize surfacePositionSize = mSurface->GetPositionSize(); - int windowOrientation = mSurface->GetSurfaceOrientation(); - int screenOrientation = mSurface->GetScreenOrientation(); + int windowOrientation = mSurface->GetSurfaceOrientation(); + int screenOrientation = mSurface->GetScreenOrientation(); - mScene = Dali::Integration::Scene::New(Size(static_cast(surfacePositionSize.width), static_cast(surfacePositionSize.height)), windowOrientation, screenOrientation); + mScene = Dali::Integration::Scene::New(Size(static_cast(surfacePositionSize.width), static_cast(surfacePositionSize.height)), windowOrientation, screenOrientation); Internal::Adaptor::Adaptor& adaptorImpl = Internal::Adaptor::Adaptor::GetImplementation(adaptor); mAdaptor = &adaptorImpl; @@ -276,7 +281,8 @@ void SceneHolder::FeedTouchPoint(Dali::Integration::Point& point, int timeStamp) timeStamp = TimeService::GetMilliSeconds(); } - RecalculateTouchPosition(point); + Vector2 convertedPosition = RecalculatePosition(point.GetScreenPosition()); + point.SetScreenPosition(convertedPosition); Integration::TouchEvent touchEvent; Integration::HoverEvent hoverEvent; @@ -311,6 +317,9 @@ void SceneHolder::FeedWheelEvent(Dali::Integration::WheelEvent& wheelEvent) // Keep the handle alive until the core events are processed. Dali::BaseHandle sceneHolder(this); + Vector2 convertedPosition = RecalculatePosition(wheelEvent.point); + wheelEvent.point = convertedPosition; + mScene.QueueEvent(wheelEvent); mAdaptor->ProcessCoreEvents(); }