Proxy model that reverses row order for display (newest first).
More...
#include <recentcapturefiles_list_model.h>
|
| | RecentCaptureFilesReverseProxyModel (QObject *parent=nullptr) |
| | Constructs the reverse-order proxy model.
|
| |
| QModelIndex | mapToSource (const QModelIndex &proxyIndex) const override |
| | Maps a proxy index to the corresponding source index by mirroring the row about the midpoint of the list.
|
| |
| QModelIndex | mapFromSource (const QModelIndex &sourceIndex) const override |
| | Maps a source index to the corresponding proxy index by mirroring the row about the midpoint of the list.
|
| |
Proxy model that reverses row order for display (newest first).
WorkspaceState stores files oldest-first to match the on-disk file format. This proxy reverses the order so the UI shows the most recently used files at the top of the list.
◆ RecentCaptureFilesReverseProxyModel()
| RecentCaptureFilesReverseProxyModel::RecentCaptureFilesReverseProxyModel |
( |
QObject * |
parent = nullptr | ) |
|
|
explicit |
Constructs the reverse-order proxy model.
- Parameters
-
| parent | Optional parent QObject. |
◆ mapFromSource()
| QModelIndex RecentCaptureFilesReverseProxyModel::mapFromSource |
( |
const QModelIndex & |
sourceIndex | ) |
const |
|
override |
Maps a source index to the corresponding proxy index by mirroring the row about the midpoint of the list.
- Parameters
-
| sourceIndex | Source-model index to map. |
- Returns
- Corresponding proxy-model index.
◆ mapToSource()
| QModelIndex RecentCaptureFilesReverseProxyModel::mapToSource |
( |
const QModelIndex & |
proxyIndex | ) |
const |
|
override |
Maps a proxy index to the corresponding source index by mirroring the row about the midpoint of the list.
- Parameters
-
| proxyIndex | Proxy-model index to map. |
- Returns
- Corresponding source-model index.
The documentation for this class was generated from the following files: