summaryrefslogtreecommitdiffstats
path: root/searchdialog.h
diff options
context:
space:
mode:
authorArno <arno@disconnect.de>2020-07-29 05:16:15 +0200
committerArno <arno@disconnect.de>2020-07-29 05:16:15 +0200
commitb384639799a68ca7d7c07eee518d3ef4b34812d0 (patch)
treecce9e8dcf49f1cfc781e1647bb1215f7c7217b0c /searchdialog.h
parentcb0b296a44656de9e4528772f8bb904db37fc9aa (diff)
downloadSheMov-b384639799a68ca7d7c07eee518d3ef4b34812d0.tar.gz
SheMov-b384639799a68ca7d7c07eee518d3ef4b34812d0.tar.bz2
SheMov-b384639799a68ca7d7c07eee518d3ef4b34812d0.zip
Add collapse and expand all to SearchDialog
Thought about using QSignalMapper for this, but that would be too convoluted, thus the inline functions.
Diffstat (limited to 'searchdialog.h')
-rw-r--r--searchdialog.h10
1 files changed, 8 insertions, 2 deletions
diff --git a/searchdialog.h b/searchdialog.h
index 19d0d09..09ed259 100644
--- a/searchdialog.h
+++ b/searchdialog.h
@@ -10,6 +10,8 @@
#include <QDialog>
+#include "smview.h"
+
class QCheckBox;
class QLineEdit;
class QPushButton;
@@ -57,6 +59,10 @@ class ActorsAndMore : public QWidget {
void doSearch();
void doData(const QModelIndex &cur, const QModelIndex &prev);
void dataDoubleClicked(const QModelIndex &index);
+ void collapseAllResult() { mResultView->collapseAll(); }
+ void expandAllResult() { mResultView->expandAll(); }
+ void collapseAllData() { mDataView->collapseAll(); }
+ void expandAllData() { mDataView->expandAll(); }
private:
void searchActor(const QString &actor);
@@ -68,8 +74,8 @@ class ActorsAndMore : public QWidget {
QLineEdit *mSearch;
QStandardItemModel *mResultModel;
QStandardItemModel *mDataModel;
- QTreeView *mResultView;
- QTreeView *mDataView;
+ SmView *mResultView;
+ SmView *mDataView;
};
class SearchDialog : public QDialog {