From: Hwankyu Jhun Date: Tue, 12 Apr 2022 07:47:26 +0000 (+0900) Subject: Fix wrong implementation about AppControl call X-Git-Tag: accepted/tizen/unified/20220413.133142~1 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=44f0bb9ec6f0e9d175f99a6a300894c871edc8d6;p=platform%2Fcore%2Fappfw%2Fapp-core.git Fix wrong implementation about AppControl call If the bundle data has "__K_SERVICE_THREAD", the request will be delivered to the service thread. Change-Id: Id5fba4c8b49a561085029001c61a33f096de7f1e Signed-off-by: Hwankyu Jhun --- diff --git a/tizen-cpp/app-core-ui-cpp/app_core_ui_base.cc b/tizen-cpp/app-core-ui-cpp/app_core_ui_base.cc index f16788b..f5b0d9b 100644 --- a/tizen-cpp/app-core-ui-cpp/app_core_ui_base.cc +++ b/tizen-cpp/app-core-ui-cpp/app_core_ui_base.cc @@ -42,6 +42,8 @@ namespace tizen_cpp { +constexpr const char K_SERVICE_THREAD[] = "__K_SERVICE_THREAD"; + class AppCoreUiBase::Impl { public: Impl(AppCoreUiBase* parent, unsigned int hint) @@ -608,9 +610,15 @@ int AppCoreUiBase::OnReceive(aul_type type, tizen_base::Bundle b) { impl_->state_ != Impl::AS_PAUSED) return 0; - if (type == AUL_START) + if (type == AUL_START) { impl_->ExitFromSuspend(); + if (!b.GetString(K_SERVICE_THREAD).empty()) { + impl_->service_->OnReceive(type, std::move(b)); + return 0; + } + } + AppCoreBase::OnReceive(type, b); switch (type) {