Open Source Snapmatic picture and Savegame viewer/editor for GTA V https://gta5view.syping.de/

OptionsDialog.h 2.6KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586
  1. /******************************************************************************
  2. * gta5view Grand Theft Auto V Profile Viewer
  3. * Copyright (C) 2016-2017 Syping
  4. *
  5. * This program is free software: you can redistribute it and/or modify
  6. * it under the terms of the GNU General Public License as published by
  7. * the Free Software Foundation, either version 3 of the License, or
  8. * (at your option) any later version.
  9. *
  10. * This program is distributed in the hope that it will be useful,
  11. * but WITHOUT ANY WARRANTY; without even the implied warranty of
  12. * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
  13. * GNU General Public License for more details.
  14. *
  15. * You should have received a copy of the GNU General Public License
  16. * along with this program. If not, see <http://www.gnu.org/licenses/>.
  17. *****************************************************************************/
  18. #ifndef OPTIONSDIALOG_H
  19. #define OPTIONSDIALOG_H
  20. #include <QSize>
  21. #include <QList>
  22. #include <QDialog>
  23. #include <QSettings>
  24. #include <QTreeWidgetItem>
  25. #include "ProfileDatabase.h"
  26. namespace Ui {
  27. class OptionsDialog;
  28. }
  29. class OptionsDialog : public QDialog
  30. {
  31. Q_OBJECT
  32. public:
  33. explicit OptionsDialog(ProfileDatabase *profileDB, QWidget *parent = 0);
  34. void commitProfiles(const QStringList &profiles);
  35. ~OptionsDialog();
  36. private slots:
  37. void on_cmdOK_clicked();
  38. void on_rbPicCustomRes_toggled(bool checked);
  39. void on_cbPicCustomQuality_toggled(bool checked);
  40. void on_hsPicQuality_valueChanged(int value);
  41. void on_cbIgnoreAspectRatio_toggled(bool checked);
  42. void on_cmdExploreFolder_clicked();
  43. void on_cbDefaultStyle_toggled(bool checked);
  44. void on_cmdCopyStatsID_clicked();
  45. signals:
  46. void settingsApplied(int contentMode, bool languageChanged);
  47. private:
  48. ProfileDatabase *profileDB;
  49. Ui::OptionsDialog *ui;
  50. QList<QTreeWidgetItem*> playerItems;
  51. Qt::AspectRatioMode aspectRatio;
  52. QString currentAreaLanguage;
  53. QString currentLanguage;
  54. QString currentCFolder;
  55. QString defaultProfile;
  56. QString percentString;
  57. QSettings *settings;
  58. bool withoutPlayers;
  59. bool currentFFolder;
  60. int contentMode;
  61. int customQuality;
  62. int defaultQuality;
  63. QSize defExportSize;
  64. QSize cusExportSize;
  65. void setupTreeWidget();
  66. void setupLanguageBox();
  67. void setupRadioButtons();
  68. void setupDefaultProfile();
  69. void setupPictureSettings();
  70. void setupCustomGTAFolder();
  71. void setupInterfaceSettings();
  72. void setupStatisticsSettings();
  73. void setupSnapmaticPictureViewer();
  74. void setupWindowsGameSettings();
  75. void applySettings();
  76. };
  77. #endif // OPTIONSDIALOG_H