i have simple if statement check determine if gps turned on on app.
this works on emulator, when installed on actual device instead of 'location & security' menu being loaded called intent, loading agps option. menu not allow me turn gps on , have manually naviagte 'location & security' menu.
this alertdialog builder code. shown using intent call 'action_location_source_settings'.
alertdialog.setpositivebutton("settings", new dialoginterface.onclicklistener() { public void onclick(dialoginterface dialog, int which) { intent intent = new intent( settings.action_location_source_settings); startactivity(intent); } });
to highlight issue further ill use following screenshots:
this screen want load through intent:
the menu being loaded:
how enable intent load first menu instead of second?
Comments
Post a Comment