/*
- * Copyright (c) 2014 Samsung Electronics Co., Ltd.
+ * Copyright (c) 2017 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.
namespace
{
+#if defined(EMSCRIPTEN)
+ThreadLocalStorage* threadLocal = NULL;
+#else
__thread ThreadLocalStorage* threadLocal = NULL;
+#endif
}
ThreadLocalStorage::ThreadLocalStorage(Core* core)
-: mCore(core)
+: mCore( core )
{
DALI_ASSERT_ALWAYS( threadLocal == NULL && "Cannot create more than one ThreadLocalStorage object" );
- // reset is used to store a new value associated with this thread
threadLocal = this;
}
return mCore->GetResourceClient();
}
-ImageFactory& ThreadLocalStorage::GetImageFactory()
-{
- return mCore->GetImageFactory();
-}
-
-ModelFactory& ThreadLocalStorage::GetModelFactory()
-{
- return mCore->GetModelFactory();
-}
-
-FontFactory& ThreadLocalStorage::GetFontFactory()
-{
- return mCore->GetFontFactory();
-}
-
ShaderFactory& ThreadLocalStorage::GetShaderFactory()
{
return mCore->GetShaderFactory();
return mCore->GetCurrentStage();
}
-EventToUpdate& ThreadLocalStorage::GetEventToUpdate()
-{
- return GetUpdateManager().GetEventToUpdate();
-}
-
GestureEventProcessor& ThreadLocalStorage::GetGestureEventProcessor()
{
return mCore->GetGestureEventProcessor();
}
-EmojiFactory& ThreadLocalStorage::GetEmojiFactory()
+RelayoutController& ThreadLocalStorage::GetRelayoutController()
{
- return mCore->GetEmojiFactory();
+ return mCore->GetRelayoutController();
}
} // namespace Internal