// Set privilege by tizen id
// this code prevent that widget launch with "root" permission,
// when developers launch by command in the shell
- set_privilege(DPL::ToUTF8String(m_widgetModel->TizenId).c_str());
+
+ set_app_privilege(
+ DPL::ToUTF8String(m_widgetModel->TizenId).c_str(),
+ m_widgetModel->Type.Get().getApptypeToString().c_str(),
+ DPL::ToUTF8String(m_widgetModel->InstallPath.Get()).c_str()
+ );
}
}
* invalid
*
*/
-int apply_csp(Ewk_Context* context, WKStringRef policy, CSP_Rules *local, CSP_Rules *http_meta)
+int apply_csp(Ewk_Context* /*context*/, WKStringRef /*policy*/, CSP_Rules */*local*/, CSP_Rules */*http_meta*/)
{
LogDebug("Setting csp policy");
return 0;
DPL::Event::PropertyStorageDynamicCached> Type;
/**
+ * @brief Config file based csp policy
+ */
+ DPL::Event::Property<DPL::OptionalString,
+ DPL::Event::PropertyReadOnly,
+ DPL::Event::PropertyStorageDynamicCached> CspPolicy;
+
+ /**
* @brief Current widget actual size
*/
DPL::Event::Property<WidgetSize> ActualSize;
DPL::Event::Property<OptionalWidgetIcon> Icon;
/**
- * @brief Config file based csp policy
- */
- DPL::Event::Property<DPL::OptionalString,
- DPL::Event::PropertyReadOnly,
- DPL::Event::PropertyStorageDynamicCached> CspPolicy;
-
- /**
* @brief Widget splash image src
*/
DPL::Event::Property<DPL::OptionalString,
0, /* willDestroyGlobalObjectForDOMWindowExtension */
0, /* didFinishProgress */
0, /* shouldForceUniversalAccessFromLocalURL */
+ 0, /* didReceiveIntentForFrame */
+ 0, /* registerIntentServiceForFrame */
};
WKBundlePageSetPageLoaderClient(page, &loaderClient);
}
}
} else {
LogDebug("ContextMenu Enable!!");
- int menu_num = ewk_context_menu_item_count(menu);
+ unsigned int menu_num = ewk_context_menu_item_count(menu);
unsigned int idx = 0;
do {
Ewk_Context_Menu_Item* item = ewk_context_menu_nth_item_get(menu,
//have to be separated
//TODO attach database only one at the start (not in every callback?)
void ViewLogic::protocolHandlerRegistrationCallback(void* data,
- Evas_Object* obj,
+ Evas_Object* /*obj*/,
void* eventInfo)
{
Assert(data);
}
void ViewLogic::protocolHandlerIsRegisteredCallback(void* data,
- Evas_Object* obj,
+ Evas_Object* /*obj*/,
void* eventInfo)
{
LogDebug("enter");
}
void ViewLogic::protocolHandlerUnregistrationCallback(void* data,
- Evas_Object* obj,
+ Evas_Object* /*obj*/,
void* eventInfo)
{
LogDebug("enter");
}
void ViewLogic::contentHandlerRegistrationCallback(void* data,
- Evas_Object* obj,
+ Evas_Object* /*obj*/,
void* eventInfo)
{
Assert(data);
}
void ViewLogic::contentHandlerIsRegisteredCallback(void* data,
- Evas_Object* obj,
+ Evas_Object* /*obj*/,
void* eventInfo)
{
LogDebug("enter");
}
void ViewLogic::contentHandlerUnregistrationCallback(void* data,
- Evas_Object* obj,
+ Evas_Object* /*obj*/,
void* eventInfo)
{
LogDebug("enter");
This->m_widget->Backward();
}
-int WrtClient::appcoreLowMemoryCallback(void* data)
+int WrtClient::appcoreLowMemoryCallback(void* /*data*/)
{
LogInfo("appcoreLowMemoryCallback");
- WrtClient* This = static_cast<WrtClient*>(data);
+ //WrtClient* This = static_cast<WrtClient*>(data);
// TODO call RunnableWidgetObject API regarding low memory
// The API should be implemented
app_argv = __create_argc_argv(kb, &app_argc);
#ifndef NATIVE_LAUNCHPAD
- if (__change_cmdline(app_path) < 0) {
+ if (__change_cmdline((char *)app_path) < 0) {
_E("change cmdline fail");
return;
}
r = XQueryTree(d, *win, &root, &parent, &child, &n);
if (r) {
- int i;
+ unsigned int i;
int found = 0;
for (i = 0; i < n; i++) {
return 0;
}
-static int __cb_x_error(Display *disp, XErrorEvent *ev)
+static int __cb_x_error(Display* disp, XErrorEvent *ev)
{
+ (void)disp;
_E("X error received - Error Code = %d", ev->error_code);
return 0;
}
int __create_client_sock(int pid)
{
int fd = -1;
- struct sockaddr_un saddr = { 0, };
+ struct sockaddr_un saddr;
+ memset(&saddr, 0, sizeof(saddr));
int retry = 1;
int ret = -1;
app_pkt_t *__app_recv_raw(int fd, int *clifd, struct ucred *cr)
{
int len;
- struct sockaddr_un aul_addr = { 0, };
+ struct sockaddr_un aul_addr;
+ memset(&aul_addr, 0, sizeof(aul_addr));
int sun_size;
app_pkt_t *pkt = NULL;
int cl = sizeof(struct ucred);
SET(WRT_DETAIL_SOURCES
${CMAKE_CURRENT_SOURCE_DIR}/src/InstallerWrapper.cpp
- ${CMAKE_CURRENT_SOURCE_DIR}/src/WidgetRunner.cpp
- ${CMAKE_CURRENT_SOURCE_DIR}/src/loop_control.cpp
- ${CMAKE_CURRENT_SOURCE_DIR}/src/TestBase.cpp
${CMAKE_CURRENT_SOURCE_DIR}/src/RunnableObjectStateTester.cpp
)
+++ /dev/null
-/*
- * Copyright (c) 2012 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.
- */
-#ifndef WRT_EXTRA_AUTO_TESTS_COMMON_INCLUDE_TESTBASE_H
-#define WRT_EXTRA_AUTO_TESTS_COMMON_INCLUDE_TESTBASE_H
-
-#include <string>
-
-#include <dpl/noncopyable.h>
-#include <dpl/wrt-dao-ro/global_config.h>
-#include <dpl/wrt-dao-ro/widget_dao_read_only.h>
-#include <dpl/localization/LanguageTagsProvider.h>
-#include <dpl/wrt-dao-ro/widget_dao_read_only.h>
-
-#include <WidgetRunner.h>
-
-class TestBase : DPL::Noncopyable
-{
-protected:
- LanguageTags m_tags;
-
- WrtDB::WidgetDAOReadOnly* dao;
-
- std::string m_widgetPath;
- std::string m_widgetName;
- WrtDB::WidgetPkgName m_widgetTizenId;
- bool m_wrongWidgetPackage;
-
- void CheckRunnerResult(InstallerWrapper::WidgetRunner & runner);
-
-public:
- TestBase(const std::string & path, const std::string & directory);
- virtual ~TestBase();
-
- void StartTest();
- void CheckIsValid();
- void CheckIsNotValid();
-
- void MakeScreenshot();
- /**
- * @brief CheckWidgetJsHook
- * @param hookFile hook file
- */
- void CheckWidgetJsHook(const char* hookFile = "hook.js");
- void CheckWidgetJsReady();
-};
-
-
-#endif // WRT_EXTRA_AUTO_TESTS_COMMON_INCLUDE_TESTBASE_H
+++ /dev/null
-/*
- * 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.
- */
-
-#ifndef WRT_TESTS_W3C_TESTS_WIDGET_RUNNER_H
-#define WRT_TESTS_W3C_TESTS_WIDGET_RUNNER_H
-
-#include <dpl/exception.h>
-#include <string>
-
-namespace InstallerWrapper {
-
- const std::string tmpFile = "/tmp/widget_runner_tmp_result_file";
- const std::string TEST_OK = "OK";
- const std::string TEST_FAIL = "FAIL";
- const std::string TEST_EXCEPTION = "EXCEPTION";
- const std::string TEST_MANUAL = "MANUAL";
-
- class WidgetRunner {
- public:
- WidgetRunner(std::string widgetTizenId, const std::string & name);
- bool addTestHook(const char* packageName, const char* hookFile = "hook.js");
- /**
- * @brief run Launches test in wrt-client and collect its output from 4 descriptor
- * @param hasHook if true messages from js hook are expected in debug
- * @return true if success
- */
- bool run(bool doScreen = false);
- std::string getResult() const;
- std::string getResultWidgetName() const;
- /**
- * @brief setHasHook Stes if test has a hook
- * @param hasHook value
- */
- void setHasHook(bool hasHook);
- private:
-
- DECLARE_EXCEPTION_TYPE(DPL::Exception, GetArgException)
-
- //timeout for 'popen'ed' process output (in seconds)
- static const unsigned popenTimeout;
-
- std::string m_widgetTizenId;
- std::string m_name; //name of file is fs
- std::string m_result; //result of test
- std::string m_resultWidgetName; //name as test presents itselfs
- bool m_hasHook;
- std::string getArg(FILE* file, std::string & lastBuffer);
- /**
- * @brief getArgs
- *
- * Reads parameters from file descriptor
- *
- * @param file fiel descriptor
- * @param id id of widget
- * @param result result value
- * @param resultWidgetName widget name
- * @throw WidgetRunner::GetArgException if parameters cannot be read
- */
- void getArgs(FILE* file, std::string & id, std::string & result,
- std::string & resultWidgetName);
- /**
- * @brief getArgs
- *
- * Reads only text from widget initialzation
- *
- * @param file file descriptor
- * @param initText first inital text from widget initialization
- * @throw WidgetRunner::GetArgException if parameters cannot be read
- */
- void getInitWidgetText(FILE* file, std::string initText);
- /**
- * @brief calculateArgumentAndBuffer
- *
- * Receives argument from buffer
- *
- * @param arg argument to be set
- * @param lastBuffer buffer to be modified
- *
- * Both parameters will be modified
- *
- * @return true if arg was succesfully read
- */
- bool calculateArgumentAndBuffer(std::string & arg, std::string & lastBuffer);
- };
-}
-
-#endif /* WRT_TESTS_W3C_TESTS_WIDGET_RUNNER_H */
-
+++ /dev/null
-/*
- * 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 loop_control.cpp
- * @author Jaroslaw Osmanski (j.osmanski@samsung.com)
- * @version 1.0
- * @brief This file is the definitions of loop controlling utilities
- */
-
-
-#ifndef LOOP_CONTROL_H_
-#define LOOP_CONTROL_H_
-
-namespace LoopControl
-{
-
-void init_loop(int argc, char *argv[]);
-void wait_for_wrt_init();
-void finish_wait_for_wrt_init();
-void quit_loop();
-
-void wrt_start_loop();
-void wrt_end_loop();
-
-void *abstract_window();
-
-}
-
-#endif /* LOOP_CONTROL_H_ */
+++ /dev/null
-/*
- * 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.
- */
-
-#include <TestBase.h>
-
-#include <dpl/string.h>
-
-#include <InstallerWrapper.h>
-#include <dpl/test/test_runner.h>
-
-using namespace WrtDB;
-
-TestBase::TestBase(const std::string & path, const std::string & directory) :
- dao(0),
- m_widgetPath (std::string(WrtDB::GlobalConfig::GetTestsDataPath()) +
- + "/" + directory + "/" + path),
- m_widgetName(path.substr(0, path.find_first_of('.'))),
- m_wrongWidgetPackage(false)
-{
- LanguageTagsProviderSingleton::Instance().setLanguageTagsFromLocales("en");
- m_tags = LanguageTagsProviderSingleton::Instance().getLanguageTags();
-}
-
-TestBase::~TestBase()
-{
- LogDebug("Finishing test case");
-
- LogDebug("deleting dao");
- if (dao)
- {
- delete dao;
- LogDebug("Uninstalling widget " << m_widgetTizenId);
- InstallerWrapper::uninstall(DPL::ToUTF8String(m_widgetTizenId));
- }
-
- LogDebug("Finished");
-}
-
-void TestBase::StartTest()
-{
- std::string id;
- InstallerWrapper::InstallResult result =
- InstallerWrapper::install(m_widgetPath, id);
- if (InstallerWrapper::OtherError == result) {
- this->dao = NULL;
- m_wrongWidgetPackage = false;
- } else if (InstallerWrapper::WrongWidgetPackage == result) {
- this->dao = NULL;
- m_wrongWidgetPackage = true;
- } else {
- m_widgetTizenId = DPL::FromASCIIString(id);
- this->dao = new WidgetDAOReadOnly(m_widgetTizenId);
- }
-}
-
-void TestBase::CheckIsNotValid()
-{
- DPL::String msg;
- if (dao)
- {
- msg = L"Widget should not be installed but has been anyway";
- } else if (!m_wrongWidgetPackage) {
- msg = L"Unknown error happend";
- }
-
- RUNNER_ASSERT_MSG(!dao && m_wrongWidgetPackage,
- "Install finished with: " << msg);
-}
-
-void TestBase::CheckIsValid()
-{
- DPL::String msg;
- if (!dao) {
- if (m_wrongWidgetPackage) {
- msg = L"Wrong widget package";
- } else {
- msg = L"Unknown error happend";
- }
- }
-
- RUNNER_ASSERT_MSG(dao && !m_wrongWidgetPackage,
- "Install finished with: " << msg);
-}
-
-void TestBase::MakeScreenshot()
-{
- InstallerWrapper::WidgetRunner runner(DPL::ToUTF8String(m_widgetTizenId), m_widgetName);
- if (!runner.run(true)) {
- RUNNER_ASSERT_MSG(false, "Screenshot was not made");
- }
-}
-
-void TestBase::CheckWidgetJsHook(const char* hookFile)
-{
- DPL::String package_name = this->dao->getPkgName();
- InstallerWrapper::WidgetRunner runner(DPL::ToUTF8String(m_widgetTizenId), m_widgetName);
- RUNNER_ASSERT_MSG(
- runner.addTestHook(DPL::ToUTF8String(package_name).c_str(), hookFile),
- "Couldn't add hook to " << hookFile);
- RUNNER_ASSERT_MSG(runner.run(true), "Get test result for "
- << runner.getResultWidgetName());
- std::string res = runner.getResult();
- RUNNER_ASSERT_MSG(InstallerWrapper::TEST_OK == res,
- "Test " << runner.getResultWidgetName() << " result: " << res);
-}
-
-void TestBase::CheckWidgetJsReady()
-{
- InstallerWrapper::WidgetRunner runner(DPL::ToUTF8String(m_widgetTizenId), m_widgetName);
-
- runner.setHasHook(true);
-
- if (runner.run(false)) {
- CheckRunnerResult(runner);
- } else {
- RUNNER_ASSERT_MSG(false, "Fail to get test result for "
- << runner.getResultWidgetName());
- }
-}
-
-void TestBase::CheckRunnerResult(InstallerWrapper::WidgetRunner & runner)
-{
- std::string res = runner.getResult();
- LogDebug("Result: " << res);
- if (InstallerWrapper::TEST_OK == res) {
- RUNNER_ASSERT_MSG(true, "Test " << runner.getResultWidgetName()
- << " passed");
- }
- else if (InstallerWrapper::TEST_FAIL == res){
- RUNNER_ASSERT_MSG(false, "Test " << runner.getResultWidgetName()
- << " failed");
- }
- else if (InstallerWrapper::TEST_EXCEPTION == res) {
- RUNNER_ASSERT_MSG(false, "Test " << runner.getResultWidgetName()
- << " threw exception");
- }
- else {
- RUNNER_ASSERT_MSG(false, "Unknown result: " << res);
- }
-}
+++ /dev/null
-/*
- * 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.
- */
-
-#include "WidgetRunner.h"
-
-#include <stdio.h>
-#include <cstdlib>
-#include <fcntl.h>
-#include <dpl/assert.h>
-#include <dpl/log/log.h>
-#include <dpl/wrt-dao-ro/widget_config.h>
-#include <dpl/wrt-dao-ro/global_dao_read_only.h>
-#include <dpl/scoped_fclose.h>
-#include <dpl/utils/wrt_global_settings.h>
-#include <dpl/string.h>
-
-#include <InstallerWrapper.h>
-
-namespace InstallerWrapper {
-
- const unsigned WidgetRunner::popenTimeout = 10;
-
- WidgetRunner::WidgetRunner(std::string widgeTizenId, const std::string & name) {
- m_widgetTizenId = widgeTizenId;
- m_name = name;
- m_hasHook = false;
- }
-
- bool WidgetRunner::addTestHook(const char* packageName, const char* hookFile)
- {
- Assert(packageName != NULL && "packageName is null");
- std::string widgetHookJs(
- WrtDB::WidgetConfig::GetWidgetBasePath(
- DPL::FromUTF8String(std::string(packageName))));
- widgetHookJs += WrtDB::GlobalConfig::GetWidgetSrcPath();
- widgetHookJs += "/";
- widgetHookJs += hookFile;
- DPL::ScopedFClose fp;
- fp.Reset(fopen(widgetHookJs.c_str(), "r"));
- if (!fp) {
- LogError(widgetHookJs << " not found");
- m_hasHook = false;
- return false;
- } else {
- std::string command(
- "sed -i \"s/function hook(id, result, message){};/"
- "function hook(id, result, message){widget \\&\\& "
- "widget.__test \\&\\& "
- "(widget.__test.setEvaluator(function()"
- "{return result == 'pass';}),"
- "widget.__test.run(0.000000));}; /\" ");
- command += widgetHookJs;
- system(command.c_str());
- m_hasHook = true;
- return true;
- }
- }
-
- void WidgetRunner::getInitWidgetText(FILE* file, std::string initText)
- {
- std::string lastBuffer;
- initText = getArg(file, lastBuffer);
- LogDebug("Init Widget text: " << initText);
- }
-
- void WidgetRunner::getArgs(FILE* file, std::string & id,
- std::string & result, std::string & resultWidgetName) {
- std::string lastBuffer;
- id = getArg(file, lastBuffer);
- LogDebug("ID: " << id);
- resultWidgetName = getArg(file, lastBuffer);
- LogDebug("ResultWidgetName: " << resultWidgetName);
- result = getArg(file, lastBuffer);
- LogDebug("Result: " << result);
- }
-
- std::string WidgetRunner::getArg(FILE* file, std::string & lastBuffer) {
- const int count = 100;
- const int fd = fileno(file);
-
- std::string arg;
- char buffer[count];
- bool done = false;
- int tries = popenTimeout;
-
- while (!done) {
- ssize_t rcount = read(fd, buffer, count);
- if (rcount == -1 && errno == EAGAIN) {
- sleep(1);
- if (tries > 0) {
- tries--;
- } else {
- Throw(GetArgException);
- }
- } else if (rcount > 0) {
- //copy buffer
- for (ssize_t i = 0; i < rcount; i++) {
- lastBuffer += buffer[i];
- }
- } else {
- //pipe closed
- Throw(GetArgException);
- }
- //receive requested argument from buffer
- done = calculateArgumentAndBuffer(arg, lastBuffer);
- }
-
- return arg;
- }
-
- bool WidgetRunner::calculateArgumentAndBuffer(std::string & arg,
- std::string & lastBuffer) {
- //get argument
- int posOfN = lastBuffer.find_first_of('\n');
- int posOfT = lastBuffer.find_first_of('\t');
- if (posOfN >= 0) {
- if (posOfT >= 0) {
- if (posOfN < posOfT) {
- arg = lastBuffer.substr(0, posOfN);
- lastBuffer = lastBuffer.substr(posOfN + 1,
- lastBuffer.length());
- return true;
- } else {
- arg = lastBuffer.substr(0, posOfT);
- lastBuffer = lastBuffer.substr(posOfT + 1,
- lastBuffer.length());
- return true;
- }
- } else {
- arg = lastBuffer.substr(0, posOfN);
- lastBuffer = lastBuffer.substr(posOfN + 1,
- lastBuffer.length());
- return true;
- }
- } else {
- if (posOfT >= 0) {
- arg = lastBuffer.substr(0, posOfT);
- lastBuffer = lastBuffer.substr(posOfT + 1,
- lastBuffer.length());
- return true;
- }
- }
- return false;
- }
-
- bool WidgetRunner::run(bool doScreen) {
- std::string command;
- if (!m_hasHook) {
- command += "DEBUG_LOAD_FINISH=1 ";
- } else {
- command += "DEBUG_LOAD_FINISH=0 ";
- }
- command += "wrt-client -t ";
- command += m_widgetTizenId;
- command += " 4>&1 2>>\"";
- command += tmpFile;
- command += "\" 1>>\"";
- command += tmpFile + "\"";
- LogDebug(command);
-
- FILE* result = popen(command.c_str(), "r");
- fcntl(fileno(result), F_SETFL, O_NONBLOCK);
-
- if (result) {
- Try
- {
- if (m_hasHook) {
- std::string id;
- // widget id, test result, widget name
- getArgs(result, id, m_result, m_resultWidgetName);
- } else {
- std::string m_test_id;
- getInitWidgetText(result, m_test_id);
- //this constant string is also in wrt repo, make it constant?
- if (m_test_id == "didFinishLoadForFrameCallback: ready")
- {
- m_resultWidgetName = InstallerWrapper::TEST_MANUAL;
- }
- }
- }
-
- Catch(GetArgException) {
- LogDebug("Test result is not complete");
- }
-
- if (GlobalSettings::MakeScreenTestModeEnabled())
- {
- if (doScreen) {
- if (!m_hasHook) {
- LogDebug("Sleeping");
- sleep(popenTimeout);
- }
- //make a screenshot
- std::string command = std::string("xwd -root -out ") + m_name
- + ".xwd ";
- LogDebug("Running system command: " << command);
- system(command.c_str());
- }
- }
- // close widget (sigint)
- sigintWrtClients();
- pclose(result);
- return true;
- } else {
- return false;
- }
- }
-
- std::string WidgetRunner::getResult() const {
- return m_result;
- }
-
- std::string WidgetRunner::getResultWidgetName() const {
- return m_resultWidgetName;
- }
-
- void WidgetRunner::setHasHook(bool hasHook) {
- m_hasHook = hasHook;
- }
-}
+++ /dev/null
-/*
- * 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 loop_control.cpp
- * @author Jaroslaw Osmanski (j.osmanski@samsung.com)
- * @version 1.0
- * @brief This is implementation of EFL version of loop control
- */
-
-#include <loop_control.h>
-#include <dpl/log/log.h>
-
-#include <dpl/framework_efl.h>
-
-#include <glib.h>
-#include <glib-object.h>
-
-
-namespace LoopControl
-{
-void init_loop(int argc, char *argv[])
-{
- (void)argc;
- (void)argv;
- g_type_init();
- g_thread_init(NULL);
-
- LogInfo("Starting");
- elm_init(argc, argv);
-}
-
-void wait_for_wrt_init()
-{
- ecore_main_loop_begin();
-}
-
-void finish_wait_for_wrt_init()
-{
- ecore_main_loop_quit();
-}
-
-void quit_loop()
-{
- elm_shutdown();
-}
-
-void wrt_start_loop()
-{
- ecore_main_loop_begin();
-}
-
-void wrt_end_loop()
-{
- ecore_main_loop_quit();
-}
-
-void *abstract_window()
-{
- return elm_win_add(NULL, "hello", ELM_WIN_BASIC);
-}
-
-}//end of LoopControl namespace