summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorHwankyu Jhun <h.jhun@samsung.com>2016-03-28 07:44:51 +0900
committerHwankyu Jhun <h.jhun@samsung.com>2016-03-31 08:00:37 +0900
commit565ba78bba6242aa89783f4ff1a4173639fc299b (patch)
tree843999fe27ce50d710a6202ee4e67c7ade5ad951
parentfd2ec93d788d1d8f46639678f92ccb27587a9a67 (diff)
downloadapp-manager-accepted/tizen/mobile/20160406.011933.tar.gz
app-manager-accepted/tizen/mobile/20160406.011933.tar.bz2
app-manager-accepted/tizen/mobile/20160406.011933.zip
Change-Id: I6322d2bc9f35cb3f29f84644c57b2d08ca73f79f Signed-off-by: Hwankyu Jhun <h.jhun@samsung.com>
-rwxr-xr-xdoc/appfw_app_manager_doc.h2
-rw-r--r--include/app_context.h20
-rw-r--r--include/app_info.h14
-rw-r--r--include/app_manager.h3
-rw-r--r--include/app_manager_extension.h3
-rw-r--r--src/app_context.c9
-rw-r--r--src/app_info.c5
-rw-r--r--src/app_manager.c7
-rw-r--r--src/app_manager_internal.h5
-rw-r--r--tool/main.c39
10 files changed, 54 insertions, 53 deletions
diff --git a/doc/appfw_app_manager_doc.h b/doc/appfw_app_manager_doc.h
index 76df8ae..5182939 100755
--- a/doc/appfw_app_manager_doc.h
+++ b/doc/appfw_app_manager_doc.h
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2011 Samsung Electronics Co., Ltd All Rights Reserved
+ * Copyright (c) 2011 - 2016 Samsung Electronics Co., Ltd All Rights Reserved
*
* Licensed under the Apache License, Version 2.0 (the License);
* you may not use this file except in compliance with the License.
diff --git a/include/app_context.h b/include/app_context.h
index 821882d..c0e3ae7 100644
--- a/include/app_context.h
+++ b/include/app_context.h
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2011 Samsung Electronics Co., Ltd All Rights Reserved
+ * Copyright (c) 2011 - 2016 Samsung Electronics Co., Ltd All Rights Reserved
*
* Licensed under the Apache License, Version 2.0 (the License);
* you may not use this file except in compliance with the License.
@@ -46,10 +46,9 @@ typedef struct app_context_s *app_context_h;
* @brief Enumeration for Application Context Event.
* @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif
*/
-typedef enum
-{
- APP_CONTEXT_EVENT_LAUNCHED, /**< The application is launched */
- APP_CONTEXT_EVENT_TERMINATED, /**< The application is terminated */
+typedef enum {
+ APP_CONTEXT_EVENT_LAUNCHED, /**< The application is launched */
+ APP_CONTEXT_EVENT_TERMINATED, /**< The application is terminated */
} app_context_event_e;
@@ -58,11 +57,11 @@ typedef enum
* @since_tizen 3.0
*/
typedef enum {
- APP_STATE_UNDEFINED, /**< The undefined state */
- APP_STATE_FOREGROUND, /**< The UI application is running in the foreground. */
- APP_STATE_BACKGROUND, /**< The UI application is running in the background. */
- APP_STATE_SERVICE, /**< The Service application is running. */
- APP_STATE_TERMINATED, /**< The application is terminated. */
+ APP_STATE_UNDEFINED, /**< The undefined state */
+ APP_STATE_FOREGROUND, /**< The UI application is running in the foreground. */
+ APP_STATE_BACKGROUND, /**< The UI application is running in the background. */
+ APP_STATE_SERVICE, /**< The Service application is running. */
+ APP_STATE_TERMINATED, /**< The application is terminated. */
} app_state_e;
@@ -222,3 +221,4 @@ int app_context_clone(app_context_h *clone, app_context_h app_context);
#endif
#endif /* __TIZEN_APPFW_APP_CONTEXT_H */
+
diff --git a/include/app_info.h b/include/app_info.h
index 15b0e9b..db49765 100644
--- a/include/app_info.h
+++ b/include/app_info.h
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2011 Samsung Electronics Co., Ltd All Rights Reserved
+ * Copyright (c) 2011 - 2016 Samsung Electronics Co., Ltd All Rights Reserved
*
* Licensed under the Apache License, Version 2.0 (the License);
* you may not use this file except in compliance with the License.
@@ -110,11 +110,10 @@ typedef bool (*app_info_metadata_cb) (const char *metadata_key, const char *meta
* @brief Enumeration for Application Information Event.
* @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif
*/
-typedef enum
-{
- APP_INFO_EVENT_INSTALLED, /**< The application is newly installed */
- APP_INFO_EVENT_UNINSTALLED, /**< The application is uninstalled */
- APP_INFO_EVENT_UPDATED, /**< The application is updated */
+typedef enum {
+ APP_INFO_EVENT_INSTALLED, /**< The application is newly installed */
+ APP_INFO_EVENT_UNINSTALLED, /**< The application is uninstalled */
+ APP_INFO_EVENT_UPDATED, /**< The application is updated */
} app_info_event_e;
/**
@@ -418,7 +417,7 @@ int app_info_filter_count_appinfo(app_info_filter_h handle, int *count);
* @retval #APP_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter
* @retval #APP_MANAGER_ERROR_IO_ERROR I/O error
*/
-int app_info_filter_foreach_appinfo(app_info_filter_h handle, app_info_filter_cb callback, void * user_data);
+int app_info_filter_foreach_appinfo(app_info_filter_h handle, app_info_filter_cb callback, void *user_data);
/**
* @brief Creates the application's metadata information filter handle from DB.
@@ -488,3 +487,4 @@ int app_info_metadata_filter_foreach(app_info_metadata_filter_h handle, app_info
#endif
#endif /* __TIZEN_APPFW_APP_INFO_H */
+
diff --git a/include/app_manager.h b/include/app_manager.h
index 13de32e..0e17b4c 100644
--- a/include/app_manager.h
+++ b/include/app_manager.h
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2011 Samsung Electronics Co., Ltd All Rights Reserved
+ * Copyright (c) 2011 - 2016 Samsung Electronics Co., Ltd All Rights Reserved
*
* Licensed under the Apache License, Version 2.0 (the License);
* you may not use this file except in compliance with the License.
@@ -357,3 +357,4 @@ int app_manager_get_external_shared_data_path(const char *app_id, char **path);
#endif
#endif /* __TIZEN_APPFW_APP_MANAGER_H */
+
diff --git a/include/app_manager_extension.h b/include/app_manager_extension.h
index afb0a39..9f98b81 100644
--- a/include/app_manager_extension.h
+++ b/include/app_manager_extension.h
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2011 Samsung Electronics Co., Ltd All Rights Reserved
+ * Copyright (c) 2011 - 2016 Samsung Electronics Co., Ltd All Rights Reserved
*
* Licensed under the Apache License, Version 2.0 (the License);
* you may not use this file except in compliance with the License.
@@ -56,3 +56,4 @@ int app_manager_terminate_app(app_context_h app_context);
#endif
#endif /* __TIZEN_APPFW_APP_MANAGER_EXTENSION_H */
+
diff --git a/src/app_context.c b/src/app_context.c
index 7d6878e..f43241e 100644
--- a/src/app_context.c
+++ b/src/app_context.c
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2011 Samsung Electronics Co., Ltd All Rights Reserved
+ * Copyright (c) 2011 - 2016 Samsung Electronics Co., Ltd All Rights Reserved
*
* Licensed under the Apache License, Version 2.0 (the License);
* you may not use this file except in compliance with the License.
@@ -89,7 +89,7 @@ static app_state_e app_context_get_app_status(int status)
static int app_context_foreach_app_context_cb(const aul_app_info *aul_app_context, void *cb_data)
{
- foreach_context_s* foreach_context = cb_data;
+ foreach_context_s *foreach_context = cb_data;
app_context_h app_context;
app_state_e app_state;
bool is_sub_app = false;
@@ -138,7 +138,7 @@ int app_context_foreach_app_context(app_manager_app_context_cb callback, void *u
static int app_context_foreach_running_app_context_cb(const aul_app_info *aul_app_context, void *cb_data)
{
- foreach_context_s* foreach_context = cb_data;
+ foreach_context_s *foreach_context = cb_data;
app_context_h app_context;
app_state_e app_state;
bool is_sub_app = false;
@@ -445,7 +445,7 @@ static bool app_context_load_all_app_context_cb_locked(app_context_h app_context
return true;
}
-static void app_context_pid_table_entry_destroyed_cb(void * data)
+static void app_context_pid_table_entry_destroyed_cb(void *data)
{
app_context_h app_context = data;
@@ -580,3 +580,4 @@ void app_context_unset_event_cb(void)
app_context_unlock_event_cb_context();
}
+
diff --git a/src/app_info.c b/src/app_info.c
index cd86ba3..eda32cf 100644
--- a/src/app_info.c
+++ b/src/app_info.c
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2011 Samsung Electronics Co., Ltd All Rights Reserved
+ * Copyright (c) 2011 - 2016 Samsung Electronics Co., Ltd All Rights Reserved
*
* Licensed under the Apache License, Version 2.0 (the License);
* you may not use this file except in compliance with the License.
@@ -635,7 +635,7 @@ API int app_info_filter_count_appinfo(app_info_filter_h handle, int *count)
return APP_MANAGER_ERROR_NONE;
}
-API int app_info_filter_foreach_appinfo(app_info_filter_h handle, app_info_filter_cb callback, void * user_data)
+API int app_info_filter_foreach_appinfo(app_info_filter_h handle, app_info_filter_cb callback, void *user_data)
{
int retval = 0;
@@ -730,3 +730,4 @@ API int app_info_metadata_filter_foreach(app_info_metadata_filter_h handle, app_
return APP_MANAGER_ERROR_NONE;
}
+
diff --git a/src/app_manager.c b/src/app_manager.c
index 2aaa4e2..8b000a1 100644
--- a/src/app_manager.c
+++ b/src/app_manager.c
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2011 Samsung Electronics Co., Ltd All Rights Reserved
+ * Copyright (c) 2011 - 2016 Samsung Electronics Co., Ltd All Rights Reserved
*
* Licensed under the Apache License, Version 2.0 (the License);
* you may not use this file except in compliance with the License.
@@ -36,7 +36,7 @@
#define SMACK_LABEL_LEN 255
-static const char* app_manager_error_to_string(app_manager_error_e error)
+static const char *app_manager_error_to_string(app_manager_error_e error)
{
switch (error) {
case APP_MANAGER_ERROR_NONE:
@@ -62,7 +62,7 @@ static const char* app_manager_error_to_string(app_manager_error_e error)
}
}
-int app_manager_error(app_manager_error_e error, const char* function, const char *description)
+int app_manager_error(app_manager_error_e error, const char *function, const char *description)
{
if (description)
LOGE("[%s] %s(0x%08x) : %s", function, app_manager_error_to_string(error), error, description);
@@ -429,3 +429,4 @@ API int app_manager_get_external_shared_data_path(const char *app_id, char **pat
return r;
}
+
diff --git a/src/app_manager_internal.h b/src/app_manager_internal.h
index d7185f6..2b8e90c 100644
--- a/src/app_manager_internal.h
+++ b/src/app_manager_internal.h
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2011 Samsung Electronics Co., Ltd All Rights Reserved
+ * Copyright (c) 2011 - 2016 Samsung Electronics Co., Ltd All Rights Reserved
*
* Licensed under the Apache License, Version 2.0 (the License);
* you may not use this file except in compliance with the License.
@@ -38,7 +38,7 @@ extern "C" {
#define PRIVILEGE_PKGMGR_INFO "http://tizen.org/privilege/packagemanager.info"
-int app_manager_error(app_manager_error_e error, const char* function, const char *description);
+int app_manager_error(app_manager_error_e error, const char *function, const char *description);
int app_context_foreach_app_context(app_manager_app_context_cb callback, void *user_data);
@@ -64,3 +64,4 @@ int app_manager_check_privilege(char *privilege);
#endif
#endif /* __TIZEN_APPFW_APP_MANAGER_INTERNAL_H */
+
diff --git a/tool/main.c b/tool/main.c
index 48cb673..9a8ef55 100644
--- a/tool/main.c
+++ b/tool/main.c
@@ -1,19 +1,19 @@
/*
-Copyright (c) 2011 Samsung Electronics Co., Ltd All Rights Reserved
-PROPRIETARY/CONFIDENTIAL
-This software is the confidential and proprietary information of
-SAMSUNG ELECTRONICS ("Confidential Information"). You agree and acknowledge that
-this software is owned by Samsung and you
-shall not disclose such Confidential Information and shall
-use it only in accordance with the terms of the license agreement
-you entered into with SAMSUNG ELECTRONICS. SAMSUNG make no
-representations or warranties about the suitability
-of the software, either express or implied, including but not
-limited to the implied warranties of merchantability, fitness for
-a particular purpose, or non-infringement.
-SAMSUNG shall not be liable for any damages suffered by licensee arising out of or
-related to this software.
-*/
+ * Copyright (c) 2011 Samsung Electronics Co., Ltd All Rights Reserved
+ * PROPRIETARY/CONFIDENTIAL
+ * This software is the confidential and proprietary information of
+ * SAMSUNG ELECTRONICS ("Confidential Information"). You agree and acknowledge that
+ * this software is owned by Samsung and you
+ * shall not disclose such Confidential Information and shall
+ * use it only in accordance with the terms of the license agreement
+ * you entered into with SAMSUNG ELECTRONICS. SAMSUNG make no
+ * representations or warranties about the suitability
+ * of the software, either express or implied, including but not
+ * limited to the implied warranties of merchantability, fitness for
+ * a particular purpose, or non-infringement.
+ * SAMSUNG shall not be liable for any damages suffered by licensee arising out of or
+ * related to this software.
+ */
#include <stdio.h>
#include <stdlib.h>
@@ -25,8 +25,6 @@ related to this software.
#include <app_manager.h>
-
-
static void _print_help(const char *cmd)
{
fprintf(stderr, "Usage:\n");
@@ -38,8 +36,6 @@ static void _print_help(const char *cmd)
fprintf(stderr, "\n");
}
-
-
static int _get_appinfo(const char *app_id)
{
app_info_h app_info;
@@ -81,11 +77,11 @@ static int _get_appinfo(const char *app_id)
return APP_MANAGER_ERROR_NONE;
}
-int main(int argc, char** argv)
+int main(int argc, char **argv)
{
int ret = APP_MANAGER_ERROR_NONE;
- if (2 == argc) {
+ if (argc == 2) {
ret = _get_appinfo(argv[1]);
} else {
_print_help(argv[0]);
@@ -98,4 +94,3 @@ int main(int argc, char** argv)
return EXIT_SUCCESS;
}
-