summaryrefslogtreecommitdiffstats
path: root/src/com/cyanogenmod/setupwizard/setup/CMSetupWizardData.java
diff options
context:
space:
mode:
authorRicardo Cerqueira <ricardo@cyngn.com>2015-08-10 13:07:37 +0100
committerRicardo Cerqueira <ricardo@cyngn.com>2015-08-10 13:21:01 +0100
commit649a5ec162a8cc6ef5840ce11fe7e35156d1bdf3 (patch)
tree7fcc3090f89eff0d873bb6425288504b8f9ecdea /src/com/cyanogenmod/setupwizard/setup/CMSetupWizardData.java
parentd587f56e2e04a11271407a127f92d205a018e078 (diff)
downloadpackages_apps_SetupWizard-649a5ec162a8cc6ef5840ce11fe7e35156d1bdf3.zip
packages_apps_SetupWizard-649a5ec162a8cc6ef5840ce11fe7e35156d1bdf3.tar.gz
packages_apps_SetupWizard-649a5ec162a8cc6ef5840ce11fe7e35156d1bdf3.tar.bz2
SetupWizard: Adjust FRP-enforcing logic
* Always pass ALLOW_SKIP to GMS, it's smart enough to know when it can't be applied. * Don't bring up the authentication screen if no-network and canSkip Still CYNGNOS-707 Change-Id: Ia1a81c4443cfd5bc3c3e5fd84758ff0ba2a2a140
Diffstat (limited to 'src/com/cyanogenmod/setupwizard/setup/CMSetupWizardData.java')
-rw-r--r--src/com/cyanogenmod/setupwizard/setup/CMSetupWizardData.java8
1 files changed, 6 insertions, 2 deletions
diff --git a/src/com/cyanogenmod/setupwizard/setup/CMSetupWizardData.java b/src/com/cyanogenmod/setupwizard/setup/CMSetupWizardData.java
index 2fc5729..9d1332d 100644
--- a/src/com/cyanogenmod/setupwizard/setup/CMSetupWizardData.java
+++ b/src/com/cyanogenmod/setupwizard/setup/CMSetupWizardData.java
@@ -64,7 +64,7 @@ public class CMSetupWizardData extends AbstractSetupData {
.setHidden(!isSimInserted() || mMobileDataEnabled));
}
if (SetupWizardUtils.hasGMS(mContext)) {
- pages.add(new GmsAccountPage(mContext, this));
+ pages.add(new GmsAccountPage(mContext, this).setHidden(true));
}
if (!SetupWizardUtils.hasLeanback(mContext)) {
pages.add(new CyanogenServicesPage(mContext, this).setHidden(true));
@@ -109,7 +109,11 @@ public class CMSetupWizardData extends AbstractSetupData {
private void showHideAccountPages() {
boolean isConnected = SetupWizardUtils.isNetworkConnected(mContext);
-
+ GmsAccountPage gmsAccountPage =
+ (GmsAccountPage) getPage(GmsAccountPage.TAG);
+ if (gmsAccountPage != null) {
+ gmsAccountPage.setHidden(!isConnected && gmsAccountPage.canSkip());
+ }
CyanogenServicesPage cyanogenServicesPage =
(CyanogenServicesPage) getPage(CyanogenServicesPage.TAG);
if (cyanogenServicesPage != null) {