V4: work around a bug in libc++'s std::vector<bool>

The ++operator of std::vector<bool>::iterator in libc++ has a bug when
using it on an iterator pointing to the last element. It will not be set
to ::end(), but beyond that. (It will be set to the first multiple of
the native word size that is bigger than size().)

See http://llvm.org/bugs/show_bug.cgi?id=19663

Task-number: QTBUG-39911
Change-Id: Ic244d9c90ee6b596261a6e322301c411a14820a8
Reviewed-by: Fawzi Mohamed <fawzi.mohamed@digia.com>
Reviewed-by: Lars Knoll <lars.knoll@digia.com>
Reviewed-by: Simon Hausmann <simon.hausmann@digia.com>
Improve programmatic flicking of ListView (and Flickable).

Fix bug when programmatically flicking ListView after a real flick in the
opposite direction. Also ensure a programmatic flick can flick past
bounds when situated at the bounds and DragAndOvershootBounds is set.

Task-number: QTBUG-38209
Change-Id: If4a2f65d0e7cb620b9af21f8a25a8a8797976125
Reviewed-by: Martin Jones <martin.jones@jollamobile.com>
Clear the visibleImgTags list when setting up the text layout

Since the text layout is being redone then the visibleImgTags will be
repopulated, therefore it should be cleared first so that it doesn't have
duplicated entries.

Change-Id: I415f94326e156ae265bc044544f2bb0d7146ce4c
Reviewed-by: Eskil Abrahamsen Blomfeldt <eskil.abrahamsen-blomfeldt@digia.com>