Commit 586efd0e authored by Philippe De Swert's avatar Philippe De Swert

Add product key for android gadget

Signed-off-by: default avatarPhilippe De Swert <philippe.deswert@jollamobile.com>
parent 5a3bcd76
......@@ -60,5 +60,11 @@ void android_init_values(void)
write_to_file("/sys/class/android_usb/android0/idVendor", text);
g_free((char *)text);
}
text = get_android_product();
if(text)
{
write_to_file("/sys/class/android_usb/android0/iProduct", text);
g_free((char *)text);
}
}
......@@ -509,6 +509,11 @@ const char * get_android_vendor(void)
return(get_conf_string(ANDROID_ENTRY, ANDROID_VENDOR_KEY));
}
const char * get_android_product(void)
{
return(get_conf_string(ANDROID_ENTRY, ANDROID_PRODUCT_KEY));
}
int check_android_section(void)
{
GKeyFile *settingsfile;
......
......@@ -53,6 +53,7 @@
#define ANDROID_ENTRY "android"
#define ANDROID_MANUFACTURER_KEY "manufacturer"
#define ANDROID_VENDOR_KEY "vendor"
#define ANDROID_PRODUCT_KEY "product"
const char * find_mounts(void);
int find_sync(void);
......@@ -83,6 +84,7 @@ const char * get_soft_connect_path(void);
const char * get_android_manufacturer(void);
const char * get_android_vendor(void);
const char * get_android_product(void);
int check_android_section(void);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment