Proxy model that appends additional information rows to a source model.
More...
#include <info_proxy_model.h>
|
| | InfoProxyModel (QObject *parent=0) |
| | Constructs an InfoProxyModel.
|
| |
|
| ~InfoProxyModel () |
| | Destroys the InfoProxyModel.
|
| |
| virtual int | rowCount (const QModelIndex &parent=QModelIndex()) const |
| | Returns the number of rows under the given parent.
|
| |
| virtual QVariant | data (const QModelIndex &index, int role=Qt::DisplayRole) const |
| | Returns the data stored under the given role for the item referred to by the index.
|
| |
| virtual Qt::ItemFlags | flags (const QModelIndex &index) const |
| | Returns the item flags for the given index.
|
| |
| virtual QModelIndex | index (int row, int column, const QModelIndex &parent=QModelIndex()) const |
| | Returns the index of the item in the model specified by the given row, column and parent index.
|
| |
| virtual QModelIndex | mapToSource (const QModelIndex &proxyIndex) const |
| | Maps a proxy index to the corresponding source model index.
|
| |
| virtual QModelIndex | mapFromSource (const QModelIndex &fromIndex) const |
| | Maps a source model index to the corresponding proxy model index.
|
| |
| void | appendInfo (QString info) |
| | Appends an information string to the model.
|
| |
|
void | clearInfos () |
| | Clears all appended information strings.
|
| |
| void | setColumn (int column) |
| | Sets the column used for displaying the information.
|
| |
Proxy model that appends additional information rows to a source model.
◆ InfoProxyModel()
| InfoProxyModel::InfoProxyModel |
( |
QObject * |
parent = 0 | ) |
|
|
explicit |
◆ appendInfo()
| void InfoProxyModel::appendInfo |
( |
QString |
info | ) |
|
Appends an information string to the model.
- Parameters
-
| info | The information string to append. |
◆ data()
| QVariant InfoProxyModel::data |
( |
const QModelIndex & |
index, |
|
|
int |
role = Qt::DisplayRole |
|
) |
| const |
|
virtual |
Returns the data stored under the given role for the item referred to by the index.
- Parameters
-
| index | The model index. |
| role | The item role. |
- Returns
- The data for the specified role.
◆ flags()
| Qt::ItemFlags InfoProxyModel::flags |
( |
const QModelIndex & |
index | ) |
const |
|
virtual |
Returns the item flags for the given index.
- Parameters
-
- Returns
- The item flags.
◆ index()
| QModelIndex InfoProxyModel::index |
( |
int |
row, |
|
|
int |
column, |
|
|
const QModelIndex & |
parent = QModelIndex() |
|
) |
| const |
|
virtual |
Returns the index of the item in the model specified by the given row, column and parent index.
- Parameters
-
| row | The row number. |
| column | The column number. |
| parent | The parent model index. |
- Returns
- The created model index.
◆ mapFromSource()
| QModelIndex InfoProxyModel::mapFromSource |
( |
const QModelIndex & |
fromIndex | ) |
const |
|
virtual |
Maps a source model index to the corresponding proxy model index.
- Parameters
-
| fromIndex | The source model index. |
- Returns
- The proxy model index.
◆ mapToSource()
| QModelIndex InfoProxyModel::mapToSource |
( |
const QModelIndex & |
proxyIndex | ) |
const |
|
virtual |
Maps a proxy index to the corresponding source model index.
- Parameters
-
| proxyIndex | The proxy model index. |
- Returns
- The source model index.
◆ rowCount()
| int InfoProxyModel::rowCount |
( |
const QModelIndex & |
parent = QModelIndex() | ) |
const |
|
virtual |
Returns the number of rows under the given parent.
- Parameters
-
| parent | The parent model index. |
- Returns
- The row count including the appended information rows.
◆ setColumn()
| void InfoProxyModel::setColumn |
( |
int |
column | ) |
|
Sets the column used for displaying the information.
- Parameters
-
The documentation for this class was generated from the following files:
- /builds/wireshark/wireshark/ui/qt/models/info_proxy_model.h
- /builds/wireshark/wireshark/ui/qt/models/info_proxy_model.cpp