Fix slideshow crashing in invalidate()
QSortFilterProxyModel uses std::stable_sort internally which requires that the
comparison function generates a strict weak ordering. Returning true or false
randomly didn't fullfil this requirement causing a crash in some calls to invalidate.
To keep the random order consistent a vector of row indices is used which records
the current random order.
To reproduce the bug use a slideshow in random order with few pictures and a small
Reviewers: Plasma, broulik
Reviewed By: Plasma, broulik
Subscribers: davidedmundson, broulik, plasma-devel
Differential Revision: https://phabricator.kde.org/D24723