mirror of
				https://github.com/encounter/SDL.git
				synced 2025-10-25 19:20:25 +00:00 
			
		
		
		
	WinRT: minor function and variable name cleanup
This commit is contained in:
		
							parent
							
								
									065b2cf470
								
							
						
					
					
						commit
						80abfc4d60
					
				| @ -300,12 +300,12 @@ void SDL_WinRTApp::OnWindowSizeChanged(CoreWindow^ sender, WindowSizeChangedEven | |||||||
|         // window-resize event as it appeared the SDL window didn't change
 |         // window-resize event as it appeared the SDL window didn't change
 | ||||||
|         // size, and the Direct3D 11.1 renderer wouldn't resize its swap
 |         // size, and the Direct3D 11.1 renderer wouldn't resize its swap
 | ||||||
|         // chain.
 |         // chain.
 | ||||||
|         SDL_DisplayMode newDisplayMode = GetMainDisplayMode(); |         SDL_DisplayMode resizedDisplayMode = CalcCurrentDisplayMode(); | ||||||
|         m_sdlVideoDevice->displays[0].current_mode = newDisplayMode; |         m_sdlVideoDevice->displays[0].current_mode = resizedDisplayMode; | ||||||
|         m_sdlVideoDevice->displays[0].desktop_mode = newDisplayMode; |         m_sdlVideoDevice->displays[0].desktop_mode = resizedDisplayMode; | ||||||
|         m_sdlVideoDevice->displays[0].display_modes[0] = newDisplayMode; |         m_sdlVideoDevice->displays[0].display_modes[0] = resizedDisplayMode; | ||||||
| 
 | 
 | ||||||
|         m_sdlWindowData->sdlWindow->fullscreen_mode = newDisplayMode; |         m_sdlWindowData->sdlWindow->fullscreen_mode = resizedDisplayMode; | ||||||
| 
 | 
 | ||||||
|         // Send the window-resize event to the rest of SDL, and to apps:
 |         // Send the window-resize event to the rest of SDL, and to apps:
 | ||||||
|         const int windowWidth = (int) ceil(args->Size.Width); |         const int windowWidth = (int) ceil(args->Size.Width); | ||||||
| @ -469,7 +469,7 @@ void SDL_WinRTApp::OnResuming(Platform::Object^ sender, Platform::Object^ args) | |||||||
|     } |     } | ||||||
| } | } | ||||||
| 
 | 
 | ||||||
| SDL_DisplayMode SDL_WinRTApp::GetMainDisplayMode() | SDL_DisplayMode SDL_WinRTApp::CalcCurrentDisplayMode() | ||||||
| { | { | ||||||
|     // Create an empty, zeroed-out display mode:
 |     // Create an empty, zeroed-out display mode:
 | ||||||
|     SDL_DisplayMode mode; |     SDL_DisplayMode mode; | ||||||
|  | |||||||
| @ -16,7 +16,7 @@ public: | |||||||
| 
 | 
 | ||||||
| internal: | internal: | ||||||
|     // SDL-specific methods
 |     // SDL-specific methods
 | ||||||
|     SDL_DisplayMode GetMainDisplayMode(); |     SDL_DisplayMode CalcCurrentDisplayMode(); | ||||||
|     void PumpEvents(); |     void PumpEvents(); | ||||||
|     const SDL_WindowData * GetSDLWindowData() const; |     const SDL_WindowData * GetSDLWindowData() const; | ||||||
|     bool HasSDLWindowData() const; |     bool HasSDLWindowData() const; | ||||||
|  | |||||||
| @ -134,7 +134,7 @@ WINRT_VideoInit(_THIS) | |||||||
| static int | static int | ||||||
| WINRT_InitModes(_THIS) | WINRT_InitModes(_THIS) | ||||||
| { | { | ||||||
|     SDL_DisplayMode mode = SDL_WinRTGlobalApp->GetMainDisplayMode(); |     SDL_DisplayMode mode = SDL_WinRTGlobalApp->CalcCurrentDisplayMode(); | ||||||
|     if (SDL_AddBasicVideoDisplay(&mode) < 0) { |     if (SDL_AddBasicVideoDisplay(&mode) < 0) { | ||||||
|         return -1; |         return -1; | ||||||
|     } |     } | ||||||
|  | |||||||
		Loading…
	
	
			
			x
			
			
		
	
		Reference in New Issue
	
	Block a user