From: Kyeonghun Lee Date: Wed, 18 Jan 2017 05:25:05 +0000 (+0900) Subject: [P161228-01293] change on-boot attribute to true from false X-Git-Tag: accepted/tizen/3.0/common/20170201.164657~2 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=44ef608350fb97cf0d37f482c40d0c842e21faeb;p=platform%2Fcore%2Fmessaging%2Fmsg-service.git [P161228-01293] change on-boot attribute to true from false Change-Id: I1e7837a125b11648de33ea1376027b0c9666b536 Signed-off-by: Kyeonghun Lee --- diff --git a/externals/MsgNotificationWrapper.cpp b/externals/MsgNotificationWrapper.cpp index 40b7409..5660448 100755 --- a/externals/MsgNotificationWrapper.cpp +++ b/externals/MsgNotificationWrapper.cpp @@ -525,15 +525,3 @@ msg_error_t MsgInsertTicker(const char* pTickerMsg, const char* pLocaleTickerMsg #endif /* MSG_WEARABLE_PROFILE */ return err; } - - -void MsgBootMsgMgr() -{ - bundle *bundle_data = bundle_create(); - - bundle_add_str(bundle_data, "cmd", "on_boot"); - - msg_launch_app(MSG_MGR_APP_ID, bundle_data); - - bundle_free(bundle_data); -} diff --git a/framework/main.cpp b/framework/main.cpp index ee579b9..4ecc9ad 100755 --- a/framework/main.cpp +++ b/framework/main.cpp @@ -35,7 +35,6 @@ #include "MsgCmdHandler.h" #include "MsgUtilFile.h" #include "MsgUtilStorage.h" -#include "MsgNotificationWrapper.h" #include #include @@ -66,7 +65,6 @@ void* InitMsgServer(void*) } MsgInitSensor(); - MsgBootMsgMgr(); /* plugin manager initialize */ MsgPluginManager::instance()->initialize(); diff --git a/include/externals/MsgNotificationWrapper.h b/include/externals/MsgNotificationWrapper.h index fb28215..b758eee 100755 --- a/include/externals/MsgNotificationWrapper.h +++ b/include/externals/MsgNotificationWrapper.h @@ -116,6 +116,4 @@ void MsgSoundPlayStart(const MSG_ADDRESS_INFO_S *pAddrInfo, MSG_SOUND_TYPE_T sou void MsgRefreshAllNotification(bool bWithSimNoti, bool bFeedback, msg_active_notification_type_t active_type); -void MsgBootMsgMgr(); - #endif diff --git a/manager/src/msg-manager-util.cpp b/manager/src/msg-manager-util.cpp index c9398ee..d62e026 100644 --- a/manager/src/msg-manager-util.cpp +++ b/manager/src/msg-manager-util.cpp @@ -74,7 +74,7 @@ int MsgMgrAlarmInit() alarmCBMap.clear(); - int retval = alarmmgr_init("msg-service-tools"); + int retval = alarmmgr_init(MSG_MGR_APP_ID); if (retval != ALARMMGR_RESULT_SUCCESS) { MSG_MGR_DEBUG("alarmmgr_init error [%d]", retval); return -1; diff --git a/manager/src/msg-manager.cpp b/manager/src/msg-manager.cpp index 3f66681..590c238 100644 --- a/manager/src/msg-manager.cpp +++ b/manager/src/msg-manager.cpp @@ -660,7 +660,7 @@ void _change_pm_state_func(app_control_h app_control) MsgMgrChangePmState(); } -void _on_boot_func(app_control_h app_control) +void _on_boot_func() { MsgMgrOnBoot(); } @@ -781,13 +781,14 @@ void service_app_control(app_control_h app_control, void *data) _sound_play_start_func(app_control); } else if (g_strcmp0(cmd, "change_pm_state") == 0) { _change_pm_state_func(app_control); - } else if (g_strcmp0(cmd, "on_boot") == 0) { - _on_boot_func(app_control); } else if (g_strcmp0(cmd, "reply_msg") == 0) { _reply_msg_func(app_control); } g_free(cmd); + } else if (ret == APP_CONTROL_ERROR_KEY_NOT_FOUND) { + MSG_MGR_INFO("on boot"); + _on_boot_func(); } } g_free(operation); diff --git a/manager/tizen-manifest.xml b/manager/tizen-manifest.xml index 673dd76..15a8d8a 100644 --- a/manager/tizen-manifest.xml +++ b/manager/tizen-manifest.xml @@ -1,7 +1,7 @@ - + msg-manager.png