X-Git-Url: https://git.quassel-irc.org/?a=blobdiff_plain;f=src%2Fclient%2Fbuffermodel.h;h=7bd3fc9ead4c18f969535d2982bf81cc8ad9afa2;hb=1e626e57b97756088052bcd88a29305dd7412f58;hp=2d6f4b478b08ce987472f95f29ff7d2ccd38da66;hpb=23eed68958b7585552be04fab4e5871a781b7f38;p=quassel.git diff --git a/src/client/buffermodel.h b/src/client/buffermodel.h index 2d6f4b47..7bd3fc9e 100644 --- a/src/client/buffermodel.h +++ b/src/client/buffermodel.h @@ -26,7 +26,6 @@ #include "types.h" #include "selectionmodelsynchronizer.h" -#include "modelpropertymapper.h" class NetworkModel; class MappedSelectionModel; @@ -37,23 +36,23 @@ class BufferModel : public QSortFilterProxyModel { public: BufferModel(NetworkModel *parent = 0); - virtual ~BufferModel(); bool filterAcceptsRow(int sourceRow, const QModelIndex &parent) const; inline const SelectionModelSynchronizer *selectionModelSynchronizer() const { return &_selectionModelSynchronizer; } - inline const ModelPropertyMapper *propertyMapper() const { return &_propertyMapper; } - inline QItemSelectionModel *standardSelectionModel() const { return _propertyMapper.selectionModel(); } - + inline QItemSelectionModel *standardSelectionModel() const { return _selectionModelSynchronizer.selectionModel(); } + void synchronizeSelectionModel(MappedSelectionModel *selectionModel); void synchronizeView(QAbstractItemView *view); - void mapProperty(int column, int role, QObject *target, const QByteArray &property); QModelIndex currentIndex(); + void setCurrentIndex(const QModelIndex &newCurrent); +private slots: + void debug_currentChanged(QModelIndex current, QModelIndex previous); + private: SelectionModelSynchronizer _selectionModelSynchronizer; - ModelPropertyMapper _propertyMapper; }; #endif // BUFFERMODEL_H