summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorhuiyu.eun <huiyu.eun@samsung.com>2024-06-04 13:14:45 +0900
committerhuiyu.eun <huiyu.eun@samsung.com>2024-06-04 13:14:45 +0900
commit3b1f15283e990422c0dc762469d03a1132c10be4 (patch)
treead29a02986c0060c7c44e58f92251564159477b1
parent4ea8e8cddf48aaace987014948a1e9b694413938 (diff)
downloaddali-adaptor-3b1f15283e990422c0dc762469d03a1132c10be4.tar.gz
dali-adaptor-3b1f15283e990422c0dc762469d03a1132c10be4.tar.bz2
dali-adaptor-3b1f15283e990422c0dc762469d03a1132c10be4.zip
Revert "Fix svace issue"
This reverts commit 4ea8e8cddf48aaace987014948a1e9b694413938.
-rw-r--r--dali/internal/application-model/component-based/appmodel-component-based-tizen.cpp3
-rw-r--r--dali/internal/application-model/normal/appmodel-normal-tizen.cpp3
-rw-r--r--dali/internal/application-model/watch/appmodel-watch-tizen.cpp3
-rw-r--r--dali/internal/application-model/widget/appmodel-widget-tizen.cpp6
-rw-r--r--dali/internal/system/tizen-wayland/widget-application-impl-tizen.cpp11
-rw-r--r--dali/internal/system/tizen-wayland/widget-controller-tizen.cpp10
6 files changed, 15 insertions, 21 deletions
diff --git a/dali/internal/application-model/component-based/appmodel-component-based-tizen.cpp b/dali/internal/application-model/component-based/appmodel-component-based-tizen.cpp
index 4adef23d8..c28c1db97 100644
--- a/dali/internal/application-model/component-based/appmodel-component-based-tizen.cpp
+++ b/dali/internal/application-model/component-based/appmodel-component-based-tizen.cpp
@@ -47,8 +47,7 @@ extern "C" DALI_ADAPTOR_API AppModelComponentBased* Create() {
}
extern "C" DALI_ADAPTOR_API void Destroy(void* p) {
- AppModelComponentBased* appComponent = static_cast<AppModelComponentBased*>(p);
- delete appComponent;
+ delete p;
}
extern "C" DALI_ADAPTOR_API int AppMain(bool isUiThread, void* data, void* pData) {
diff --git a/dali/internal/application-model/normal/appmodel-normal-tizen.cpp b/dali/internal/application-model/normal/appmodel-normal-tizen.cpp
index 80b75d01e..4b27e1450 100644
--- a/dali/internal/application-model/normal/appmodel-normal-tizen.cpp
+++ b/dali/internal/application-model/normal/appmodel-normal-tizen.cpp
@@ -56,8 +56,7 @@ extern "C" DALI_ADAPTOR_API AppModelNormal* Create() {
}
extern "C" DALI_ADAPTOR_API void Destroy(void* p) {
- AppModelNormal* appNormal = static_cast<AppModelNormal*>(p);
- delete appNormal;
+ delete p;
}
extern "C" DALI_ADAPTOR_API int AppMain(bool isUiThread, void* data, void* pData) {
diff --git a/dali/internal/application-model/watch/appmodel-watch-tizen.cpp b/dali/internal/application-model/watch/appmodel-watch-tizen.cpp
index b29c3474d..6a7a5d59a 100644
--- a/dali/internal/application-model/watch/appmodel-watch-tizen.cpp
+++ b/dali/internal/application-model/watch/appmodel-watch-tizen.cpp
@@ -49,8 +49,7 @@ extern "C" DALI_ADAPTOR_API AppModelWatch* Create() {
}
extern "C" DALI_ADAPTOR_API void Destroy(void* p) {
- AppModelWatch* appWatch = static_cast<AppModelWatch*>(p);
- delete appWatch;
+ delete p;
}
extern "C" DALI_ADAPTOR_API int AppMain(bool isUiThread, void* data, void* pData) {
diff --git a/dali/internal/application-model/widget/appmodel-widget-tizen.cpp b/dali/internal/application-model/widget/appmodel-widget-tizen.cpp
index efbef24dc..109ed100b 100644
--- a/dali/internal/application-model/widget/appmodel-widget-tizen.cpp
+++ b/dali/internal/application-model/widget/appmodel-widget-tizen.cpp
@@ -49,19 +49,21 @@ namespace Adaptor
{
extern "C" DALI_ADAPTOR_API AppModelWidget* Create() {
+ print_log(DLOG_INFO, "DALI", "AppModelWidget Create");
return new AppModelWidget();
}
extern "C" DALI_ADAPTOR_API void Destroy(void* p) {
- AppModelWidget* appWidget = static_cast<AppModelWidget*>(p);
- delete appWidget;
+ delete p;
}
extern "C" DALI_ADAPTOR_API int AppMain(bool isUiThread, void* data, void* pData) {
+ print_log(DLOG_INFO, "DALI", "AppModelWidget AppMain 1");
AppModelWidget* appWidget = static_cast<AppModelWidget*>(pData);
int ret = 0;
if (appWidget != nullptr)
{
+ print_log(DLOG_INFO, "DALI", "AppModelWidget AppMain 2");
ret = appWidget->AppMain(data);
}
else
diff --git a/dali/internal/system/tizen-wayland/widget-application-impl-tizen.cpp b/dali/internal/system/tizen-wayland/widget-application-impl-tizen.cpp
index 8cb649628..789eea5f6 100644
--- a/dali/internal/system/tizen-wayland/widget-application-impl-tizen.cpp
+++ b/dali/internal/system/tizen-wayland/widget-application-impl-tizen.cpp
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2024 Samsung Electronics Co., Ltd.
+ * Copyright (c) 2023 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.
@@ -141,14 +141,11 @@ void WidgetApplicationTizen::RegisterWidgetCreatingFunction(const std::string& w
}
registerFunctionPtr = reinterpret_cast<RegisterFunction>(dlsym(mHandle, "RegisterWidgetCallback"));
- if(registerFunctionPtr != nullptr)
+ if(registerFunctionPtr == nullptr)
{
- registerFunctionPtr(widgetName.c_str(), this);
- }
- else
- {
- print_log(DLOG_INFO, "DALI", "registerFunctionPtr is null\n");
+ DALI_LOG_ERROR("createFunctionPtr is null\n");
}
+ registerFunctionPtr(widgetName.c_str(), this);
if(mHandle!=NULL)
{
diff --git a/dali/internal/system/tizen-wayland/widget-controller-tizen.cpp b/dali/internal/system/tizen-wayland/widget-controller-tizen.cpp
index 0fb4a18be..18c13aed6 100644
--- a/dali/internal/system/tizen-wayland/widget-controller-tizen.cpp
+++ b/dali/internal/system/tizen-wayland/widget-controller-tizen.cpp
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2024 Samsung Electronics Co., Ltd.
+ * Copyright (c) 2021 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.
@@ -83,14 +83,12 @@ void WidgetImplTizen::SetContentInfo(const std::string& contentInfo)
}
setContentInfoFuncPtr = reinterpret_cast<SetContentInfoFunc>(dlsym(mHandle, "SetContentInfo"));
- if(setContentInfoFuncPtr != nullptr)
- {
- setContentInfoFuncPtr(mInstanceHandle, contentBundle);
- }
- else
+ if(setContentInfoFuncPtr == nullptr)
{
print_log(DLOG_ERROR, "DALI", "SetContentInfo is null\n" );
+ return;
}
+ setContentInfoFuncPtr(mInstanceHandle, contentBundle);
bundle_free(contentBundle);