/*
- * Copyright (c) 2019 Samsung Electronics Co., Ltd.
+ * Copyright (c) 2020 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.
mId( mSceneHolderCounter++ ),
mSurface( nullptr ),
mAdaptor( nullptr ),
+ mIsBeingDeleted( false ),
mAdaptorStarted( false ),
mVisible( true )
{
{
mSurface.reset( surface );
- mScene.SetSurface( *mSurface.get() );
+ mScene.SurfaceReplaced();
+
+ SurfaceResized();
unsigned int dpiHorizontal, dpiVertical;
dpiHorizontal = dpiVertical = 0;
void SceneHolder::SurfaceResized()
{
- mScene.SurfaceResized();
+ PositionSize surfacePositionSize = mSurface->GetPositionSize();
+ mScene.SurfaceResized( static_cast<float>( surfacePositionSize.width ), static_cast<float>( surfacePositionSize.height ) );
}
Dali::RenderSurfaceInterface* SceneHolder::GetSurface() const
mAdaptorStarted = true;
// Create the scene
- mScene = Dali::Integration::Scene::New( *mSurface );
+ PositionSize surfacePositionSize = mSurface->GetPositionSize();
+ mScene = Dali::Integration::Scene::New( Size(static_cast<float>( surfacePositionSize.width ), static_cast<float>( surfacePositionSize.height )) );
Internal::Adaptor::Adaptor& adaptorImpl = Internal::Adaptor::Adaptor::GetImplementation( adaptor );
mAdaptor = &adaptorImpl;