-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathmainwinrenamer.h
executable file
·65 lines (53 loc) · 1.68 KB
/
mainwinrenamer.h
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
#ifndef MAINWINRENAMER_H
#define MAINWINRENAMER_H
#include <QWidget>
#include <QTableWidget>
#include <QFile>
#include <QDir>
#include <QStringList>
#include "editorwgt.h"
#include "directoryreader.h"
class EditorWgt;
class QProgressBar;
class QThread;
/**
* @brief The MainWinRenamer class - основное окно программы.
*/
class MainWinRenamer : public QWidget
{
Q_OBJECT
QTableWidget *tblWgt;
EditorWgt *editor;
int currentRow;
QFile currentFile;
QProgressBar *prBar;
DirectoryReader dir_reader_;
QThread *thread_;
QStringList old_file_names;
bool is_auto_rename;
/**
* @brief clearTable - удаляет содержимое таблицы вместе со строками.
*/
void clearTable();
//QString EXIF_ErrorCodeToString(int code);
public:
MainWinRenamer(QWidget *parent = nullptr);
~MainWinRenamer();
private slots:
void sltCurrentDirectoryChoosed(const QString &cdir);
void sltTblCellClicked(int row, int col);
void sltFileNameChanged(const QString &newName);
void sltAutoRename(const QString &oldName, const QString &newName);
//void fillTable();
void onRowReady(int row_num, const QString &fname, const QString &size, const QString &date, const QString &camera_brand, const QString &camera_model, int percent);
void onAnalyzeDirectoryFinished();
void file_dropped_from_folder(const QString &fname);
signals:
void sgnPicClicked(QString fname);
void filling_finished();
protected:
virtual void resizeEvent(QResizeEvent * event);
private:
void createProgressBar();
};
#endif // MAINWINRENAMER_H