TabEditor-Qt/mainwindow.h

40 lines
858 B
C
Raw Normal View History

2023-06-20 22:15:15 +08:00
#ifndef MAINWINDOW_H
#define MAINWINDOW_H
#include "qprogressdialog.h"
#include <QThread>
#include <QMainWindow>
#include <QTableWidget>
2023-06-20 22:27:42 +08:00
#include <QDragEnterEvent>
#include <QMimeData>
2023-06-20 23:05:02 +08:00
#include <QShortcut>
2023-06-20 22:15:15 +08:00
QT_BEGIN_NAMESPACE
namespace Ui { class MainWindow; }
QT_END_NAMESPACE
class MainWindow : public QMainWindow
{
Q_OBJECT
public:
MainWindow(QWidget *parent = nullptr);
~MainWindow();
void loadTextFile(const QString& fileName);
2023-06-20 22:27:42 +08:00
void dragEnterEvent(QDragEnterEvent *event);
void dropEvent(QDropEvent *event);
2023-06-21 00:17:06 +08:00
void convertTextToSqlite();
void convertSqliteToText();
2023-06-20 22:15:15 +08:00
private slots:
void onOpenButtonClicked();
void onSaveButtonClicked();
private:
Ui::MainWindow *ui;
QProgressDialog* progressDialog; // 添加进度对话框指针
2023-06-20 23:05:02 +08:00
QMenu* menuFile;
QAction* actionFile;
2023-06-20 22:15:15 +08:00
};
#endif // MAINWINDOW_H