2021-03-31 05:38:59 -07:00
|
|
|
#ifndef GENERALDIALOG_H
|
|
|
|
#define GENERALDIALOG_H
|
|
|
|
|
|
|
|
#include <QDialog>
|
|
|
|
|
2021-05-09 11:07:05 -07:00
|
|
|
#include "usbms_splash.h"
|
2021-06-08 04:49:52 -07:00
|
|
|
#include "textwidget.h"
|
2021-07-05 13:01:32 -07:00
|
|
|
#include "virtualkeyboard.h"
|
2021-07-05 10:45:35 -07:00
|
|
|
#include "virtualkeypad.h"
|
2021-07-05 19:21:20 -07:00
|
|
|
#include "dictionarywidget.h"
|
2021-08-19 05:23:18 -07:00
|
|
|
#include "otamanager.h"
|
2021-09-04 19:18:17 -07:00
|
|
|
#include "searchresultswidget.h"
|
2021-05-09 11:07:05 -07:00
|
|
|
|
2021-03-31 05:38:59 -07:00
|
|
|
using namespace std;
|
|
|
|
|
|
|
|
namespace Ui {
|
|
|
|
class generalDialog;
|
|
|
|
}
|
|
|
|
|
|
|
|
class generalDialog : public QDialog
|
|
|
|
{
|
|
|
|
Q_OBJECT
|
|
|
|
|
|
|
|
public:
|
2022-04-04 21:47:15 -07:00
|
|
|
QString className = this->metaObject()->className();
|
2021-03-31 05:38:59 -07:00
|
|
|
explicit generalDialog(QWidget *parent = nullptr);
|
|
|
|
~generalDialog();
|
|
|
|
bool resetDialog = false;
|
2021-04-01 05:58:37 -07:00
|
|
|
bool updateDialog = false;
|
2021-04-05 12:35:25 -07:00
|
|
|
bool settingsRebootDialog = false;
|
2021-05-01 12:53:52 -07:00
|
|
|
bool koboxSettingsRebootDialog = false;
|
2021-04-22 04:38:54 -07:00
|
|
|
bool lowBatteryDialog = false;
|
2021-05-09 11:07:05 -07:00
|
|
|
bool usbmsDialog = false;
|
2021-06-08 04:49:52 -07:00
|
|
|
bool textBrowserDialog = false;
|
2022-06-17 20:59:21 -07:00
|
|
|
bool appCompabilityDialog = false;
|
|
|
|
bool appInfoDialog = false;
|
2021-06-14 11:31:49 -07:00
|
|
|
bool resetKoboxDialog = false;
|
2021-07-05 10:45:35 -07:00
|
|
|
bool keyboardDialog = false;
|
|
|
|
bool keypadDialog = false;
|
2021-07-05 19:21:20 -07:00
|
|
|
bool dictionaryResults = false;
|
2021-07-05 21:13:11 -07:00
|
|
|
bool vncServerSet = false;
|
|
|
|
bool vncPasswordSet = false;
|
2022-01-11 11:17:14 -08:00
|
|
|
bool gutenbergSyncDone = false;
|
|
|
|
bool gutenbergSyncStatus = false;
|
|
|
|
bool noGutenbergSyncToDo = false;
|
2022-01-12 08:30:34 -08:00
|
|
|
bool searchTimerDone = false;
|
2021-07-05 21:13:11 -07:00
|
|
|
QString vncServerAddress;
|
|
|
|
QString vncServerPassword;
|
|
|
|
QString vncServerPort;
|
2021-07-14 15:23:54 -07:00
|
|
|
QString wifiEssid;
|
|
|
|
QString wifiPassphrase;
|
2021-07-05 19:21:20 -07:00
|
|
|
void setupKeyboardDialog();
|
2021-07-05 21:13:11 -07:00
|
|
|
void startVNC(QString server, QString password, QString port);
|
2022-06-17 20:59:21 -07:00
|
|
|
float yIncrease;
|
|
|
|
|
|
|
|
public slots:
|
|
|
|
void increaseSize();
|
2021-03-31 05:38:59 -07:00
|
|
|
|
|
|
|
private slots:
|
|
|
|
void on_cancelBtn_clicked();
|
|
|
|
void on_okBtn_clicked();
|
2021-04-05 12:35:25 -07:00
|
|
|
void on_acceptBtn_clicked();
|
2021-07-05 13:01:32 -07:00
|
|
|
void adjust_size();
|
2021-07-05 19:21:20 -07:00
|
|
|
void restartSearchDialog();
|
|
|
|
void refreshScreenNative();
|
2021-07-14 15:23:54 -07:00
|
|
|
void connectToNetworkSlot();
|
2021-08-19 05:23:18 -07:00
|
|
|
void startOtaUpdate(bool wasDownloadSuccessful);
|
2021-09-05 06:37:07 -07:00
|
|
|
void openBookFileNative(QString book, bool relativePath);
|
2021-12-29 20:09:51 -08:00
|
|
|
void showToastNative(QString messageToDisplay);
|
|
|
|
void closeIndefiniteToastNative();
|
2021-12-31 12:50:59 -08:00
|
|
|
void quit_restart();
|
2022-01-12 08:04:10 -08:00
|
|
|
void syncGutenbergCatalog();
|
|
|
|
void waitForGutenbergSearchDone();
|
2021-04-05 12:35:25 -07:00
|
|
|
|
2021-03-31 05:38:59 -07:00
|
|
|
private:
|
|
|
|
Ui::generalDialog *ui;
|
2021-05-09 11:07:05 -07:00
|
|
|
usbms_splash *usbmsWindow;
|
2021-06-08 04:49:52 -07:00
|
|
|
textwidget *textwidgetWindow;
|
2021-07-05 13:01:32 -07:00
|
|
|
virtualkeyboard *keyboardWidget;
|
2021-07-05 10:45:35 -07:00
|
|
|
virtualkeypad *keypadWidget;
|
2021-07-05 19:21:20 -07:00
|
|
|
dictionaryWidget *dictionaryWidgetWindow;
|
2021-08-19 05:23:18 -07:00
|
|
|
otaManager *otaManagerWindow;
|
2021-09-04 19:18:17 -07:00
|
|
|
searchResultsWidget * searchResultsWidgetWindow;
|
2021-07-05 10:45:35 -07:00
|
|
|
|
|
|
|
signals:
|
|
|
|
void gotoPageSelected(int value);
|
2021-07-05 13:01:32 -07:00
|
|
|
void refreshScreen();
|
2021-07-14 15:23:54 -07:00
|
|
|
void updateWifiIcon(int mode);
|
|
|
|
void showToast(QString messageToDisplay);
|
|
|
|
void closeIndefiniteToast();
|
2021-09-05 06:37:07 -07:00
|
|
|
void openBookFile(QString book, bool relativePath);
|
2021-10-17 19:31:44 -07:00
|
|
|
void cancelDisableStorageEncryption();
|
|
|
|
void disableStorageEncryption();
|
2021-03-31 05:38:59 -07:00
|
|
|
};
|
|
|
|
|
|
|
|
#endif // GENERALDIALOG_H
|