Qt: Add FPS target back to settings view

This commit is contained in:
Jeffrey Pfau 2014-12-23 00:26:47 -08:00
parent 2414df6527
commit 65bb4b4996
2 changed files with 50 additions and 11 deletions

View File

@ -23,6 +23,7 @@ SettingsView::SettingsView(ConfigController* controller, QWidget* parent)
loadSetting("videoSync", m_ui.videoSync);
loadSetting("audioSync", m_ui.audioSync);
loadSetting("frameskip", m_ui.frameskip);
loadSetting("fpsTarget", m_ui.fpsTarget);
loadSetting("lockAspectRatio", m_ui.lockAspectRatio);
loadSetting("rewindBufferInterval", m_ui.rewindInterval);
loadSetting("rewindBufferCapacity", m_ui.rewindCapacity);
@ -46,6 +47,7 @@ void SettingsView::updateConfig() {
saveSetting("videoSync", m_ui.videoSync);
saveSetting("audioSync", m_ui.audioSync);
saveSetting("frameskip", m_ui.frameskip);
saveSetting("fpsTarget", m_ui.fpsTarget);
saveSetting("lockAspectRatio", m_ui.lockAspectRatio);
saveSetting("rewindBufferInterval", m_ui.rewindInterval);
saveSetting("rewindBufferCapacity", m_ui.rewindCapacity);

View File

@ -6,10 +6,16 @@
<rect>
<x>0</x>
<y>0</y>
<width>339</width>
<height>503</height>
<width>350</width>
<height>501</height>
</rect>
</property>
<property name="sizePolicy">
<sizepolicy hsizetype="Fixed" vsizetype="Fixed">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="windowTitle">
<string>Settings</string>
</property>
@ -62,6 +68,9 @@
<property name="text">
<string>Use BIOS file</string>
</property>
<property name="checked">
<bool>true</bool>
</property>
</widget>
</item>
<item row="3" column="0" colspan="2">
@ -205,35 +214,35 @@
</item>
</layout>
</item>
<item row="8" column="0" colspan="2">
<item row="9" column="0" colspan="2">
<widget class="Line" name="line">
<property name="orientation">
<enum>Qt::Horizontal</enum>
</property>
</widget>
</item>
<item row="9" column="1">
<item row="10" column="1">
<widget class="QCheckBox" name="lockAspectRatio">
<property name="text">
<string>Lock aspect ratio</string>
</property>
</widget>
</item>
<item row="10" column="1">
<item row="11" column="1">
<widget class="QCheckBox" name="resampleVideo">
<property name="text">
<string>Resample video</string>
</property>
</widget>
</item>
<item row="11" column="0" colspan="2">
<item row="12" column="0" colspan="2">
<widget class="Line" name="line_3">
<property name="orientation">
<enum>Qt::Horizontal</enum>
</property>
</widget>
</item>
<item row="12" column="1">
<item row="13" column="1">
<widget class="QCheckBox" name="rewind">
<property name="enabled">
<bool>false</bool>
@ -243,14 +252,14 @@
</property>
</widget>
</item>
<item row="13" column="0">
<item row="14" column="0">
<widget class="QLabel" name="label_4">
<property name="text">
<string>Rewind interval:</string>
</property>
</widget>
</item>
<item row="13" column="1">
<item row="14" column="1">
<layout class="QHBoxLayout" name="horizontalLayout_12">
<item>
<widget class="QLabel" name="label_5">
@ -271,14 +280,14 @@
</item>
</layout>
</item>
<item row="14" column="0">
<item row="15" column="0">
<widget class="QLabel" name="label_8">
<property name="text">
<string>Rewind length:</string>
</property>
</widget>
</item>
<item row="14" column="1">
<item row="15" column="1">
<layout class="QHBoxLayout" name="horizontalLayout_13">
<item>
<widget class="QSpinBox" name="rewindCapacity"/>
@ -292,6 +301,34 @@
</item>
</layout>
</item>
<item row="8" column="0">
<widget class="QLabel" name="label_3">
<property name="text">
<string>FPS target:</string>
</property>
</widget>
</item>
<item row="8" column="1">
<layout class="QHBoxLayout" name="horizontalLayout_2">
<item>
<widget class="QSpinBox" name="fpsTarget">
<property name="maximum">
<number>240</number>
</property>
<property name="value">
<number>60</number>
</property>
</widget>
</item>
<item>
<widget class="QLabel" name="label_11">
<property name="text">
<string>frames per second</string>
</property>
</widget>
</item>
</layout>
</item>
</layout>
</item>
<item>