summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDaehyeon Jung <darrenh.jung@samsung.com>2019-05-30 13:15:26 +0900
committerDaehyeon Jung <darrenh.jung@samsung.com>2019-06-11 09:02:31 +0900
commitcd6b655b88292993ee3b7c2b3c56f95246a97e07 (patch)
tree160b13d04cabd54c83dd621ac26c50612b02d864
parent4d1ec1c7dcdfcb16910f778a50446ae8008dad0a (diff)
downloadapp-manager-cd6b655b88292993ee3b7c2b3c56f95246a97e07.tar.gz
app-manager-cd6b655b88292993ee3b7c2b3c56f95246a97e07.tar.bz2
app-manager-cd6b655b88292993ee3b7c2b3c56f95246a97e07.zip
Change-Id: I5040820ab9d4ffbde2398f8cafd03cf9b935c4a1 Signed-off-by: Daehyeon Jung <darrenh.jung@samsung.com>
-rw-r--r--include/app_info.h13
-rw-r--r--src/app_info.c14
2 files changed, 27 insertions, 0 deletions
diff --git a/include/app_info.h b/include/app_info.h
index 2ae90a3..a9f7740 100644
--- a/include/app_info.h
+++ b/include/app_info.h
@@ -384,6 +384,19 @@ int app_info_is_onboot(app_info_h app_info, bool *onboot);
int app_info_is_preload(app_info_h app_info, bool *preload);
/**
+ * @brief Checks whether the application supports ambient mode.
+ * @since_tizen 5.5
+ * @param[in] app_info The application information
+ * @param[out] ambient_supported @c true if the application supports ambient mode, \n
+ * otherwise @c false
+ * @return @c 0 on success,
+ * otherwise a negative error value
+ * @retval #APP_MANAGER_ERROR_NONE Successful
+ * @retval #APP_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter
+ */
+int app_info_is_support_ambient(app_info_h app_info, bool *ambient_supported);
+
+/**
* @brief Clones the application information handle.
* @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif
* @param[out] clone A newly created application information handle, if successfully cloned
diff --git a/src/app_info.c b/src/app_info.c
index d101c22..e9e23c6 100644
--- a/src/app_info.c
+++ b/src/app_info.c
@@ -681,6 +681,20 @@ API int app_info_is_preload(app_info_h app_info, bool *preload)
return APP_MANAGER_ERROR_NONE;
}
+API int app_info_is_support_ambient(app_info_h app_info, bool *support_ambient)
+{
+ bool val;
+
+ if (app_info == NULL || support_ambient == NULL)
+ return app_manager_error(APP_MANAGER_ERROR_INVALID_PARAMETER, __FUNCTION__, NULL);
+
+ if (pkgmgrinfo_appinfo_is_support_ambient(app_info->pkg_app_info, &val) < 0)
+ return app_manager_error(APP_MANAGER_ERROR_INVALID_PARAMETER, __FUNCTION__, NULL);
+
+ *support_ambient = val;
+ return APP_MANAGER_ERROR_NONE;
+}
+
API int app_info_clone(app_info_h *clone, app_info_h app_info)
{
app_info_h info;