am 35ae2183: am 428de84e: Merge "Workaround for the issue where a layout is not being triggered when rotating the screen while customizing. (3329988)" into honeycomb
* commit '35ae2183787921eab83f0958d129a98f09db8027':
Workaround for the issue where a layout is not being triggered when rotating the screen while customizing. (3329988)
diff --git a/src/com/android/launcher2/Launcher.java b/src/com/android/launcher2/Launcher.java
index f3208d0..3777410 100644
--- a/src/com/android/launcher2/Launcher.java
+++ b/src/com/android/launcher2/Launcher.java
@@ -3476,6 +3476,15 @@
mSavedInstanceState = null;
}
+ // Workaround a bug that occurs when rotating the device while the customization mode is
+ // open, we trigger a new layout on all the CellLayout children.
+ if (LauncherApplication.isScreenXLarge() && (mState == State.CUSTOMIZE)) {
+ final int childCount = mWorkspace.getChildCount();
+ for (int i = 0; i < childCount; ++i) {
+ mWorkspace.getChildAt(i).requestLayout();
+ }
+ }
+
mWorkspaceLoading = false;
}