Created
February 7, 2011 10:40
-
-
Save nickfox/814231 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// launches the settings screen that lets user turn on gps radio | |
private void launchGPSOptions() { | |
final ComponentName toLaunch = new ComponentName("com.android.settings","com.android.settings.SecuritySettings"); | |
final Intent intent = new Intent(Settings.ACTION_LOCATION_SOURCE_SETTINGS); | |
intent.addCategory(Intent.CATEGORY_LAUNCHER); | |
intent.setComponent(toLaunch); | |
intent.setFlags(Intent.FLAG_ACTIVITY_NEW_TASK); | |
startActivityForResult(intent, 0); | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment