diff options
author | Sunny Goyal <sunnygoyal@google.com> | 2015-03-02 19:33:35 +0000 |
---|---|---|
committer | Android (Google) Code Review <android-gerrit@google.com> | 2015-03-02 19:33:35 +0000 |
commit | 5b437d8957c21b5fab42d3540db39da09378cfd7 (patch) | |
tree | eee3aa99415416f07fb108dffc5a04033d0ecb13 /src/com/android/launcher3/AppsCustomizePagedView.java | |
parent | 53fca52d3b2db08a35ab7af6f9bc52f6cd8f28a4 (diff) | |
parent | c9acdd51c40c1b397adae6ba62c4acd01914b473 (diff) | |
download | android_packages_apps_Trebuchet-5b437d8957c21b5fab42d3540db39da09378cfd7.tar.gz android_packages_apps_Trebuchet-5b437d8957c21b5fab42d3540db39da09378cfd7.tar.bz2 android_packages_apps_Trebuchet-5b437d8957c21b5fab42d3540db39da09378cfd7.zip |
Merge "Removed disableAllApps flag" into ub-launcher3-burnaby
Diffstat (limited to 'src/com/android/launcher3/AppsCustomizePagedView.java')
-rw-r--r-- | src/com/android/launcher3/AppsCustomizePagedView.java | 30 |
1 files changed, 11 insertions, 19 deletions
diff --git a/src/com/android/launcher3/AppsCustomizePagedView.java b/src/com/android/launcher3/AppsCustomizePagedView.java index 875cd2108..c1aa19ae7 100644 --- a/src/com/android/launcher3/AppsCustomizePagedView.java +++ b/src/com/android/launcher3/AppsCustomizePagedView.java @@ -358,7 +358,7 @@ public class AppsCustomizePagedView extends PagedViewWithDraggableItems implemen super.onLayout(changed, l, t, r, b); if (!isDataReady()) { - if ((LauncherAppState.isDisableAllApps() || !mApps.isEmpty()) && !mWidgets.isEmpty()) { + if ((!mApps.isEmpty()) && !mWidgets.isEmpty()) { post(new Runnable() { // This code triggers requestLayout so must be posted outside of the // layout pass. @@ -1402,11 +1402,9 @@ public class AppsCustomizePagedView extends PagedViewWithDraggableItems implemen } public void setApps(ArrayList<AppInfo> list) { - if (!LauncherAppState.isDisableAllApps()) { - mApps = list; - Collections.sort(mApps, LauncherModel.getAppNameComparator()); - updatePageCountsAndInvalidateData(); - } + mApps = list; + Collections.sort(mApps, LauncherModel.getAppNameComparator()); + updatePageCountsAndInvalidateData(); } public ArrayList<AppInfo> getApps() { @@ -1425,10 +1423,8 @@ public class AppsCustomizePagedView extends PagedViewWithDraggableItems implemen } } public void addApps(ArrayList<AppInfo> list) { - if (!LauncherAppState.isDisableAllApps()) { - addAppsWithoutInvalidate(list); - updatePageCountsAndInvalidateData(); - } + addAppsWithoutInvalidate(list); + updatePageCountsAndInvalidateData(); } private int findAppByComponent(List<AppInfo> list, AppInfo item) { ComponentName removeComponent = item.intent.getComponent(); @@ -1454,20 +1450,16 @@ public class AppsCustomizePagedView extends PagedViewWithDraggableItems implemen } } public void removeApps(ArrayList<AppInfo> appInfos) { - if (!LauncherAppState.isDisableAllApps()) { - removeAppsWithoutInvalidate(appInfos); - updatePageCountsAndInvalidateData(); - } + removeAppsWithoutInvalidate(appInfos); + updatePageCountsAndInvalidateData(); } public void updateApps(ArrayList<AppInfo> list) { // We remove and re-add the updated applications list because it's properties may have // changed (ie. the title), and this will ensure that the items will be in their proper // place in the list. - if (!LauncherAppState.isDisableAllApps()) { - removeAppsWithoutInvalidate(list); - addAppsWithoutInvalidate(list); - updatePageCountsAndInvalidateData(); - } + removeAppsWithoutInvalidate(list); + addAppsWithoutInvalidate(list); + updatePageCountsAndInvalidateData(); } public void reset() { |