enyojs/enyo — pull request #942 by graynorton (2014-11-24 20:58:41+00:00)
Title: BHV-18217: Avoid generating invalid page index for one-page list

We recently updated the logic in VerticalDelegate's resetToPosition
method to fix a bug and support additional use cases, but
introduced a new issue in the case where a list only has enough
items to fill a single page.

This commit adds logic to ensure that we don't calculate an invalid
page index (-1) in this case.

Also removing no-longer-needed call to pagesByPosition, which
was left over from a previous implementation of resetToPosition.

Enyo-DCO-1.1-Signed-Off-By: Gray Norton (gray.norton@lge.com)