GlobalLogic moved to api_new
authorTomasz Iwanek <t.iwanek@samsung.com>
Tue, 27 Nov 2012 13:39:46 +0000 (14:39 +0100)
committerGerrit Code Review <gerrit2@kim11>
Thu, 13 Dec 2012 14:59:00 +0000 (23:59 +0900)
[Issue#]       LINUXNGWAP-561
[Bug]          Global logic should be moved to core module
[Cause]        N/A
[Solution]     N/A
[Verification] Install and run any widget.

Signed-off-by: Iwanek Tomasz <t.iwanek@samsung.com>
Change-Id: I610c9975c449dea96185697372e60b00202e956f

17 files changed:
src/CMakeLists.txt
src/api_new/CMakeLists.txt
src/api_new/core_module.cpp
src/api_new/core_module.h
src/api_new/runnable_widget_object.cpp
src/api_new/runnable_widget_object.h
src/domain/common_error.h [deleted file]
src/domain/global_context.cpp [deleted file]
src/domain/global_context.h [deleted file]
src/global_logic/global_logic.cpp [deleted file]
src/global_logic/global_logic.h [deleted file]
src/global_logic/global_model.cpp [deleted file]
src/global_logic/global_model.h [deleted file]
src/utils/DESCRIPTION [deleted file]
src/utils/FreeLogic.h [deleted file]
src/view/webkit/CMakeLists.txt
src/wrt-client/wrt-client.cpp

index c72db16..29f071b 100644 (file)
@@ -27,7 +27,6 @@ SET(WRT_SRC_DIR
    )
 
 SET(WRT_CORE_BASE_SOURCES
-    ${WRT_SRC_DIR}/domain/global_context.cpp
     ${WRT_SRC_DIR}/domain/widget_data_types.cpp
     ${WRT_SRC_DIR}/domain/widget_deserialize_model.cpp
     ${WRT_SRC_DIR}/domain/localization_setting.cpp
@@ -37,16 +36,9 @@ SET(WRT_CORE_BASE_SOURCES
 
 SET(WRT_CORE_INCLUDES
     ${WRT_SRC_DIR}/plugin-service
-    ${WRT_SRC_DIR}/common
-    ${WRT_SRC_DIR}/utils
-    ${WRT_SRC_DIR}/orm
-    ${WRT_SRC_DIR}/configuration
     ${WRT_SRC_DIR}/domain
-    ${WRT_SRC_DIR}/localization
     ${WRT_SRC_DIR}/profiling
-    ${WRT_SRC_DIR}/global_logic
-    ${WRT_SRC_DIR}/ui
-    ${WRT_SRC_DIR}/smack
+    ${WRT_SRC_DIR}/popup-process
     ${WRT_SRC_DIR}/view
     )
 
index 603d8c0..2aa2a27 100644 (file)
@@ -28,6 +28,7 @@ PKG_CHECK_MODULES(CORE_MODULE_DEP
     wrt-plugin-js-overlay
     dpl-efl
     security-wrt-ocsp
+    wrt-popup-wrt-runner
     REQUIRED
 )
 
index 346006c..f678720 100644 (file)
@@ -25,7 +25,6 @@
 #include "runnable_widget_object.h"
 #include <string>
 #include <main_thread.h>
-#include <global_context.h>
 #include <dpl/log/log.h>
 #include <dpl/assert.h>
 #include <dpl/exception.h>
 #include <profiling_util.h>
 #include <widget_deserialize_model.h>
 #include <dpl/wrt-dao-ro/widget_dao_read_only.h>
+#include <dpl/wrt-dao-ro/global_dao_read_only.h>
 
 #include <EWebKit2.h>
 
+
 IMPLEMENT_SINGLETON(WRT::CoreModule)
 
 namespace { //Anonymous
@@ -138,8 +139,6 @@ public:
                                                EWK_COOKIE_JAR_ACCEPT_ALWAYS);
                 ADD_PROFILING_POINT("WebProcess fork", "stop");
 
-                GlobalContext::TouchArchitecture();
-
                 ADD_PROFILING_POINT("attach databases", "start");
                 MainThreadSingleton::Instance().AttachDatabases();
                 ADD_PROFILING_POINT("attach databases", "stop");
@@ -187,6 +186,43 @@ public:
         }
     }
 
+    CoreModule::NetworkAccessMode homeNetworkAccess()
+    {
+        switch (WrtDB::GlobalDAOReadOnly::GetHomeNetworkDataUsage()) {
+        case WrtDB::GlobalDAOReadOnly::NEVER_CONNECT:
+            return CoreModule::NEVER_CONNECT;
+        case WrtDB::GlobalDAOReadOnly::ALWAYS_ASK:
+            return CoreModule::ALWAYS_ASK;
+        case WrtDB::GlobalDAOReadOnly::CONNECT_AUTOMATICALLY:
+            return CoreModule::CONNECT_AUTOMATICALLY;
+        default:
+            break;
+        }
+        LogWarning("using default value");
+        return CoreModule::ALWAYS_ASK;
+    }
+
+    CoreModule::NetworkAccessMode roamingNetworkAccess()
+    {
+        switch (WrtDB::GlobalDAOReadOnly::GetRoamingDataUsage()) {
+        case WrtDB::GlobalDAOReadOnly::NEVER_CONNECT:
+            return CoreModule::NEVER_CONNECT;
+        case WrtDB::GlobalDAOReadOnly::ALWAYS_ASK:
+            return CoreModule::ALWAYS_ASK;
+        case WrtDB::GlobalDAOReadOnly::CONNECT_AUTOMATICALLY:
+            return CoreModule::CONNECT_AUTOMATICALLY;
+        default:
+            break;
+        }
+        LogWarning("using default value");
+        return CoreModule::ALWAYS_ASK;
+    }
+
+    bool developerMode()
+    {
+        return WrtDB::GlobalDAOReadOnly::GetDeveloperMode();
+    }
+
 private:
     bool m_initialized;
     Ewk_Context* m_ewkContext;
@@ -216,4 +252,19 @@ RunnableWidgetObjectPtr CoreModule::getRunnableWidgetObject(
     return m_impl->getRunnableWidgetObject(tizenId);
 }
 
+CoreModule::NetworkAccessMode CoreModule::homeNetworkAccess()
+{
+    return m_impl->homeNetworkAccess();
+}
+
+CoreModule::NetworkAccessMode CoreModule::roamingNetworkAccess()
+{
+    return m_impl->roamingNetworkAccess();
+}
+
+bool CoreModule::developerMode()
+{
+    return m_impl->developerMode();
+}
+
 } /* namespace WRT */
