From 923dc023a0ec3604c1c3a76ee63b421d773dc173 Mon Sep 17 00:00:00 2001 From: "pr.jung" Date: Tue, 29 Nov 2016 14:17:43 +0900 Subject: [PATCH] Remove system-settings dependency - Get Ringtone path using vconfkey Change-Id: Iea9d680f85f8c6fc3c8ed8d42b1bd47aa99ce148 Signed-off-by: pr.jung --- CMakeLists.txt | 1 - packaging/libstorage.spec | 1 - src/storage.c | 8 +++----- 3 files changed, 3 insertions(+), 7 deletions(-) diff --git a/CMakeLists.txt b/CMakeLists.txt index a4feb38..3169d78 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -17,7 +17,6 @@ SET(dependents glib-2.0 gio-2.0 libtzplatform-config - capi-system-system-settings mount ) SET(pc_dependents "capi-base-common") diff --git a/packaging/libstorage.spec b/packaging/libstorage.spec index 90eae50..57611e7 100644 --- a/packaging/libstorage.spec +++ b/packaging/libstorage.spec @@ -13,7 +13,6 @@ BuildRequires: pkgconfig(vconf) BuildRequires: pkgconfig(glib-2.0) BuildRequires: pkgconfig(gio-2.0) BuildRequires: pkgconfig(libtzplatform-config) -BuildRequires: pkgconfig(capi-system-system-settings) BuildRequires: pkgconfig(mount) %description diff --git a/src/storage.c b/src/storage.c index 26b4036..42aaec2 100644 --- a/src/storage.c +++ b/src/storage.c @@ -19,7 +19,7 @@ #include #include #include -#include +#include #include "common.h" #include "list.h" @@ -164,11 +164,9 @@ API int storage_get_directory(int storage_id, storage_directory_e type, char **p if (found && st) { snprintf(root, sizeof(root), "%s", st->root()); if (type == STORAGE_DIRECTORY_SYSTEM_RINGTONES) { - ret = system_settings_get_value_string(SYSTEM_SETTINGS_KEY_INCOMING_CALL_RINGTONE, &temp2); - if (ret < 0) { - _E("Failed to get ringtone path : %d", ret); //LCOV_EXCL_LINE + temp2 = vconf_get_str(VCONFKEY_SETAPPL_CALL_RINGTONE_PATH_STR); + if (temp2 == NULL) return STORAGE_ERROR_OPERATION_FAILED; - } end = strrchr(temp2, '/'); if (end) *end = '\0'; -- 2.7.4