Bug fix for unable to close webapp from Task switch.
authorTaejeong Lee <taejeong.lee@samsung.com>
Wed, 2 Jan 2013 07:35:03 +0000 (16:35 +0900)
committerGerrit Code Review <gerrit2@kim11>
Wed, 2 Jan 2013 11:56:13 +0000 (20:56 +0900)
[Issue#] N/A
[Problem] Bug fix for unable to close webapp from Task switch.
[Cause] AUL_DBUS_SIGNAL_INTERFACE value was incorrect.
[Solution] N/A

Change-Id: Ic72e700a798ef9a7a977aedd7095c59e20fa18fe

src/wrt-launchpad-daemon/include/app_signal.h
src/wrt-launchpad-daemon/include/menu_db_util.h
src/wrt-launchpad-daemon/include/simple_util.h
src/wrt-launchpad-daemon/launchpad_src/launchpad.c

index 7987916..0082437 100644 (file)
@@ -23,7 +23,7 @@
 #include <dbus/dbus-glib-lowlevel.h>
 
 #define AUL_DBUS_PATH "/aul/dbus_handler"
-#define AUL_DBUS_SIGNAL_INTERFACE "com.samsung.aul.signal"
+#define AUL_DBUS_SIGNAL_INTERFACE "org.tizen.aul.signal"
 #define AUL_DBUS_APPDEAD_SIGNAL        "app_dead"
 #define AUL_DBUS_APPLAUNCH_SIGNAL      "app_launch"
 
index 8af4181..a31bb5f 100644 (file)
@@ -42,6 +42,7 @@ typedef struct {
        char *app_path;         /* exec */
        char *original_app_path;        /* exec */
        char *pkg_type;         /* x_slp_packagetype */
+       char *hwacc;            /* hwacceleration */
 } app_info_from_db;
 
 static inline char *_get_pkgname(app_info_from_db *menu_info)
@@ -99,6 +100,8 @@ static inline void _free_app_info_from_db(app_info_from_db *menu_info)
                        free(menu_info->app_path);
                if (menu_info->original_app_path != NULL)
                        free(menu_info->original_app_path);
+               if (menu_info->hwacc != NULL)
+                       free(menu_info->hwacc);
                free(menu_info);
        }
 }
@@ -124,7 +127,7 @@ static inline app_info_from_db *_get_app_info_from_db_by_pkgname(
 
        ret = ail_appinfo_get_str(handle, AIL_PROP_PACKAGE_STR, &str);
        if (str) {
-               menu_info->pkg_name = strdup(str);
+               menu_info->pkg_name = strdup(str);      
                str = NULL;
        }
 
@@ -142,7 +145,7 @@ static inline app_info_from_db *_get_app_info_from_db_by_pkgname(
                menu_info->pkg_type = strdup(str);
                str = NULL;
        }
-
+       
        ret = ail_destroy_appinfo(handle);
        if (ret != AIL_ERROR_OK) {
                _E("ail_destroy_appinfo failed");
@@ -164,8 +167,8 @@ static inline ail_cb_ret_e __appinfo_func(const ail_appinfo_h appinfo, void *use
        ail_appinfo_get_str(appinfo, AIL_PROP_PACKAGE_STR, &package);
 
        menu_info->pkg_name = strdup(package);
-
-       return AIL_CB_RET_CANCEL;       /*return AIL_CB_RET_CONTINUE;*/
+       
+       return AIL_CB_RET_CANCEL;       /*return AIL_CB_RET_CONTINUE;*/ 
 }
 
 static inline app_info_from_db *_get_app_info_from_db_by_apppath(
@@ -175,7 +178,7 @@ static inline app_info_from_db *_get_app_info_from_db_by_apppath(
        ail_filter_h filter;
        ail_error_e ret;
        int count;
-
+       
        if (apppath == NULL)
                return NULL;
 
@@ -216,6 +219,6 @@ static inline app_info_from_db *_get_app_info_from_db_by_apppath(
        menu_info->original_app_path = strdup(apppath);
 
        return menu_info;
-
+       
 }
 
index 92e75f4..168078d 100644 (file)
 
 #ifdef LAUNCHPAD_LOG
 #undef LOG_TAG
-#define LOG_TAG "AULD"
+#define LOG_TAG "AUL_PAD"
 #else
 #undef LOG_TAG
 #define LOG_TAG "AUL"
 #endif
 #ifdef AMD_LOG
 #undef LOG_TAG
-#define LOG_TAG "AMD"
+#define LOG_TAG "AUL_AMD"
 #endif
 
 
 #define MAX_LOCAL_BUFSZ 128
 #define MAX_PID_STR_BUFSZ 20
 
-#define _E(fmt, arg...) LOGE("[%s,%d] "fmt, __FUNCTION__, __LINE__, ##arg)
-#define _D(fmt, arg...) LOGD("[%s,%d] "fmt, __FUNCTION__, __LINE__, ##arg)
+#define _E(fmt, arg...) LOGE(fmt, ##arg)
+#define _D(fmt, arg...) LOGD(fmt, ##arg)
 
 #define retvm_if(expr, val, fmt, arg...) do { \
        if (expr) { \
index 6785d09..739487b 100644 (file)
@@ -166,6 +166,8 @@ _static_ void __set_env(app_info_from_db * menu_info, bundle * kb)
                        __set_sdk_env(menu_info, (char *)str);
                }
        }
+       if (menu_info->hwacc != NULL)
+               setenv("HWACC", menu_info->hwacc, 1);
 }
 
 _static_ int __prepare_exec(const char *pkg_name,
@@ -424,6 +426,7 @@ _static_ void __modify_bundle(bundle * kb, int caller_pid,
        bundle_del(kb, AUL_K_PKG_NAME);
        bundle_del(kb, AUL_K_EXEC);
        bundle_del(kb, AUL_K_PACKAGETYPE);
+       bundle_del(kb, AUL_K_HWACC);
 
        /* Parse app_path to retrieve default bundle*/
        if (cmd == APP_START || cmd == APP_START_RES || cmd == APP_OPEN || cmd == APP_RESUME) {
@@ -662,6 +665,7 @@ static app_info_from_db *_get_app_info_from_bundle_by_pkgname(
        if (menu_info->app_path != NULL)
                menu_info->original_app_path = strdup(menu_info->app_path);
        menu_info->pkg_type = strdup(bundle_get_val(kb, AUL_K_PACKAGETYPE));
+       menu_info->hwacc = strdup(bundle_get_val(kb, AUL_K_HWACC));
 
        if (!_get_app_path(menu_info)) {
                _free_app_info_from_db(menu_info);