index fae27a9..85d9802 100644 (file)
@@ -37,6 +37,16 @@ class CoreModule
 {
   public:
     /**
+     * Network access mode enum.
+     */
+    enum NetworkAccessMode
+    {
+        NEVER_CONNECT,
+        ALWAYS_ASK,
+        CONNECT_AUTOMATICALLY
+    };
+
+    /**
      * Initialize needed by WRT components (database etc).
      * Will not throw exception. elm_init() is NOT called in this function.
      * You MUST call it before running widget.
@@ -57,6 +67,22 @@ class CoreModule
      */
     RunnableWidgetObjectPtr getRunnableWidgetObject(
             const std::string& tizenId);
+    /**
+     * Gets from database global property of homeNetworkAccess
+     * @return homeNetworkAccess value
+     */
+    NetworkAccessMode homeNetworkAccess();
+    /**
+     * Gets from database global property of roamingNetworkAccess
+     * @return roamingNetworkAccess value
+     */
+    NetworkAccessMode roamingNetworkAccess();
+    /**
+     * Returns actual value of developer mode.
+     * @return is developer mode on
+     */
+    bool developerMode();
+
   private:
     CoreModule();
     ~CoreModule();
index dedf7e5..088274d 100644 (file)
@@ -23,7 +23,6 @@
 #include <runnable_widget_object.h>
 #include <privilege-control.h>
 #include <dpl/wrt-dao-ro/global_config.h>
-#include "global_logic.h"
 #include <dpl/utils/wrt_global_settings.h>
 #include <appcore-common.h>
 #include <profiling_util.h>
@@ -46,7 +45,6 @@ const unsigned int UID_ROOT = 0;
 
 } // namespace anonymous
 
