mirror of
				https://github.com/PabloMK7/citra.git
				synced 2025-10-31 05:40:04 +00:00 
			
		
		
		
	texture dump hotkey (ctrl+d)
address more comments
This commit is contained in:
		
							parent
							
								
									5450d4980d
								
							
						
					
					
						commit
						a458155f99
					
				
					 5 changed files with 27 additions and 12 deletions
				
			
		|  | @ -56,7 +56,7 @@ const std::array<std::array<int, 5>, Settings::NativeAnalog::NumAnalogs> Config: | |||
| // This must be in alphabetical order according to action name as it must have the same order as
 | ||||
| // UISetting::values.shortcuts, which is alphabetically ordered.
 | ||||
| // clang-format off
 | ||||
| const std::array<UISettings::Shortcut, 19> default_hotkeys{ | ||||
| const std::array<UISettings::Shortcut, 20> default_hotkeys{ | ||||
|     {{QStringLiteral("Advance Frame"),            QStringLiteral("Main Window"), {QStringLiteral("\\"), Qt::ApplicationShortcut}}, | ||||
|      {QStringLiteral("Capture Screenshot"),       QStringLiteral("Main Window"), {QStringLiteral("Ctrl+P"), Qt::ApplicationShortcut}}, | ||||
|      {QStringLiteral("Continue/Pause Emulation"), QStringLiteral("Main Window"), {QStringLiteral("F4"), Qt::WindowShortcut}}, | ||||
|  | @ -75,7 +75,8 @@ const std::array<UISettings::Shortcut, 19> default_hotkeys{ | |||
|      {QStringLiteral("Toggle Frame Advancing"),   QStringLiteral("Main Window"), {QStringLiteral("Ctrl+A"), Qt::ApplicationShortcut}}, | ||||
|      {QStringLiteral("Toggle Screen Layout"),     QStringLiteral("Main Window"), {QStringLiteral("F10"), Qt::WindowShortcut}}, | ||||
|      {QStringLiteral("Toggle Speed Limit"),       QStringLiteral("Main Window"), {QStringLiteral("Ctrl+Z"), Qt::ApplicationShortcut}}, | ||||
|      {QStringLiteral("Toggle Status Bar"),        QStringLiteral("Main Window"), {QStringLiteral("Ctrl+S"), Qt::WindowShortcut}}}}; | ||||
|      {QStringLiteral("Toggle Status Bar"),        QStringLiteral("Main Window"), {QStringLiteral("Ctrl+S"), Qt::WindowShortcut}}, | ||||
|      {QStringLiteral("Toggle Texture Dumping"),   QStringLiteral("Main Window"), {QStringLiteral("Ctrl+D"), Qt::ApplicationShortcut}}}}; | ||||
| // clang-format on
 | ||||
| 
 | ||||
| void Config::ReadValues() { | ||||
|  |  | |||
|  | @ -428,8 +428,11 @@ void GMainWindow::InitializeHotkeys() { | |||
|                 Settings::values.use_frame_limit = !Settings::values.use_frame_limit; | ||||
|                 UpdateStatusBar(); | ||||
|             }); | ||||
|     // We use "static" here in order to avoid capturing by lambda due to a MSVC bug, which makes the
 | ||||
|     // variable hold a garbage value after this function exits
 | ||||
|     connect(hotkey_registry.GetHotkey("Main Window", "Toggle Texture Dumping", this), | ||||
|             &QShortcut::activated, this, | ||||
|             [&] { Settings::values.dump_textures = !Settings::values.dump_textures; }); | ||||
|     // We use "static" here in order to avoid capturing by lambda due to a MSVC bug, which makes
 | ||||
|     // the variable hold a garbage value after this function exits
 | ||||
|     static constexpr u16 SPEED_LIMIT_STEP = 5; | ||||
|     connect(hotkey_registry.GetHotkey("Main Window", "Increase Speed Limit", this), | ||||
|             &QShortcut::activated, this, [&] { | ||||
|  |  | |||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue