From: YoungHun Kim Date: Fri, 18 Jan 2019 07:37:18 +0000 (+0900) Subject: Change to use new feature of external storage X-Git-Tag: submit/tizen/20190129.225447~2 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=c19c0258dec2bb3e85d5526762fc64fb4ffbba9e;p=platform%2Fcore%2Fmultimedia%2Fmmsvc-core.git Change to use new feature of external storage Change-Id: I916b07af824c8939ab98b79424b73f8fcb2e2da2 --- diff --git a/packaging/mused.spec b/packaging/mused.spec index 670c7252..c3e48936 100644 --- a/packaging/mused.spec +++ b/packaging/mused.spec @@ -1,6 +1,6 @@ Name: mused Summary: A multimedia daemon -Version: 0.3.63 +Version: 0.3.64 Release: 0 Group: System/Libraries License: Apache-2.0 and BSD-3-Clause diff --git a/server/src/muse_server_system.c b/server/src/muse_server_system.c index 358aadaf..4d952023 100644 --- a/server/src/muse_server_system.c +++ b/server/src/muse_server_system.c @@ -24,6 +24,8 @@ #include #include +#define MUSE_STORAGE_EXTERNAL_FEATURE "http://tizen.org/feature/storage.external" + enum muse_poweroff_type { MUSE_POWER_OFF_NONE = 0, MUSE_POWER_OFF_POPUP, @@ -362,6 +364,10 @@ int ms_system_get_platform_info(const char *key, bool *value) void ms_system_subscribe_external_event(ms_system_t *system) { +#ifdef MUSE_USE_EXTERNAL_STORAGE_STATE_CHANGE + int ret = MM_ERROR_NONE; + bool is_external_storage_enabled; +#endif muse_return_if_fail(system); #ifdef MUSE_USE_POWER_OFF_STATE_CHANGE @@ -370,7 +376,8 @@ void ms_system_subscribe_external_event(ms_system_t *system) #endif #ifdef MUSE_USE_EXTERNAL_STORAGE_STATE_CHANGE - if (ms_get_instance()->conf->is_watch_external_storage_enabled == TRUE && + ret = system_info_get_platform_bool(MUSE_STORAGE_EXTERNAL_FEATURE, &is_external_storage_enabled); + if (ret == MM_ERROR_NONE && is_external_storage_enabled == true && _ms_system_subscribe_external_storage_state_change(system) != MM_ERROR_NONE) LOGE("Fail to subscribe external storage state change"); #endif