-
 namespace WRT {
 
 RunnableWidgetObject::RunnableWidgetObject(WidgetModelPtr &model, Ewk_Context* context) :
index e35952f..49f028e 100644 (file)
@@ -34,7 +34,6 @@ class StateChange;
 #include <string>
 #include <memory>
 
-#include <common_error.h>
 #include <widget_model.h>
 #include <i_view_module.h>
 #include "i_runnable_widget_object.h"
diff --git a/src/domain/common_error.h b/src/domain/common_error.h
deleted file mode 100644 (file)
index 586a337..0000000
+++ /dev/null
@@ -1,46 +0,0 @@
-/*
- * Copyright (c) 2011 Samsung Electronics Co., Ltd All Rights Reserved
- *
- *    Licensed under the Apache License, Version 2.0 (the "License");
- *    you may not use this file except in compliance with the License.
- *    You may obtain a copy of the License at
- *
- *        http://www.apache.org/licenses/LICENSE-2.0
- *
- *    Unless required by applicable law or agreed to in writing, software
- *    distributed under the License is distributed on an "AS IS" BASIS,
- *    WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- *    See the License for the specific language governing permissions and
- *    limitations under the License.
- */
-/**
- * @file    common_error.h
- * @author  Przemyslaw Dobrowolski (p.dobrowolsk@samsung.com)
- * @version 1.0
- * @brief   Header file for common error definitions
- */
-#ifndef COMMON_ERROR_H
-#define COMMON_ERROR_H
-
-namespace CommonError {
-enum Type
-{
-    WrtSuccess,                ///< Success
-
-    HandleNotFound,         ///< Widget handle was not found
-    AlreadyRunning,         ///< Widget is already running
-    AlreadyStopped,         ///< Widget is already stopped
-    InvalidLanguage,        ///< Widget is invalid in current locales
-    StillAuthorizing,       ///< Widget is still autorizing and has not yet finished it
-    EarlyKilled,            ///< Widget was early killed during launch
-    AccessDenied,           ///< Access denied from ACE
-    CertificateRevoked,     ///< Some certificate was revoked.
-                            ///  Widget is not allowed to run.
-    DatabaseFailure,        ///< Wrong database version
-    NoPath,                 ///< Required path does not exist
-
-    Unknown                 ///< Temporary error. Try to not use this.
-};
-}
-
-#endif // COMMON_ERROR_H
diff --git a/src/domain/global_context.cpp b/src/domain/global_context.cpp
deleted file mode 100644 (file)
index 27ffc00..0000000
+++ /dev/null
@@ -1,34 +0,0 @@
-/*
- * Copyright (c) 2011 Samsung Electronics Co., Ltd All Rights Reserved
- *
- *    Licensed under the Apache License, Version 2.0 (the "License");
- *    you may not use this file except in compliance with the License.
- *    You may obtain a copy of the License at
- *
- *        http://www.apache.org/licenses/LICENSE-2.0
- *
- *    Unless required by applicable law or agreed to in writing, software
- *    distributed under the License is distributed on an "AS IS" BASIS,
- *    WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- *    See the License for the specific language governing permissions and
- *    limitations under the License.
- */
-/**
- * @file    global_context.cpp
- * @author  Przemyslaw Dobrowolski (p.dobrowolsk@samsung.com)
- * @version 1.0
- * @brief   Implementation file for global context
- */
-#include <global_context.h>
-#include <global_logic.h>
-
-namespace GlobalContext {
-
-void TouchArchitecture()
-{
-    // Touch all WebRuntime controllers
-    // Remember to always add here new singletons!
-    GlobalLogicSingleton::Instance().GetGlobalModel();
-    // Start UI process rpc server
-}
-} // namespace GlobalContext
diff --git a/src/domain/global_context.h b/src/domain/global_context.h
deleted file mode 100644 (file)
index 547ba72..0000000
+++ /dev/null
@@ -1,37 +0,0 @@
-/*
- * Copyright (c) 2011 Samsung Electronics Co., Ltd All Rights Reserved
- *
- *    Licensed under the Apache License, Version 2.0 (the "License");
- *    you may not use this file except in compliance with the License.
- *    You may obtain a copy of the License at
- *
- *        http://www.apache.org/licenses/LICENSE-2.0
- *
- *    Unless required by applicable law or agreed to in writing, software
- *    distributed under the License is distributed on an "AS IS" BASIS,
- *    WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- *    See the License for the specific language governing permissions and
- *    limitations under the License.
- */
-/**
- * @file    global_context.h
- * @author  Przemyslaw Dobrowolski (p.dobrowolsk@samsung.com)
- * @version 1.0
- * @brief   Header file for global contect
- */
-#ifndef GLOBAL_CONTEXT_H
-#define GLOBAL_CONTEXT_H
-
-namespace GlobalContext {
-
-void Initialize();
-
-void Finalize();
-
-/**
- * Touch all singletons to inherit default context
- */
-void TouchArchitecture();
-} // namespace GlobalContext
-
-#endif // GLOBAL_CONTEXT_H
diff --git a/src/global_logic/global_logic.cpp b/src/global_logic/global_logic.cpp
deleted file mode 100644 (file)
index e5dd879..0000000
+++ /dev/null
@@ -1,41 +0,0 @@
-/*
- * Copyright (c) 2011 Samsung Electronics Co., Ltd All Rights Reserved
- *
- *    Licensed under the Apache License, Version 2.0 (the "License");
- *    you may not use this file except in compliance with the License.
- *    You may obtain a copy of the License at
- *
- *        http://www.apache.org/licenses/LICENSE-2.0
- *
- *    Unless required by applicable law or agreed to in writing, software
- *    distributed under the License is distributed on an "AS IS" BASIS,
- *    WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- *    See the License for the specific language governing permissions and
- *    limitations under the License.
- */
-/**
- * @file    global_logic.cpp
- * @author  Lukasz Marek (l.marek@samgsung.com)
- * @version
- * @brief
- */
-
-#include "global_logic.h"
-
-#include <dpl/singleton_impl.h>
-IMPLEMENT_SINGLETON(GlobalLogic)
-
-GlobalLogic::GlobalLogic()
-{
-}
-
-GlobalLogic::~GlobalLogic()
-{
-}
-
-GlobalModel* GlobalLogic::GetGlobalModel() const
-{
-    FREE_LOGIC_LOCK
-    static GlobalModel globalLogic;
-    return &globalLogic;
-}
diff --git a/src/global_logic/global_logic.h b/src/global_logic/global_logic.h
deleted file mode 100644 (file)
index 604c965..0000000
+++ /dev/null
@@ -1,40 +0,0 @@
-/*
- * Copyright (c) 2011 Samsung Electronics Co., Ltd All Rights Reserved
- *
- *    Licensed under the Apache License, Version 2.0 (the "License");
- *    you may not use this file except in compliance with the License.
- *    You may obtain a copy of the License at
- *
- *        http://www.apache.org/licenses/LICENSE-2.0
- *
- *    Unless required by applicable law or agreed to in writing, software
- *    distributed under the License is distributed on an "AS IS" BASIS,
- *    WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- *    See the License for the specific language governing permissions and
- *    limitations under the License.
- */
-/**
- * @file    global_logic.h
- * @author  Lukasz Marek (l.marek@samgsung.com)
- * @version
- * @brief
- */
-
-#include <dpl/singleton.h>
-
-#include <global_model.h>
-#include <FreeLogic.h>
-
-class GlobalLogic : public FreeLogic
-{
-  public:
-    GlobalModel* GetGlobalModel() const;
-
-  private:
-    GlobalLogic();
-    ~GlobalLogic();
-
-    friend class DPL::Singleton<GlobalLogic>;
-};
-
-typedef DPL::Singleton<GlobalLogic> GlobalLogicSingleton;
diff --git a/src/global_logic/global_model.cpp b/src/global_logic/global_model.cpp
deleted file mode 100644 (file)
index f9c703c..0000000
+++ /dev/null
@@ -1,75 +0,0 @@
-/*
- * Copyright (c) 2011 Samsung Electronics Co., Ltd All Rights Reserved
- *
- *    Licensed under the Apache License, Version 2.0 (the "License");
- *    you may not use this file except in compliance with the License.
- *    You may obtain a copy of the License at
- *
- *        http://www.apache.org/licenses/LICENSE-2.0
- *
- *    Unless required by applicable law or agreed to in writing, software
- *    distributed under the License is distributed on an "AS IS" BASIS,
- *    WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- *    See the License for the specific language governing permissions and
- *    limitations under the License.
- */
-/*
- * @file        global_model.cpp
- * @author      Przemyslaw Dobrowolski (p.dobrowolsk@samsung.com)
- */
-#include "global_model.h"
-#include <dpl/wrt-dao-ro/global_dao_read_only.h>
-
-using namespace WrtDB;
-
-GlobalModel::GlobalModel() :
-    HomeNetworkAccess(this,
-        & GlobalModel::HomeNetworkAccessReadProperty),
-    RoamingNetworkAccess(this,
-        & GlobalModel::RoamingNetworkAccessReadProperty),
-    DeveloperMode(this,
-        static_cast<DPL::Event::Property<bool,
-                        DPL::Event::PropertyReadOnly,
-                        DPL::Event::PropertyStorageDynamicCached>::ReadDelegateType>
-                        (& GlobalModel::ReadDeveloperMode))
-{
-}
-
-GlobalModel::NetworkAccessMode GlobalModel::HomeNetworkAccessReadProperty(
-        DPL::Event::Model* /*model*/)
-{
-    switch (GlobalDAOReadOnly::GetHomeNetworkDataUsage()) {
-    case GlobalDAOReadOnly::NEVER_CONNECT:
-        return GlobalModel::NEVER_CONNECT;
-    case GlobalDAOReadOnly::ALWAYS_ASK:
-        return GlobalModel::ALWAYS_ASK;
-    case GlobalDAOReadOnly::CONNECT_AUTOMATICALLY:
-        return GlobalModel::CONNECT_AUTOMATICALLY;
-    default:
-        break;
-    }
-    LogWarning("using default value");
-    return GlobalModel::ALWAYS_ASK;
-}
-
-GlobalModel::NetworkAccessMode GlobalModel::RoamingNetworkAccessReadProperty(
-        DPL::Event::Model* /*model*/)
-{
-    switch (GlobalDAOReadOnly::GetRoamingDataUsage()) {
-    case GlobalDAOReadOnly::NEVER_CONNECT:
-        return GlobalModel::NEVER_CONNECT;
-    case GlobalDAOReadOnly::ALWAYS_ASK:
-        return GlobalModel::ALWAYS_ASK;
-    case GlobalDAOReadOnly::CONNECT_AUTOMATICALLY:
-        return GlobalModel::CONNECT_AUTOMATICALLY;
-    default:
-        break;
-    }
-    LogWarning("using default value");
-    return GlobalModel::ALWAYS_ASK;
-}
-
-bool GlobalModel::ReadDeveloperMode(DPL::Event::Model */*model*/)
-{
-    return GlobalDAOReadOnly::GetDeveloperMode();
-}
diff --git a/src/global_logic/global_model.h b/src/global_logic/global_model.h
deleted file mode 100644 (file)
index 065ca3b..0000000
+++ /dev/null
@@ -1,66 +0,0 @@
-/*
- * Copyright (c) 2011 Samsung Electronics Co., Ltd All Rights Reserved
- *
- *    Licensed under the Apache License, Version 2.0 (the "License");
- *    you may not use this file except in compliance with the License.
- *    You may obtain a copy of the License at
- *
- *        http://www.apache.org/licenses/LICENSE-2.0
- *
- *    Unless required by applicable law or agreed to in writing, software
- *    distributed under the License is distributed on an "AS IS" BASIS,
- *    WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- *    See the License for the specific language governing permissions and
- *    limitations under the License.
- */
-/*
- * @file        global_model.h
- * @author      Przemyslaw Dobrowolski (p.dobrowolsk@samsung.com)
- */
-#ifndef WRT_COMMON_GLOBAL_MODEL_H_
-#define WRT_COMMON_GLOBAL_MODEL_H_
-
-#include <string>
-#include <dpl/event/model.h>
-#include <dpl/event/property.h>
-#include <dpl/type_list.h>
-#include <dpl/shared_ptr.h>
-
-class GlobalModel : public DPL::Event::Model
-{
-  public:
-
-    /**
-     * Network access mode enum.
-     */
-    enum NetworkAccessMode
-    {
-        NEVER_CONNECT,
-        ALWAYS_ASK,
-        CONNECT_AUTOMATICALLY
-    };
-
-    DPL::Event::Property<NetworkAccessMode,
-                  DPL::Event::PropertyReadOnly,
-                  DPL::Event::PropertyStorageDynamicCached> HomeNetworkAccess;
-
-    DPL::Event::Property<NetworkAccessMode,
-                  DPL::Event::PropertyReadOnly,
-                  DPL::Event::PropertyStorageDynamicCached> RoamingNetworkAccess;
-
-    DPL::Event::Property<bool,
-                  DPL::Event::PropertyReadOnly,
-                  DPL::Event::PropertyStorageDynamicCached> DeveloperMode;
-
-    GlobalModel();
-
-  private:
-    // Custom read write delegates
-    static NetworkAccessMode HomeNetworkAccessReadProperty(DPL::Event::Model *model);
-
-    static NetworkAccessMode RoamingNetworkAccessReadProperty(DPL::Event::Model *model);
-
-    static bool ReadDeveloperMode(DPL::Event::Model *model);
-};
-
-#endif // WRT_COMMON_GLOBAL_MODEL_H_
diff --git a/src/utils/DESCRIPTION b/src/utils/DESCRIPTION
deleted file mode 100644 (file)
index ff8cc40..0000000
+++ /dev/null
@@ -1 +0,0 @@
-General purpose utilities
diff --git a/src/utils/FreeLogic.h b/src/utils/FreeLogic.h
deleted file mode 100644 (file)
index 4383236..0000000
+++ /dev/null
@@ -1,69 +0,0 @@
-/*
- * Copyright (c) 2011 Samsung Electronics Co., Ltd All Rights Reserved
- *
- *    Licensed under the Apache License, Version 2.0 (the "License");
- *    you may not use this file except in compliance with the License.
- *    You may obtain a copy of the License at
- *
- *        http://www.apache.org/licenses/LICENSE-2.0
- *
- *    Unless required by applicable law or agreed to in writing, software
- *    distributed under the License is distributed on an "AS IS" BASIS,
- *    WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- *    See the License for the specific language governing permissions and
- *    limitations under the License.
- */
-/**
- * @file    FreeLogic.h
- * @author  Piotr Kozbial (p.kozbial@samsung.com)
- * @version 1.0
- * @brief   Common base for Free Logic classes
- */
-
-#ifndef WRT_UTILS_FREELOGIC_H_
-#define WRT_UTILS_FREELOGIC_H_
-
-#include <dpl/noncopyable.h>
-#include <dpl/mutex.h>
-
-/*
- * This is the base class for any "Free Logic" class.
- *
- * A Free Logic is a bit like a Logic, but the difference is
- * that a Logic is always coupled with a controller and so
- * it is assigned to a single thread, while a Free Logic
- * doesn't have a controller, so it doesn't have a designated
- * thread.
- *
- * A Free Logic's public interface may be directly called
- * from any thread. For this to be safe, every Free Logic must
- * adhere to the following constraints:
- *
- * 1. Every (no matter how trivial) public API function must
- *    start with locking the mutex using the following macro:
- *
- *        FREE_LOGIC_LOCK
- *
- *  2. A Free Logic cannot contact other Logics, that is,
- *     it cannot POST events to controllers and it cannot
- *     call methods of other FreeLogics.
- *
- *  3. A Free Logic cannot emit or receive any events.
- *
- *  4. A Free Logic cannot do blocking system calls.
- *
- *  5. A Free Logic cannot use any synchronization
- *     mechanisms (except the default lock, as described
- *     above).
- */
-class FreeLogic : private DPL::Noncopyable
-{
-  protected:
-    mutable DPL::Mutex _freeLogicMutex;
-};
-
-#define FREE_LOGIC_LOCK \
-    DPL::Mutex::ScopedLock _freeLogicLock(&_freeLogicMutex);
-
-#endif // WRT_UTILS_FREELOGIC_H_
-
index 2940d3e..90c0f32 100644 (file)
@@ -40,8 +40,6 @@ PKG_CHECK_MODULES(SYS_VIEW_MODULE_DEP
 )
 
 SET(VIEW_MODULE_SOURCES
-    ${PROJECT_SOURCE_DIR}/src/global_logic/global_logic.cpp #TODO this should be moved to separate module
-    ${PROJECT_SOURCE_DIR}/src/global_logic/global_model.cpp #TODO this should be moved to separate module
     ${PROJECT_SOURCE_DIR}/src/view/webkit/view_logic.cpp
     ${PROJECT_SOURCE_DIR}/src/view/webkit/view_logic_filesystem_support.cpp
     ${PROJECT_SOURCE_DIR}/src/view/webkit/view_logic_scheme_support.cpp
index 8ca5f02..addf2c4 100644 (file)
@@ -22,7 +22,6 @@
 #include <dpl/exception.h>
 #include <common/application_data.h>
 #include <core_module.h>
-#include <global_logic.h>
 #include <localization_setting.h>
 #include <widget_deserialize_model.h>
 #include <EWebKit2.h>
@@ -251,9 +250,7 @@ bool WrtClient::checkDebugMode(SDKDebugData* debugData)
         // every launched widgets as debug mode can use it.
         if (m_dao->getWidgetType().appType == WrtDB::APP_TYPE_WAC20)
         {
-            bool developerMode =
-                GlobalLogicSingleton::Instance().GetGlobalModel()
-                ->DeveloperMode.Get();
+            bool developerMode = WRT::CoreModuleSingleton::Instance().developerMode();
             //This code will be activated
             //after WAC test certificate is used by SDK
             //bool isTestWidget = view->m_widgetModel->IsTestWidget.Get();
@@ -309,8 +306,7 @@ bool WrtClient::checkWACTestCertififedWidget()
     // Developer Mode.
 
     bool developerWidget = m_dao->isTestWidget();
-    bool developerMode =
-        GlobalLogicSingleton::Instance().GetGlobalModel()->DeveloperMode.Get();
+    bool developerMode = WRT::CoreModuleSingleton::Instance().developerMode();
 
     LogDebug("Is WAC test widget: " << developerWidget);
     LogDebug("Is developer Mode: " << developerMode);