mirror of
https://github.com/Chatterino/chatterino2.git
synced 2024-11-13 19:49:51 +01:00
33 lines
638 B
C++
33 lines
638 B
C++
|
#pragma once
|
||
|
|
||
|
#include <QListView>
|
||
|
#include "widgets/listview/GenericItemDelegate.hpp"
|
||
|
#include "widgets/listview/GenericListItem.hpp"
|
||
|
|
||
|
namespace chatterino {
|
||
|
|
||
|
class GenericListModel;
|
||
|
class Theme;
|
||
|
|
||
|
class GenericListView : public QListView
|
||
|
{
|
||
|
Q_OBJECT
|
||
|
|
||
|
public:
|
||
|
GenericListView();
|
||
|
|
||
|
virtual void setModel(QAbstractItemModel *model) override;
|
||
|
void setModel(GenericListModel *);
|
||
|
bool eventFilter(QObject *watched, QEvent *event) override;
|
||
|
|
||
|
GenericListModel *model_{};
|
||
|
SwitcherItemDelegate itemDelegate_;
|
||
|
|
||
|
void refreshTheme(const Theme &theme);
|
||
|
|
||
|
signals:
|
||
|
void closeRequested();
|
||
|
};
|
||
|
|
||
|
} // namespace chatterino
|