int app_manager_attach_window_below(const char *parent_appid, const char *child_appid);
/**
+ * @brief Terminates the application without restarting.
+ * @since_tizen 7.0
+ * @privlevel platform
+ * @privilege %http://tizen.org/privilege/appmanager.kill
+ * @param[in] app_context The application context
+ * @return @c 0 on success,
+ * otherwise a negative error value
+ * @retval #APP_MANAGER_ERROR_NONE Successful
+ * @retval #APP_MANAGER_ERROR_PERMISSION_DENIED Permission denied
+ * @retval #APP_MANAGER_IO_ERROR I/O error
+ * @retval #APP_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter
+ * @retval #APP_MANAGER_ERROR_REQUEST_FAILED Internal terminate error
+ */
+int app_manager_terminate_app_without_restarting(app_context_h app_context);
+
+/**
* @}
*/
return APP_MANAGER_ERROR_NONE;
}
+
+API int app_manager_terminate_app_without_restarting(app_context_h app_context)
+{
+ int ret;
+ pid_t pid = -1;
+
+ if (app_context == NULL) {
+ return app_manager_error(APP_MANAGER_ERROR_INVALID_PARAMETER,
+ __FUNCTION__, "Invalid parameter");
+ }
+
+ app_context_get_pid(app_context, &pid);
+
+ ret = aul_terminate_pid_without_restart(pid);
+ if (ret != AUL_R_OK) {
+ return app_manager_error(__aul_error_convert(ret), __FUNCTION__,
+ "Failed to send termination request");
+ }
+
+ return APP_MANAGER_ERROR_NONE;
+}