Internal::Adaptor::SceneHolder& windowImpl = Dali::GetImplementation( childWindow );
windowImpl.SetAdaptor( Get() );
+ // ChildWindow is set to the layout direction of the default window.
+ windowImpl.GetRootLayer().SetProperty( Dali::Actor::Property::LAYOUT_DIRECTION, mRootLayoutDirection );
+
// Add the new Window to the container - the order is not important
mWindows.push_back( &windowImpl );
mSocketFactory(),
mThreadMode( threadMode ),
mEnvironmentOptionsOwned( environmentOptions ? false : true /* If not provided then we own the object */ ),
- mUseRemoteSurface( false )
+ mUseRemoteSurface( false ),
+ mRootLayoutDirection( Dali::LayoutDirection::LEFT_TO_RIGHT )
{
DALI_ASSERT_ALWAYS( !IsAvailable() && "Cannot create more than one Adaptor per thread" );
mWindows.insert( mWindows.begin(), &Dali::GetImplementation( window ) );
void Adaptor::SetRootLayoutDirection( std::string locale )
{
+ mRootLayoutDirection = static_cast< LayoutDirection::Type >( Internal::Adaptor::Locale::GetDirection( std::string( locale ) ) );
for ( auto& window : mWindows )
{
Dali::Actor root = window->GetRootLayer();
- root.SetProperty( Dali::Actor::Property::LAYOUT_DIRECTION,
- static_cast< LayoutDirection::Type >( Internal::Adaptor::Locale::GetDirection( std::string( locale ) ) ) );
+ root.SetProperty( Dali::Actor::Property::LAYOUT_DIRECTION, mRootLayoutDirection );
}
}
ThreadMode mThreadMode; ///< The thread mode
const bool mEnvironmentOptionsOwned:1; ///< Whether we own the EnvironmentOptions (and thus, need to delete it)
bool mUseRemoteSurface:1; ///< whether the remoteSurface is used or not
+ Dali::LayoutDirection::Type mRootLayoutDirection; ///< LayoutDirection of window
std::unique_ptr<Integration::AddOnManager> mAddOnManager; ///< Pointer to the addon manager