Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in / Register
Toggle navigation
Menu
Open sidebar
e
os
android_packages_apps_SetupWizard
Commits
72364176
Commit
72364176
authored
Nov 20, 2018
by
Amit Kumar
Browse files
Active OpenWeatherMapProvider by default
Change-Id: Ib54c6c4c0f9524911876422b8f2d4c266c7491c5
parent
2d0cd922
Changes
1
Show whitespace changes
Inline
Side-by-side
src/com/cyanogenmod/setupwizard/FinishActivity.java
View file @
72364176
...
@@ -65,6 +65,13 @@ public class FinishActivity extends BaseSetupWizardActivity {
...
@@ -65,6 +65,13 @@ public class FinishActivity extends BaseSetupWizardActivity {
private
volatile
boolean
mIsFinishing
=
false
;
private
volatile
boolean
mIsFinishing
=
false
;
private
boolean
hasError
=
false
;
// Component name of default weather provider.
private
static
final
String
OWM
=
"org.lineageos.openweathermapprovider/org.lineageos.openweathermapprovider"
+
".OpenWeatherMapProviderService"
;
@Override
@Override
protected
void
onCreate
(
Bundle
savedInstanceState
)
{
protected
void
onCreate
(
Bundle
savedInstanceState
)
{
super
.
onCreate
(
savedInstanceState
);
super
.
onCreate
(
savedInstanceState
);
...
@@ -184,6 +191,7 @@ public class FinishActivity extends BaseSetupWizardActivity {
...
@@ -184,6 +191,7 @@ public class FinishActivity extends BaseSetupWizardActivity {
if
(
mEnableAccessibilityController
!=
null
)
{
if
(
mEnableAccessibilityController
!=
null
)
{
mEnableAccessibilityController
.
onDestroy
();
mEnableAccessibilityController
.
onDestroy
();
}
}
setupWeatherProvider
();
handlePrivacyGuard
(
mSetupWizardApp
);
handlePrivacyGuard
(
mSetupWizardApp
);
handleEnableMetrics
(
mSetupWizardApp
);
handleEnableMetrics
(
mSetupWizardApp
);
handleNavKeys
(
mSetupWizardApp
);
handleNavKeys
(
mSetupWizardApp
);
...
@@ -196,6 +204,11 @@ public class FinishActivity extends BaseSetupWizardActivity {
...
@@ -196,6 +204,11 @@ public class FinishActivity extends BaseSetupWizardActivity {
startActivityForResult
(
intent
,
NEXT_REQUEST
);
startActivityForResult
(
intent
,
NEXT_REQUEST
);
}
}
private
void
setupWeatherProvider
()
{
LineageSettings
.
Secure
.
putString
(
getContentResolver
(),
LineageSettings
.
Secure
.
WEATHER_PROVIDER_SERVICE
,
OWM
);
}
private
static
void
handleEnableMetrics
(
SetupWizardApp
setupWizardApp
)
{
private
static
void
handleEnableMetrics
(
SetupWizardApp
setupWizardApp
)
{
CMSettings
.
Secure
.
putInt
(
setupWizardApp
.
getContentResolver
(),
CMSettings
.
Secure
.
putInt
(
setupWizardApp
.
getContentResolver
(),
CMSettings
.
Secure
.
STATS_COLLECTION
,
0
);
CMSettings
.
Secure
.
STATS_COLLECTION
,
0
);
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment