| 1 |
|
| 2 |
|
| 3 |
|
| 4 |
#pragma once |
| 5 |
|
| 6 |
#include <array> |
| 7 |
|
| 8 |
#include <QWidget> |
| 9 |
|
| 10 |
class ConfigBool; |
| 11 |
class ConfigChoice; |
| 12 |
class ConfigInteger; |
| 13 |
class ConfigRadioInt; |
| 14 |
class ConfigStringChoice; |
| 15 |
class GraphicsPane; |
| 16 |
class QLabel; |
| 17 |
class ToolTipComboBox; |
| 18 |
|
| 19 |
namespace Config |
| 20 |
{ |
| 21 |
class Layer; |
| 22 |
} |
| 23 |
|
| 24 |
class GeneralWidget final : public QWidget |
| 25 |
{ |
| 26 |
Q_OBJECT |
| 27 |
public: |
| 28 |
explicit GeneralWidget(GraphicsPane* gfx_pane); |
| 29 |
|
| 30 |
signals: |
| 31 |
void BackendChanged(const QString& backend); |
| 32 |
|
| 33 |
private: |
| 34 |
void BackendWarning(); |
| 35 |
|
| 36 |
void CreateWidgets(); |
| 37 |
void ToggleCustomAspectRatio(int index); |
| 38 |
void ConnectWidgets(); |
| 39 |
void AddDescriptions(); |
| 40 |
|
| 41 |
void OnBackendChanged(const QString& backend_name); |
| 42 |
void OnEmulationStateChanged(bool running); |
| 43 |
|
| 44 |
|
| 45 |
ConfigStringChoice* m_backend_combo; |
| 46 |
ToolTipComboBox* m_adapter_combo; |
| 47 |
ConfigChoice* m_aspect_combo; |
| 48 |
QLabel* m_custom_aspect_label; |
| 49 |
ConfigInteger* m_custom_aspect_width; |
| 50 |
ConfigInteger* m_custom_aspect_height; |
| 51 |
ConfigBool* m_enable_vsync; |
| 52 |
ConfigBool* m_enable_fullscreen; |
| 53 |
|
| 54 |
|
| 55 |
ConfigBool* m_autoadjust_window_size; |
| 56 |
ConfigBool* m_render_main_window; |
| 57 |
|
| 58 |
std::array<ConfigRadioInt*, 4> m_shader_compilation_mode{}; |
| 59 |
ConfigBool* m_wait_for_shaders; |
| 60 |
int m_previous_backend = 0; |
| 61 |
Config::Layer* m_game_layer = nullptr; |
| 62 |
}; |