From ae6c2117c3e24a0cde012f4f205636b8de571003 Mon Sep 17 00:00:00 2001 From: Zhe Lu Date: Fri, 30 May 2014 05:30:58 -0400 Subject: [PATCH] Add updateEmptyStatus() in setAdapter() method The `setAdapter(ListAdapter adapter)` method should also update empty status, otherwise if it is called later, the items won't be shown as the StaggeredGridView is in `Visibility.GONE`. --- .../src/main/java/com/etsy/android/grid/ExtendableListView.java | 1 + 1 file changed, 1 insertion(+) diff --git a/library/src/main/java/com/etsy/android/grid/ExtendableListView.java b/library/src/main/java/com/etsy/android/grid/ExtendableListView.java index 280ab43..1a82d2a 100644 --- a/library/src/main/java/com/etsy/android/grid/ExtendableListView.java +++ b/library/src/main/java/com/etsy/android/grid/ExtendableListView.java @@ -272,6 +272,7 @@ public void setAdapter(final ListAdapter adapter) { mRecycleBin.setViewTypeCount(mAdapter.getViewTypeCount()); } + updateEmptyStatus(); requestLayout(); }