Pre-setup restrictions DO NOT MERGE am: e6ad6e866b

am: 2d21d1b9cf

Change-Id: I1fc62827de765434ac88a7cb75d63febb074b565
This commit is contained in:
Jason Monk
2016-07-15 14:03:03 +00:00
committed by android-build-merger
3 changed files with 18 additions and 0 deletions

View File

@@ -45,6 +45,7 @@ import android.preference.Preference.OnPreferenceClickListener;
import android.preference.PreferenceGroup;
import android.preference.PreferenceScreen;
import android.provider.Settings;
import android.provider.Settings.Global;
import android.provider.Settings.Secure;
import android.util.Log;
import android.util.SparseArray;
@@ -229,6 +230,11 @@ public class UserSettings extends SettingsPreferenceFragment
filter.addAction(Intent.ACTION_USER_INFO_CHANGED);
context.registerReceiverAsUser(mUserChangeReceiver, UserHandle.ALL, filter, null,
mHandler);
if (Global.getInt(getContext().getContentResolver(), Global.DEVICE_PROVISIONED, 0) == 0) {
getActivity().finish();
return;
}
}
@Override