diff options
author | cretin45 <cretin45@gmail.com> | 2015-02-17 17:09:32 -0800 |
---|---|---|
committer | cretin45 <cretin45@gmail.com> | 2015-02-17 17:09:32 -0800 |
commit | 79840ecb4e4bfd5093746be41498cfcdc9254509 (patch) | |
tree | f147777afb4781127922e32c29326f8c952258fa /src/com/cyanogenmod/setupwizard/ui/SetupWizardActivity.java | |
parent | 77c129f8b940532298d9c3cb8ae72d051ad3ed74 (diff) | |
download | packages_apps_SetupWizard-79840ecb4e4bfd5093746be41498cfcdc9254509.zip packages_apps_SetupWizard-79840ecb4e4bfd5093746be41498cfcdc9254509.tar.gz packages_apps_SetupWizard-79840ecb4e4bfd5093746be41498cfcdc9254509.tar.bz2 |
SetupWizard: Fix scenario where GMS setup disables its components
Change-Id: Ia8edd39645f83625ff06fb61903b672b774257d6
Diffstat (limited to 'src/com/cyanogenmod/setupwizard/ui/SetupWizardActivity.java')
-rw-r--r-- | src/com/cyanogenmod/setupwizard/ui/SetupWizardActivity.java | 12 |
1 files changed, 8 insertions, 4 deletions
diff --git a/src/com/cyanogenmod/setupwizard/ui/SetupWizardActivity.java b/src/com/cyanogenmod/setupwizard/ui/SetupWizardActivity.java index 98be972..bded6ff 100644 --- a/src/com/cyanogenmod/setupwizard/ui/SetupWizardActivity.java +++ b/src/com/cyanogenmod/setupwizard/ui/SetupWizardActivity.java @@ -18,7 +18,6 @@ package com.cyanogenmod.setupwizard.ui; import android.animation.Animator; import android.app.Activity; -import android.app.AppGlobals; import android.app.WallpaperManager; import android.content.Intent; import android.content.res.Resources; @@ -305,18 +304,23 @@ public class SetupWizardActivity extends Activity implements SetupDataCallbacks } private void finishSetup() { + SetupWizardApp setupWizardApp = (SetupWizardApp)getApplication(); if (!mIsGuestUser) { - getApplication().sendBroadcastAsUser(new Intent(SetupWizardApp.ACTION_FINISHED), + setupWizardApp.sendBroadcastAsUser(new Intent(SetupWizardApp.ACTION_FINISHED), UserHandle.getCallingUserHandle()); } mSetupData.finishPages(); Settings.Global.putInt(getContentResolver(), Settings.Global.DEVICE_PROVISIONED, 1); Settings.Secure.putInt(getContentResolver(), Settings.Secure.USER_SETUP_COMPLETE, 1); - ((SetupWizardApp)AppGlobals.getInitialApplication()).enableStatusBar(); + setupWizardApp.enableStatusBar(); finish(); if (mEnableAccessibilityController != null) { mEnableAccessibilityController.onDestroy(); } - SetupWizardUtils.disableSetupWizards(this); + SetupWizardUtils.disableGMSSetupWizard(this); + SetupWizardUtils.disableSetupWizard(this); + Intent intent = new Intent(Intent.ACTION_MAIN); + intent.addCategory(Intent.CATEGORY_HOME); + startActivity(intent); } } |