Update CREDITS.txt
[opentx.git] / companion / src / apppreferencesdialog.h
blob22949e99032543c616bddd9e16c1e95f728d9469
1 /*
2 * Copyright (C) OpenTX
4 * Based on code named
5 * th9x - http://code.google.com/p/th9x
6 * er9x - http://code.google.com/p/er9x
7 * gruvin9x - http://code.google.com/p/gruvin9x
9 * License GPLv2: http://www.gnu.org/licenses/gpl-2.0.html
11 * This program is free software; you can redistribute it and/or modify
12 * it under the terms of the GNU General Public License version 2 as
13 * published by the Free Software Foundation.
15 * This program is distributed in the hope that it will be useful,
16 * but WITHOUT ANY WARRANTY; without even the implied warranty of
17 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
18 * GNU General Public License for more details.
21 #ifndef _APPPREFERENCESDIALOG_H_
22 #define _APPPREFERENCESDIALOG_H_
24 #include <QDialog>
25 #include <QCheckBox>
26 #include "eeprominterface.h"
28 namespace Ui {
29 class AppPreferencesDialog;
32 class Joystick;
34 class AppPreferencesDialog : public QDialog
36 Q_OBJECT
38 public:
39 explicit AppPreferencesDialog(QWidget * parent = 0);
40 ~AppPreferencesDialog();
42 Joystick * joystick;
44 public slots:
45 void accept() Q_DECL_OVERRIDE;
46 void setMainWinHasDirtyChild(bool value);
48 signals:
49 void firmwareProfileChanged(int profId);
50 void firmwareProfileAboutToChange(bool saveFiles = true);
52 private:
53 QList<QCheckBox *> optionsCheckBoxes;
54 bool updateLock;
55 bool mainWinHasDirtyChild;
56 void showVoice(bool);
57 void showVoice();
58 void hideVoice();
59 void populateLocale();
60 void populateFirmwareOptions(const Firmware *);
61 Firmware * getFirmwareVariant();
62 QCheckBox * voice;
64 Ui::AppPreferencesDialog *ui;
65 void initSettings();
66 bool displayImage(const QString & fileName);
68 protected slots:
69 void shrink();
70 void baseFirmwareChanged();
71 void firmwareOptionChanged(bool state);
72 void toggleAppLogSettings();
74 void on_libraryPathButton_clicked();
75 void on_snapshotPathButton_clicked();
76 void on_snapshotClipboardCKB_clicked();
77 void on_backupPathButton_clicked();
78 void on_ProfilebackupPathButton_clicked();
79 void on_ge_pathButton_clicked();
81 void on_sdPathButton_clicked();
82 void on_SplashSelect_clicked();
83 void on_clearImageButton_clicked();
84 void on_btn_appLogsDir_clicked();
86 #if defined(JOYSTICKS)
87 void on_joystickChkB_clicked();
88 void on_joystickcalButton_clicked();
89 #endif
92 #endif // _APPPREFERENCESDIALOG_H_