Stop when first or last doc is reached instead of wrapping-around
Review Request #115020 - Created Jan. 15, 2014 and submitted
Wrapping around when reaching the end has turned out to be annoying: I rarely wants it to happen. This patch changes this behavior to stop when first or last doc is reached.
Tested with list of one or more images. Works as expected.