+ug-setting-bluetooth-efl (0.2.117) unstable; urgency=low
+
+ * Upload the package
+ * Git: magnolia/apps/home/ug-bluetooth-efl
+ * Tag: ug-setting-bluetooth-efl_0.2.117
+
+ -- DoHyun Pyun <dh79.pyun@samsung.com> Wed, 12 Sep 2012 10:54:14 +0900
+
ug-setting-bluetooth-efl (0.2.116) unstable; urgency=low
* Upload the package
void _bt_util_set_list_disabled(Evas_Object *genlist, Eina_Bool disable);
+void _bt_util_set_phone_name(void);
+
int _bt_util_get_phone_name(char *phone_name, int size);
int _bt_util_get_timeout_string(int timeout, char *buf, int size);
Name: ug-bluetooth-efl
Summary: UI gadget about the bluetooth
-Version: 0.2.116
+Version: 0.2.117
Release: 1
Group: TO_BE/FILLED_IN
License: TO BE FILLED IN
}
}
+ _bt_util_set_phone_name();
+
elm_object_item_disabled_set(ugd->visible_item, EINA_FALSE);
elm_genlist_item_update(ugd->status_item);
elm_genlist_item_update(ugd->visible_item);
return TRUE;
}
+void _bt_util_set_phone_name(void)
+{
+ char *phone_name = NULL;
+ char *ptr = NULL;
+
+ phone_name = vconf_get_str(VCONFKEY_SETAPPL_DEVICE_NAME_STR);
+ if (phone_name && strlen(phone_name) != 0) {
+ if (!g_utf8_validate(phone_name, -1, (const char **)&ptr))
+ *ptr = '\0';
+
+ bt_adapter_set_name(phone_name);
+ }
+}
+
int _bt_util_get_phone_name(char *phone_name, int size)
{
FN_START;
FN_START;
service_h service = NULL;
+ char *dev_name = NULL;
+ char phone_name[BT_DEVICE_NAME_LENGTH_MAX + 1];
bool status = false;
bt_adapter_state_e bt_state = BT_ADAPTER_DISABLED;
bt_adapter_visibility_mode_e mode =
ugd->op_status = BT_ACTIVATED;
+ /* Get adapter name from bluez */
+ bt_adapter_get_name(&dev_name);
+
+ /* Get phone name from vconf */
+ _bt_util_get_phone_name(phone_name, BT_DEVICE_NAME_LENGTH_MAX);
+
+ if (g_strcmp0(dev_name, phone_name) != 0) {
+ _bt_util_set_phone_name();
+ }
+
+ g_free(dev_name);
+
if(bt_adapter_get_visibility(&mode) != BT_ERROR_NONE)
BT_DBG("bt_adapter_get_visibility() failed.");