Do not rebind when when deviceProfile has not changed
am: c8502c1df5
Change-Id: I0534a547468601a099899b6e05aeaea148a68b42
This commit is contained in:
@@ -461,6 +461,7 @@ public class Launcher extends BaseDraggingActivity implements LauncherExterns,
|
||||
private void onIdpChanged(InvariantDeviceProfile idp) {
|
||||
mUserEventDispatcher = null;
|
||||
|
||||
DeviceProfile oldWallpaperProfile = getWallpaperDeviceProfile();
|
||||
initDeviceProfile(idp);
|
||||
dispatchDeviceProfileChanged();
|
||||
reapplyUi();
|
||||
@@ -469,8 +470,9 @@ public class Launcher extends BaseDraggingActivity implements LauncherExterns,
|
||||
// Calling onSaveInstanceState ensures that static cache used by listWidgets is
|
||||
// initialized properly.
|
||||
onSaveInstanceState(new Bundle());
|
||||
// TODO: We can probably avoid rebind when only screen size changed.
|
||||
rebindModel();
|
||||
if (oldWallpaperProfile != getWallpaperDeviceProfile()) {
|
||||
rebindModel();
|
||||
}
|
||||
}
|
||||
|
||||
public void onAssistantVisibilityChanged(float visibility) {
|
||||
|
||||
Reference in New Issue
Block a user