4 #include "filetablemodel.h"
9 class FolderView : public QTableView
13 explicit FolderView(QWidget *parent = 0);
19 void updateAppearance();
22 void searchItem(const QString &text);
23 void searchNext(const QString &text);
24 void searchPrev(const QString &text);
26 void setCheckStateAll(bool checked);
27 void setCheckStateAllFiles();
28 void invertCheckState();
29 void toggleCheckState(const QModelIndex &index);
32 bool historyForward();
36 QFileInfo currentItem() const;
37 QString dir() const { return m_model.absolutePath(); }
38 QFileInfoList selectedItems() const;
39 const History* history() const { return &m_history; }
40 QStringList nameFilters() const { return m_model.nameFilters(); }
43 void setPath(const QString &path, bool addHistory);
44 void setFilter(QDir::Filters filter, bool enable);
45 void setHistoryIndexAt(int index);
46 void setNameFilters(const QStringList &list);
47 void setSorting(QDir::SortFlags flags);
50 FileTableModel m_model;
55 void itemFound(FolderView *view);
56 void itemNotFound(FolderView *view);
57 void retrieveStarted(const QString &path);
58 void retrieveFinished();
59 void keyPressed(FolderView *view, QKeyEvent *event);
66 void keyPressEvent(QKeyEvent *event);
70 #endif // FOLDERVIEW_H