Skip to content
This repository has been archived by the owner on May 27, 2021. It is now read-only.

Commit

Permalink
Fix "IllegalArgumentException: Span count should be at least 1. Provi…
Browse files Browse the repository at this point in the history
…ded 0"
  • Loading branch information
AndrewJack committed Oct 27, 2015
1 parent 70c4653 commit 69d80a8
Showing 1 changed file with 2 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -89,7 +89,8 @@ private int getSpanCount() {
Display display = getActivity().getWindowManager().getDefaultDisplay();
Point size = new Point();
display.getSize(size);
return size.x / 600;
int i = size.x / 600;
return i > 0 ? i : 1;
}

@Override
Expand Down

0 comments on commit 69d80a8

Please sign in to comment.