adb shell settings put secure user_setup_complete 1
adb shell settings put global device_provisioned 1
adb reboot
user_setu_complete
device_provisioned
https://blog.csdn.net/u010672559/article/details/89509762
https://www.cnblogs.com/programandriod/p/13868589.html
import android.database.ContentObserver;
mContext.getContentResolver().registerContentObserver(Settings.System.getUriFor("power_save_mode_state"), false, mXXXObserver);
private ContentObserver mXXXObserver=new ContentObserver(new Handler()) {
public void onChange(boolean selfChange) {
};
};
mContext.getContentResolver().unregisterContentObserver(mXXXObserver);
getContentResolver().registerContentObserver(Settings.System.getUriFor(Settings.Global.DEVICE_PROVISIONED),true, null)//注册监听