parse-community / ParseUI-Android

ParseUI contains user interface libraries for building apps with the Parse Android SDK.
Other
592 stars 324 forks source link

ParseQueryAdapter can't be used with Spinner above SDK version 19 #95

Open gwenger opened 8 years ago

gwenger commented 8 years ago

Above SDK 19, Spinners seem to require a view type count of 1. As far as I can tell, only one view type will ever be returned if paginationEnabled is set to false, so I modified the getViewTypeCount method to return 2 if paginationEnabled is true, and 1 otherwise. This seems to work so far for spinners without the need to override the class elsewhere.

grantland commented 8 years ago

returning 1 from getViewTypeCount() if paginationEnabled is false seems like a good workaround for this.