Add a new API to attach window below parent window 50/261550/2
authorHwankyu Jhun <h.jhun@samsung.com>
Wed, 21 Jul 2021 05:55:20 +0000 (14:55 +0900)
committerHwankyu Jhun <h.jhun@samsung.com>
Wed, 21 Jul 2021 06:04:32 +0000 (15:04 +0900)
The function attaches the window of the child application below
the window of the parent application.

Adds:
 - app_manager_attach_window_below()

Requires:
 - https://review.tizen.org/gerrit/#/c/platform/core/appfw/aul-1/+/261414/
 - https://review.tizen.org/gerrit/#/c/platform/core/appfw/amd/+/261432/

Change-Id: I91006738a7e3d9dfd16686258e29bc766a2af872
Signed-off-by: Hwankyu Jhun <h.jhun@samsung.com>
include/app_manager_extension.h
src/app_manager.c

index 098eab4..82a40fc 100644 (file)
@@ -231,6 +231,23 @@ int app_manager_add_app_group(int win_id);
 int app_manager_remove_app_group(int win_id);
 
 /**
+ * @brief  Attaches the window of the child application below the window of the parent application.
+ * @since_tizen 6.5
+ * @remarks This function is only available for platform level signed applications.
+ * @param[in]   parent_app_id The ID of the parent application
+ * @param[in]   child_app_id  The ID of the child applicatio
+ * @return      @c 0 on success,
+ *              otherwise a negative error value
+ * @retval  #APP_MANAGER_ERROR_NONE               Successful
+ * @retval  #APP_MANAGER_ERROR_INVALID_PARAMETER  Invalid parameter
+ * @retval  #APP_MANAGER_ERROR_IO_ERROR           I/O error
+ * @retval  #APP_MANAGER_ERROR_OUT_OF_MEMORY      Out of memory
+ * @retval  #APP_MANAGER_ERROR_NO_SUCH_APP        No such application
+ * @retval  #APP_MANAGER_ERROR_PERMISSION_DENIED  Permission denied
+ */
+int app_manager_attach_window_below(const char *parent_appid, const char *child_appid);
+
+/**
  * @}
  */
 
index 8956f81..1ef0262 100644 (file)
@@ -716,3 +716,14 @@ API int app_manager_remove_app_group(int win_id)
 
        return APP_MANAGER_ERROR_NONE;
 }
+
+API int app_manager_attach_window_below(const char *parent_appid, const char *child_appid)
+{
+       int ret;
+
+       ret = aul_window_attach_below(parent_appid, child_appid);
+       if (ret != AUL_R_OK)
+               return app_manager_error(__aul_error_convert(ret), __FUNCTION__, NULL);
+
+       return APP_MANAGER_ERROR_NONE;
+}