mirror of
https://github.com/dolphin-emu/dolphin.git
synced 2025-07-23 14:19:46 -06:00
Merge pull request #12001 from Filoppi/patch-21
Qt: Fix some Post Process Configuration Widget issues #3-4
This commit is contained in:
@ -279,7 +279,7 @@ u32 PostProcessingConfigWindow::ConfigGroup::AddInteger(PostProcessingConfigWind
|
|||||||
std::ceil(range / static_cast<double>(m_config_option->m_integer_step_values[i]));
|
std::ceil(range / static_cast<double>(m_config_option->m_integer_step_values[i]));
|
||||||
const int current_value = std::round(
|
const int current_value = std::round(
|
||||||
(m_config_option->m_integer_values[i] - m_config_option->m_integer_min_values[i]) /
|
(m_config_option->m_integer_values[i] - m_config_option->m_integer_min_values[i]) /
|
||||||
static_cast<double>(m_config_option->m_integer_max_values[i]));
|
static_cast<double>(m_config_option->m_integer_step_values[i]));
|
||||||
|
|
||||||
auto* const slider = new QSlider(Qt::Orientation::Horizontal);
|
auto* const slider = new QSlider(Qt::Orientation::Horizontal);
|
||||||
slider->setMinimum(0);
|
slider->setMinimum(0);
|
||||||
@ -289,7 +289,7 @@ u32 PostProcessingConfigWindow::ConfigGroup::AddInteger(PostProcessingConfigWind
|
|||||||
QObject::connect(slider, &QSlider::valueChanged,
|
QObject::connect(slider, &QSlider::valueChanged,
|
||||||
[this, parent](int value) { parent->UpdateInteger(this, value); });
|
[this, parent](int value) { parent->UpdateInteger(this, value); });
|
||||||
|
|
||||||
auto* const value_box = new QLineEdit(QString::number(current_value));
|
auto* const value_box = new QLineEdit(QString::number(m_config_option->m_integer_values[i]));
|
||||||
value_box->setEnabled(false);
|
value_box->setEnabled(false);
|
||||||
|
|
||||||
grid->addWidget(slider, row, 1);
|
grid->addWidget(slider, row, 1);
|
||||||
|
Reference in New Issue
Block a user