update vconf status of charge now 39/14939/2
authorgiyeol.ok <giyeol.ok@samsung.com>
Tue, 14 May 2013 01:28:28 +0000 (10:28 +0900)
committerKrzysztof Sasiak <k.sasiak@samsung.com>
Thu, 16 Jan 2014 10:38:46 +0000 (11:38 +0100)
Change-Id: Ibf5efd18008705052665302fcc1d76fb367636ff
Signed-off-by: giyeol.ok <giyeol.ok@samsung.com>
src/ta/ta-handler.c

index bfa6c8f..3f8d115 100644 (file)
@@ -31,6 +31,7 @@
 static void ta_init(void *data)
 {
        int val, i = 0;
+       int ret;
 
        if (device_get_property(DEVICE_TYPE_EXTCON, PROP_EXTCON_TA_ONLINE, &val) != 0)
                return;
@@ -48,6 +49,10 @@ static void ta_init(void *data)
                vconf_set_int(VCONFKEY_SYSMAN_CHARGER_STATUS,
                                VCONFKEY_SYSMAN_CHARGER_DISCONNECTED);
        }
+       ret = device_get_property(DEVICE_TYPE_POWER,
+               PROP_POWER_CHARGE_NOW, &val);
+       if (ret == 0)
+               vconf_set_int(VCONFKEY_SYSMAN_BATTERY_CHARGE_NOW, val);
 }
 
 const struct device_ops ta_device_ops = {