Permalink
Browse files

Merge pull request #7351 from Techjar/qt-settings-boot-crash-fix

Qt/AdvancedPane: Block signals during Update()
  • Loading branch information...
spycrab committed Aug 23, 2018
2 parents 74cbc6c + d72f4ed commit e92443e4674ad767354fc9dc822219b2af883ec9
Showing with 6 additions and 2 deletions.
  1. +6 −2 Source/Core/DolphinQt/Settings/AdvancedPane.cpp
@@ -9,6 +9,7 @@
#include <QGroupBox>
#include <QHBoxLayout>
#include <QLabel>
#include <QSignalBlocker>
#include <QSlider>
#include <QVBoxLayout>
#include <cmath>
@@ -138,8 +139,11 @@ void AdvancedPane::Update()
m_cpu_clock_override_slider->setEnabled(enable_cpu_clock_override_widgets);
m_cpu_clock_override_slider_label->setEnabled(enable_cpu_clock_override_widgets);
m_cpu_clock_override_slider->setValue(
static_cast<int>(std::round(std::log2f(SConfig::GetInstance().m_OCFactor) * 25.f + 100.f)));
{
const QSignalBlocker blocker(m_cpu_clock_override_slider);
m_cpu_clock_override_slider->setValue(
static_cast<int>(std::round(std::log2f(SConfig::GetInstance().m_OCFactor) * 25.f + 100.f)));
}
m_cpu_clock_override_slider_label->setText([] {
int core_clock = SystemTimers::GetTicksPerSecond() / std::pow(10, 6);

0 comments on commit e92443e

Please sign in to comment.