Fixes a bug when using the prediction row view and changing screen orientation.

Bug: 68713881
Change-Id: I9740eee8425d42af87c8c788aefff9a99ae48d2f
This commit is contained in:
Mario Bertschler
2017-11-28 13:34:20 -08:00
parent 0c2d9b0f3e
commit 44607301e2
2 changed files with 7 additions and 1 deletions
@@ -543,6 +543,9 @@ public class AllAppsContainerView extends RelativeLayout implements DragSource,
}
private void setupHeader() {
if (mFloatingHeaderHandler == null) {
return;
}
mHeader.setVisibility(View.VISIBLE);
int contentHeight = mLauncher.getDeviceProfile().allAppsCellHeightPx;
if (!mUsingTabs) {
@@ -68,7 +68,10 @@ public class PredictionRowView extends LinearLayout {
* Sets the number of apps per row.
*/
public void setNumAppsPerRow(int numPredictedAppsPerRow) {
mNumPredictedAppsPerRow = numPredictedAppsPerRow;
if (mNumPredictedAppsPerRow != numPredictedAppsPerRow) {
mNumPredictedAppsPerRow = numPredictedAppsPerRow;
onAppsUpdated();
}
}
/**