Qt: More sizing + improve hotkeys code

There were other sizing issues with region and CRC that are now have better width. Taking the liberty to organise the hotkeys as it is laid on the GUI-level + adding missing hotkeys. There is still much work to be done.
This commit is contained in:
RedDevilus 2022-02-04 00:53:47 +01:00 committed by refractionpcsx2
parent ee4f498a13
commit f6d49eb5b9
4 changed files with 36 additions and 13 deletions

View File

@ -324,9 +324,9 @@ void GameListWidget::resizeTableViewColumnsToFit()
80, // code
-1, // title
-1, // file title
50, // crc
60, // crc
80, // size
50, // region
60, // region
100 // compatibility
});
}

View File

@ -186,7 +186,7 @@
</widget>
<widget class="QToolBar" name="toolBar">
<property name="windowTitle">
<string>toolBar</string>
<string>Toolbar</string>
</property>
<property name="iconSize">
<size>

View File

@ -54,7 +54,7 @@
<item>
<widget class="QCheckBox" name="enableSDLEnhancedMode">
<property name="text">
<string>Dualshock 4 / Dualsense Enhanced Mode</string>
<string>DualShock 4 / DualSense Enhanced Mode</string>
</property>
</widget>
</item>

View File

@ -184,11 +184,13 @@ void PAD::SetDefaultConfig(SettingsInterface& si)
si.ClearSection(StringUtil::StdStringFromFormat("Pad%u", i + 1).c_str());
si.ClearSection("Hotkeys");
// PCSX2 Controller Settings - Global Settings
si.SetBoolValue("InputSources", "SDL", true);
si.SetBoolValue("InputSources", "SDLControllerEnhancedMode", false);
si.SetBoolValue("InputSources", "XInput", false);
// PCSX2 Controller Settings - Controller 1 / Controller 2 / ...
si.SetStringValue("Pad1", "Type", "DualShock2");
si.SetStringValue("Pad1", "Up", "Keyboard/Up");
si.SetStringValue("Pad1", "Right", "Keyboard/Right");
@ -214,16 +216,37 @@ void PAD::SetDefaultConfig(SettingsInterface& si)
si.SetStringValue("Pad1", "R3", "Keyboard/4");
si.SetStringValue("Pad1", "Start", "Keyboard/Return");
si.SetStringValue("Pad1", "Select", "Keyboard/Backspace");
si.SetStringValue("Hotkeys", "ToggleTurbo", "Keyboard/Tab");
si.SetStringValue("Hotkeys", "ToggleFrameLimit", "Keyboard/F4");
si.SetStringValue("Hotkeys", "ToggleSoftwareRendering", "Keyboard/F9");
si.SetStringValue("Hotkeys", "TogglePause", "Keyboard/Space");
si.SetStringValue("Hotkeys", "ToggleFullscreen", "Keyboard/Alt & Keyboard/Return");
// PCSX2 Controller Settings - Hotkeys
// PCSX2 Controller Settings - Hotkeys - General
si.SetStringValue("Hotkeys", "Screenshot", "Keyboard/F8");
si.SetStringValue("Hotkeys", "ToggleFullscreen", "Keyboard/Alt & Keyboard/Return");
// PCSX2 Controller Settings - Hotkeys - Graphics
si.SetStringValue("Hotkeys", "CycleAspectRatio", "Keyboard/F6");
si.SetStringValue("Hotkeys", "CycleMipmapMode", "Keyboard/Insert");
si.SetStringValue("Hotkeys", "CycleInterlaceMode", "Keyboard/F5");
// si.SetStringValue("Hotkeys", "DecreaseUpscaleMultiplier", "Keyboard"); TBD
// si.SetStringValue("Hotkeys", "IncreaseUpscaleMultiplier", "Keyboard"); TBD
si.SetStringValue("Hotkeys", "ToggleSoftwareRendering", "Keyboard/F9");
si.SetStringValue("Hotkeys", "ZoomIn", "Keyboard/Control & Keyboard/Plus");
si.SetStringValue("Hotkeys", "ZoomOut", "Keyboard/Control & Keyboard/Minus");
// Missing hotkey for resetting zoom back to 100 with Keyboard/Control & Keyboard/Asterisk
// PCSX2 Controller Settings - Hotkeys - Save States
si.SetStringValue("Hotkeys", "LoadStateFromSlot", "Keyboard/F3");
si.SetStringValue("Hotkeys", "SaveStateToSlot", "Keyboard/F1");
si.SetStringValue("Hotkeys", "NextSaveStateSlot", "Keyboard/F2");
si.SetStringValue("Hotkeys", "LoadStateFromSlot", "Keyboard/F3");
si.SetStringValue("Hotkeys", "PreviousSaveStateSlot", "Keyboard/Shift & Keyboard/F2");
// PCSX2 Controller Settings - Hotkeys - System
// si.SetStringValue("Hotkeys", "DecreaseSpeed", "Keyboard"); TBD
// si.SetStringValue("Hotkeys", "IncreaseSpeed", "Keyboard"); TBD
si.SetStringValue("Hotkeys", "ToggleFrameLimit", "Keyboard/F4");
si.SetStringValue("Hotkeys", "TogglePause", "Keyboard/Space");
si.SetStringValue("Hotkeys", "ToggleSlowMotion", "Keyboard/Shift & Keyboard/Backtab");
si.SetStringValue("Hotkeys", "ToggleTurbo", "Keyboard/Tab");
}
void PAD::Update()