Merge "Calling recreate() instead of finish() so that the activity life cycle is handled properly" into ub-launcher3-dorval-polish

am: 36faf14d34

Change-Id: I52c292c8442d7100b6f72cbc503715dba663a305
This commit is contained in:
Sunny Goyal
2017-05-23 16:49:09 +00:00
committed by android-build-merger
+2 -3
View File
@@ -4140,9 +4140,8 @@ public class Launcher extends BaseActivity
public void onSharedPreferenceChanged(
SharedPreferences sharedPreferences, String key) {
if (Utilities.ALLOW_ROTATION_PREFERENCE_KEY.equals(key)) {
// Finish this instance of the activity. When the activity is recreated,
// it will initialize the rotation preference again.
finish();
// Recreate the activity so that it initializes the rotation preference again.
recreate();
}
}
}