summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorGravatar Lioncash2019-04-05 19:26:39 -0400
committerGravatar Lioncash2019-04-05 19:26:43 -0400
commitbbeb859122e322e062ee271a0dba5b46cca87ef7 (patch)
tree8443b18e760b9481fde15e219f75931e310a8df3 /src
parentyuzu/debugger/graphics_surface: Fill in missing surface format listings (diff)
downloadyuzu-bbeb859122e322e062ee271a0dba5b46cca87ef7.tar.gz
yuzu-bbeb859122e322e062ee271a0dba5b46cca87ef7.tar.xz
yuzu-bbeb859122e322e062ee271a0dba5b46cca87ef7.zip
yuzu/debugger/graphics_surface: Clean up connection overload deduction
We can utilize qOverload with the signal connections to make the function deducing a little less ugly.
Diffstat (limited to 'src')
-rw-r--r--src/yuzu/debugger/graphics/graphics_surface.cpp22
1 files changed, 10 insertions, 12 deletions
diff --git a/src/yuzu/debugger/graphics/graphics_surface.cpp b/src/yuzu/debugger/graphics/graphics_surface.cpp
index 946a17dd8..886da9587 100644
--- a/src/yuzu/debugger/graphics/graphics_surface.cpp
+++ b/src/yuzu/debugger/graphics/graphics_surface.cpp
@@ -198,22 +198,20 @@ GraphicsSurfaceWidget::GraphicsSurfaceWidget(std::shared_ptr<Tegra::DebugContext
198 198
199 // Connections 199 // Connections
200 connect(this, &GraphicsSurfaceWidget::Update, this, &GraphicsSurfaceWidget::OnUpdate); 200 connect(this, &GraphicsSurfaceWidget::Update, this, &GraphicsSurfaceWidget::OnUpdate);
201 connect(surface_source_list, 201 connect(surface_source_list, qOverload<int>(&QComboBox::currentIndexChanged), this,
202 static_cast<void (QComboBox::*)(int)>(&QComboBox::currentIndexChanged), this,
203 &GraphicsSurfaceWidget::OnSurfaceSourceChanged); 202 &GraphicsSurfaceWidget::OnSurfaceSourceChanged);
204 connect(surface_address_control, &CSpinBox::ValueChanged, this, 203 connect(surface_address_control, &CSpinBox::ValueChanged, this,
205 &GraphicsSurfaceWidget::OnSurfaceAddressChanged); 204 &GraphicsSurfaceWidget::OnSurfaceAddressChanged);
206 connect(surface_width_control, static_cast<void (QSpinBox::*)(int)>(&QSpinBox::valueChanged), 205 connect(surface_width_control, qOverload<int>(&QSpinBox::valueChanged), this,
207 this, &GraphicsSurfaceWidget::OnSurfaceWidthChanged); 206 &GraphicsSurfaceWidget::OnSurfaceWidthChanged);
208 connect(surface_height_control, static_cast<void (QSpinBox::*)(int)>(&QSpinBox::valueChanged), 207 connect(surface_height_control, qOverload<int>(&QSpinBox::valueChanged), this,
209 this, &GraphicsSurfaceWidget::OnSurfaceHeightChanged); 208 &GraphicsSurfaceWidget::OnSurfaceHeightChanged);
210 connect(surface_format_control, 209 connect(surface_format_control, qOverload<int>(&QComboBox::currentIndexChanged), this,
211 static_cast<void (QComboBox::*)(int)>(&QComboBox::currentIndexChanged), this,
212 &GraphicsSurfaceWidget::OnSurfaceFormatChanged); 210 &GraphicsSurfaceWidget::OnSurfaceFormatChanged);
213 connect(surface_picker_x_control, static_cast<void (QSpinBox::*)(int)>(&QSpinBox::valueChanged), 211 connect(surface_picker_x_control, qOverload<int>(&QSpinBox::valueChanged), this,
214 this, &GraphicsSurfaceWidget::OnSurfacePickerXChanged); 212 &GraphicsSurfaceWidget::OnSurfacePickerXChanged);
215 connect(surface_picker_y_control, static_cast<void (QSpinBox::*)(int)>(&QSpinBox::valueChanged), 213 connect(surface_picker_y_control, qOverload<int>(&QSpinBox::valueChanged), this,
216 this, &GraphicsSurfaceWidget::OnSurfacePickerYChanged); 214 &GraphicsSurfaceWidget::OnSurfacePickerYChanged);
217 connect(save_surface, &QPushButton::clicked, this, &GraphicsSurfaceWidget::SaveSurface); 215 connect(save_surface, &QPushButton::clicked, this, &GraphicsSurfaceWidget::SaveSurface);
218 216
219 auto main_widget = new QWidget; 217 auto main_widget = new QWidget;