mirror of
				https://github.com/PabloMK7/citra.git
				synced 2025-10-31 05:40:04 +00:00 
			
		
		
		
	build: Clear out remaining compile warnings. (#6662)
This commit is contained in:
		
							parent
							
								
									2126c240cd
								
							
						
					
					
						commit
						13a8969824
					
				
					 26 changed files with 117 additions and 103 deletions
				
			
		|  | @ -290,6 +290,11 @@ elseif(WIN32) | |||
|     endif() | ||||
| endif() | ||||
| 
 | ||||
| if(ENABLE_SDL2) | ||||
|     target_link_libraries(citra-qt PRIVATE SDL2::SDL2) | ||||
|     target_compile_definitions(citra-qt PRIVATE HAVE_SDL2) | ||||
| endif() | ||||
| 
 | ||||
| create_target_directory_groups(citra-qt) | ||||
| 
 | ||||
| target_link_libraries(citra-qt PRIVATE audio_core citra_common citra_core input_common network video_core) | ||||
|  |  | |||
|  | @ -26,7 +26,7 @@ void HotkeyRegistry::SaveHotkeys() { | |||
| void HotkeyRegistry::LoadHotkeys() { | ||||
|     // Make sure NOT to use a reference here because it would become invalid once we call
 | ||||
|     // beginGroup()
 | ||||
|     for (const auto shortcut : UISettings::values.shortcuts) { | ||||
|     for (auto shortcut : UISettings::values.shortcuts) { | ||||
|         Hotkey& hk = hotkey_groups[shortcut.group][shortcut.name]; | ||||
|         if (!shortcut.shortcut.keyseq.isEmpty()) { | ||||
|             hk.keyseq = | ||||
|  |  | |||
|  | @ -115,6 +115,10 @@ __declspec(dllexport) unsigned long NvOptimusEnablement = 0x00000001; | |||
| } | ||||
| #endif | ||||
| 
 | ||||
| #ifdef HAVE_SDL2 | ||||
| #include <SDL.h> | ||||
| #endif | ||||
| 
 | ||||
| constexpr int default_mouse_timeout = 2500; | ||||
| 
 | ||||
| /**
 | ||||
|  | @ -967,7 +971,7 @@ void GMainWindow::ShowUpdaterWidgets() { | |||
| } | ||||
| #endif | ||||
| 
 | ||||
| #if defined(__unix__) && !defined(__APPLE__) | ||||
| #if defined(HAVE_SDL2) && defined(__unix__) && !defined(__APPLE__) | ||||
| static std::optional<QDBusObjectPath> HoldWakeLockLinux(u32 window_id = 0) { | ||||
|     if (!QDBusConnection::sessionBus().isConnected()) { | ||||
|         return {}; | ||||
|  | @ -1013,12 +1017,12 @@ void GMainWindow::PreventOSSleep() { | |||
|     SetThreadExecutionState(ES_CONTINUOUS | ES_SYSTEM_REQUIRED | ES_DISPLAY_REQUIRED); | ||||
| #elif defined(HAVE_SDL2) | ||||
|     SDL_DisableScreenSaver(); | ||||
| #ifdef __unix__ | ||||
| #if defined(__unix__) && !defined(__APPLE__) | ||||
|     auto reply = HoldWakeLockLinux(winId()); | ||||
|     if (reply) { | ||||
|         wake_lock = std::move(reply.value()); | ||||
|     } | ||||
| #endif // __unix__
 | ||||
| #endif // defined(__unix__) && !defined(__APPLE__)
 | ||||
| #endif // _WIN32
 | ||||
| } | ||||
| 
 | ||||
|  | @ -1027,11 +1031,11 @@ void GMainWindow::AllowOSSleep() { | |||
|     SetThreadExecutionState(ES_CONTINUOUS); | ||||
| #elif defined(HAVE_SDL2) | ||||
|     SDL_EnableScreenSaver(); | ||||
| #ifdef __unix__ | ||||
| #if defined(__unix__) && !defined(__APPLE__) | ||||
|     if (!wake_lock.path().isEmpty()) { | ||||
|         ReleaseWakeLockLinux(wake_lock); | ||||
|     } | ||||
| #endif // __unix__
 | ||||
| #endif // defined(__unix__) && !defined(__APPLE__)
 | ||||
| #endif // _WIN32
 | ||||
| } | ||||
| 
 | ||||
|  |  | |||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue