2017-07-13 10:26:03 +02:00
|
|
|
/*
|
|
|
|
* csettingsview_moc.h, part of VCMI engine
|
|
|
|
*
|
|
|
|
* Authors: listed in file AUTHORS in main folder
|
|
|
|
*
|
|
|
|
* License: GNU General Public License v2.0 or later
|
|
|
|
* Full text of license available in license.txt file, in main folder
|
|
|
|
*
|
|
|
|
*/
|
2013-08-22 17:22:49 +03:00
|
|
|
#pragma once
|
2016-01-09 22:23:55 +02:00
|
|
|
|
2018-04-13 07:34:58 +02:00
|
|
|
namespace Ui
|
|
|
|
{
|
|
|
|
class CSettingsView;
|
2013-08-22 17:22:49 +03:00
|
|
|
}
|
|
|
|
|
2024-09-14 21:34:39 +02:00
|
|
|
class MainWindow;
|
|
|
|
|
2013-08-22 17:22:49 +03:00
|
|
|
class CSettingsView : public QWidget
|
|
|
|
{
|
|
|
|
Q_OBJECT
|
2018-04-13 07:34:58 +02:00
|
|
|
|
2024-09-14 21:34:39 +02:00
|
|
|
MainWindow * getMainWindow();
|
|
|
|
|
2013-08-22 17:22:49 +03:00
|
|
|
public:
|
2023-10-27 17:10:54 +02:00
|
|
|
explicit CSettingsView(QWidget * parent = nullptr);
|
2013-08-22 17:22:49 +03:00
|
|
|
~CSettingsView();
|
|
|
|
|
|
|
|
void loadSettings();
|
2024-06-11 20:08:55 +02:00
|
|
|
void loadToggleButtonSettings();
|
2023-03-14 13:37:22 +02:00
|
|
|
void loadTranslation();
|
2017-08-24 03:52:02 +02:00
|
|
|
void setDisplayList();
|
2022-12-25 13:19:16 +02:00
|
|
|
void changeEvent(QEvent *event) override;
|
2023-03-14 13:37:22 +02:00
|
|
|
void showEvent(QShowEvent * event) override;
|
2016-01-09 22:23:55 +02:00
|
|
|
|
2024-06-08 19:53:10 +02:00
|
|
|
void setCheckbuttonState(QToolButton * button, bool checked);
|
|
|
|
void updateCheckbuttonText(QToolButton * button);
|
|
|
|
|
2022-09-27 10:51:49 +02:00
|
|
|
public slots:
|
2023-05-07 21:18:01 +02:00
|
|
|
void fillValidResolutions();
|
2022-09-27 10:51:49 +02:00
|
|
|
|
2013-08-22 17:22:49 +03:00
|
|
|
private slots:
|
2022-09-26 15:39:10 +02:00
|
|
|
void on_comboBoxResolution_currentTextChanged(const QString & arg1);
|
2013-08-22 17:22:49 +03:00
|
|
|
void on_comboBoxFullScreen_currentIndexChanged(int index);
|
2023-06-13 19:56:27 +02:00
|
|
|
void on_comboBoxFriendlyAI_currentTextChanged(const QString & arg1);
|
|
|
|
void on_comboBoxNeutralAI_currentTextChanged(const QString & arg1);
|
|
|
|
void on_comboBoxEnemyAI_currentTextChanged(const QString & arg1);
|
2013-08-22 17:22:49 +03:00
|
|
|
void on_spinBoxNetworkPort_valueChanged(int arg1);
|
2024-06-08 20:17:58 +02:00
|
|
|
void on_buttonShowIntro_toggled(bool value);
|
|
|
|
void on_buttonAutoCheck_toggled(bool value);
|
2016-08-30 20:54:37 +02:00
|
|
|
void on_comboBoxDisplayIndex_currentIndexChanged(int index);
|
2024-06-08 20:17:58 +02:00
|
|
|
void on_buttonAutoSave_toggled(bool value);
|
2022-12-25 13:19:16 +02:00
|
|
|
void on_comboBoxLanguage_currentIndexChanged(int index);
|
2024-06-08 20:17:58 +02:00
|
|
|
void on_buttonCursorType_toggled(bool value);
|
2023-03-14 13:37:22 +02:00
|
|
|
void on_pushButtonTranslation_clicked();
|
2024-06-20 21:33:45 +02:00
|
|
|
void on_pushButtonResetTutorialTouchscreen_clicked();
|
2024-06-08 20:17:58 +02:00
|
|
|
void on_buttonRepositoryDefault_toggled(bool value);
|
|
|
|
void on_buttonRepositoryExtra_toggled(bool value);
|
2023-06-29 14:41:12 +02:00
|
|
|
void on_lineEditRepositoryExtra_textEdited(const QString &arg1);
|
|
|
|
void on_spinBoxInterfaceScaling_valueChanged(int arg1);
|
2023-06-30 17:41:05 +02:00
|
|
|
void on_refreshRepositoriesButton_clicked();
|
2023-07-03 13:30:13 +02:00
|
|
|
void on_spinBoxFramerateLimit_valueChanged(int arg1);
|
2024-06-08 20:17:58 +02:00
|
|
|
void on_buttonVSync_toggled(bool value);
|
2023-07-15 12:22:15 +02:00
|
|
|
void on_comboBoxEnemyPlayerAI_currentTextChanged(const QString &arg1);
|
|
|
|
void on_comboBoxAlliedPlayerAI_currentTextChanged(const QString &arg1);
|
2024-06-08 20:17:58 +02:00
|
|
|
void on_buttonAutoSavePrefix_toggled(bool value);
|
2024-04-20 18:51:03 +02:00
|
|
|
void on_spinBoxAutoSaveLimit_valueChanged(int arg1);
|
|
|
|
void on_lineEditAutoSavePrefix_textEdited(const QString &arg1);
|
2024-06-08 20:17:58 +02:00
|
|
|
void on_sliderReservedArea_valueChanged(int arg1);
|
2024-01-05 21:47:03 +02:00
|
|
|
void on_comboBoxRendererType_currentTextChanged(const QString &arg1);
|
|
|
|
|
2024-06-08 19:53:10 +02:00
|
|
|
void on_buttonIgnoreSslErrors_clicked(bool checked);
|
2024-05-07 15:38:38 +02:00
|
|
|
void on_comboBoxUpscalingFilter_currentIndexChanged(int index);
|
2024-08-03 22:14:51 +02:00
|
|
|
void on_comboBoxDownscalingFilter_currentIndexChanged(int index);
|
2024-05-07 15:38:38 +02:00
|
|
|
void on_sliderMusicVolume_valueChanged(int value);
|
|
|
|
void on_sliderSoundVolume_valueChanged(int value);
|
2024-06-08 20:17:58 +02:00
|
|
|
void on_buttonRelativeCursorMode_toggled(bool value);
|
2024-05-07 15:38:38 +02:00
|
|
|
void on_sliderRelativeCursorSpeed_valueChanged(int value);
|
2024-06-08 20:17:58 +02:00
|
|
|
void on_buttonHapticFeedback_toggled(bool value);
|
2024-05-07 15:38:38 +02:00
|
|
|
void on_sliderLongTouchDuration_valueChanged(int value);
|
|
|
|
void on_slideToleranceDistanceMouse_valueChanged(int value);
|
|
|
|
void on_sliderToleranceDistanceTouch_valueChanged(int value);
|
|
|
|
void on_sliderToleranceDistanceController_valueChanged(int value);
|
|
|
|
void on_lineEditGameLobbyHost_textChanged(const QString &arg1);
|
|
|
|
void on_spinBoxNetworkPortLobby_valueChanged(int arg1);
|
2024-04-20 18:46:30 +02:00
|
|
|
|
2024-06-08 17:11:36 +02:00
|
|
|
void on_sliderControllerSticksAcceleration_valueChanged(int value);
|
|
|
|
|
|
|
|
void on_sliderControllerSticksSensitivity_valueChanged(int value);
|
|
|
|
|
2024-09-14 21:34:39 +02:00
|
|
|
void on_buttonTtfFont_toggled(bool value);
|
|
|
|
|
2013-08-22 17:22:49 +03:00
|
|
|
private:
|
2018-04-13 07:34:58 +02:00
|
|
|
Ui::CSettingsView * ui;
|
2022-09-26 15:58:27 +02:00
|
|
|
|
2024-01-05 21:47:03 +02:00
|
|
|
void fillValidRenderers();
|
2022-09-26 15:58:27 +02:00
|
|
|
void fillValidResolutionsForScreen(int screenIndex);
|
2023-06-29 18:52:25 +02:00
|
|
|
void fillValidScalingRange();
|
|
|
|
QSize getPreferredRenderingResolution();
|
2013-08-22 17:22:49 +03:00
|
|
|
};
|