Make lastPosition() result consistent among GridView and ListView
lastPosition() returns the end position of the last item so it should
always include a -1 calculation for the last item (as
FxListItemSG::endPosition() and FxGridItemSG::endPosition() do) to get
the last edge pixel of the item. With this fix, both views now
calculate startPosition() and endPosition() in the same way.
This also fixes positioning of GridView items in TopToBottom+RightToLeft
layouts. Incorrect test values in positionViewAtIndex_rightToLeft()
test are fixed (the last edge of a 1-pixel border shouldn't be visible,
since the bottom edge of a 1-pixel border is actually drawn outside,
not inside, the Rectangle).
Change-Id: I253c3836f871c61e13c08f67007ebc75e09378d6
Reviewed-on: http://codereview.qt.nokia.com/1547
Reviewed-by: Bea Lam <bea.lam@nokia.com>
Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com>