2018-01-01 09:22:11 +01:00
|
|
|
#ifndef MAINWINDOW_H
|
|
|
|
#define MAINWINDOW_H
|
|
|
|
|
|
|
|
#include <QMainWindow>
|
2019-01-14 17:49:10 +01:00
|
|
|
#include <QString>
|
2019-11-01 09:29:00 +01:00
|
|
|
#include <QFileSystemModel>
|
2018-01-01 09:22:11 +01:00
|
|
|
|
2021-04-03 21:30:50 +02:00
|
|
|
class QListWidgetItem;
|
|
|
|
class QTextStream;
|
2018-01-01 09:22:11 +01:00
|
|
|
namespace Ui {
|
2018-01-01 10:52:51 +01:00
|
|
|
class MainWindow;
|
2018-01-01 09:22:11 +01:00
|
|
|
}
|
|
|
|
|
2018-01-01 10:52:51 +01:00
|
|
|
class MainWindow : public QMainWindow {
|
2018-01-01 09:22:11 +01:00
|
|
|
Q_OBJECT
|
|
|
|
|
|
|
|
public:
|
2019-01-12 09:16:43 +01:00
|
|
|
explicit MainWindow(QWidget *parent = Q_NULLPTR);
|
2018-05-01 10:55:06 +02:00
|
|
|
MainWindow(const MainWindow &) = delete;
|
|
|
|
MainWindow &operator=(const MainWindow &) = delete;
|
2019-11-01 09:29:00 +01:00
|
|
|
~MainWindow();
|
2018-01-01 09:22:11 +01:00
|
|
|
|
|
|
|
public slots:
|
2018-01-02 23:39:30 +01:00
|
|
|
void loadFile();
|
2019-01-14 17:49:10 +01:00
|
|
|
void loadFromClipboard();
|
2019-06-15 14:37:02 +02:00
|
|
|
void filter(QString filter);
|
2018-01-01 09:22:11 +01:00
|
|
|
void showResult(QListWidgetItem *item);
|
2019-03-09 11:01:22 +01:00
|
|
|
void refreshResults();
|
2019-11-01 09:29:00 +01:00
|
|
|
void fileTreeFilter(QString str);
|
|
|
|
void findInFilesClicked();
|
|
|
|
void directorytreeDoubleClick();
|
|
|
|
void searchResultsDoubleClick();
|
2021-12-22 18:58:11 +01:00
|
|
|
void resultsContextMenu(const QPoint& pos);
|
2018-01-01 09:22:11 +01:00
|
|
|
|
|
|
|
private:
|
|
|
|
Ui::MainWindow *ui;
|
2019-01-12 09:16:43 +01:00
|
|
|
|
2019-01-14 17:49:10 +01:00
|
|
|
void load(QTextStream &textStream);
|
2019-01-12 09:16:43 +01:00
|
|
|
bool runProcess(const QString &programName, const QStringList & arguments);
|
2019-02-16 17:52:36 +01:00
|
|
|
bool wget(const QString &url);
|
|
|
|
bool unpackArchive(const QString &archiveName);
|
2019-11-01 09:29:00 +01:00
|
|
|
void showSrcFile(const QString &fileName, const QString &url, const int lineNumber);
|
2019-03-09 11:01:22 +01:00
|
|
|
|
|
|
|
QStringList mAllErrors;
|
2019-11-04 07:10:31 +01:00
|
|
|
QFileSystemModel mFSmodel;
|
|
|
|
const QRegExp mVersionRe;
|
|
|
|
|
|
|
|
const QStringList hFiles;
|
|
|
|
const QStringList srcFiles;
|
2018-01-01 09:22:11 +01:00
|
|
|
};
|
|
|
|
|
|
|
|
#endif // MAINWINDOW_H
|