Launch sticker-receiver for receiving sticker feature 16/240516/2
authorJihoon Kim <jihoon48.kim@samsung.com>
Fri, 7 Aug 2020 04:53:40 +0000 (13:53 +0900)
committerJihoon Kim <jihoon48.kim@samsung.com>
Fri, 7 Aug 2020 05:58:53 +0000 (14:58 +0900)
Change-Id: I4a0851c30ffdf10917bfec9dd1adf643e6ba80d3
Signed-off-by: Jihoon Kim <jihoon48.kim@samsung.com>
receiver/src/main.cpp
receiver/tizen-manifest.xml

index 783ac2d..a829059 100644 (file)
@@ -214,6 +214,21 @@ static void app_control(app_control_h app_control, void *data)
                 free(uri);
             }
         }
+        else if (strcmp(operation, APP_CONTROL_OPERATION_DEFAULT) == 0) {
+#ifdef VCONFKEY_STICKER_SUPPORTED_FEATURE
+            // Check whether oobe has been done
+            int feature_flag = 0;
+            if (vconf_get_int(VCONFKEY_STICKER_SUPPORTED_FEATURE, &feature_flag) == 0 && feature_flag == 0) {
+                STLOGD("Request to get sticker feature");
+                initialize_sap();
+                request_sticker_feature();
+            }
+            else {
+                if (!is_init_sap())
+                    service_app_exit();
+            }
+#endif
+        }
     }
     else {
         STLOGW("Failed to get operation. error : %d", ret);
index b4889cd..247a220 100644 (file)
@@ -1,7 +1,7 @@
 <?xml version="1.0" encoding="utf-8"?>
 <manifest xmlns="http://tizen.org/ns/packages" api-version="5.5" package="org.tizen.sticker-receiver" version="1.0.60">
         <profile name="wearable" />
-        <service-application appid="org.tizen.sticker-receiver" exec="sticker-receiver" type="capp" multiple="false" taskmanage="false" nodisplay="true" launch_mode="single">
+        <service-application appid="org.tizen.sticker-receiver" exec="sticker-receiver" type="capp" multiple="false" taskmanage="false" nodisplay="true" launch_mode="single" on-boot="true">
             <label>sticker-receiver</label>
             <metadata key="accessory-services-location" value="/res/xml/accessoryservices.xml"/>
             <metadata key="launch-on-attach" value="false"/>