Limiting number of predictions on phones.

This commit is contained in:
Winson Chung
2015-05-14 13:15:29 -07:00
parent a0abe2661e
commit c2af7f9175
+1 -1
View File
@@ -443,7 +443,7 @@ public class DeviceProfile {
int availableAppsWidthPx = (containerWidth > 0) ? containerWidth : availableWidthPx;
int numAppsCols = (availableAppsWidthPx - appsViewLeftMarginPx) /
(allAppsCellWidthPx + 2 * allAppsCellPaddingPx);
int numPredictiveAppCols = Math.max(numColumns, numAppsCols);
int numPredictiveAppCols = isPhone() ? 4 : numAppsCols;
if ((numAppsCols != appsViewNumCols) ||
(numPredictiveAppCols != appsViewNumPredictiveCols)) {
appsViewNumCols = numAppsCols;