Commit 42487734 authored by phdeswer's avatar phdeswer

- Fix missing charging only mode in usb modes query

- Update the usb-moded dbus config so the supported modes can be queried by a normal user
Signed-off-by: phdeswer's avatarPhilippe De Swert <philippedeswert@gmail.com>
parent ae8bf3d7
......@@ -16,6 +16,9 @@
<allow send_destination="com.meego.usb_moded"
send_interface="com.meego.usb_moded" send_member="set_config"/>
<deny own="com.meego.usb_moded"/>
<allow send_destination="com.meego.usb_moded"
send_interface="com.meego.usb_moded" send_member="get_modes"/>
<deny own="com.meego.usb_moded"/>
</policy>
</busconfig>
......@@ -338,11 +338,6 @@ gchar *get_mode_list(void)
modelist_str = g_string_new(NULL);
#ifdef N900
asprintf(&modelist_str->str, "%s, %s, %s, %s, %s", MODE_MASS_STORAGE, MODE_OVI_SUITE, MODE_CHARGING, MODE_DEVELOPER, MODE_MTP);
#else
asprintf(&modelist_str->str, "%s, %s, %s, %s", MODE_MASS_STORAGE, MODE_CHARGING, MODE_DEVELOPER, MODE_MTP);
#endif /* N900 */
{
/* check dynamic modes */
if(modelist)
......@@ -357,6 +352,8 @@ gchar *get_mode_list(void)
}
}
}
/* end with charging mode */
g_string_append(modelist_str, MODE_CHARGING);
return(g_string_free(modelist_str, FALSE));
}
......
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