(svn r2955) Fix: make ottd start with the last resolution you had set (custom) (win32)
This commit is contained in:
		
							
								
								
									
										2
									
								
								gfx.c
									
									
									
									
									
								
							
							
						
						
									
										2
									
								
								gfx.c
									
									
									
									
									
								
							@@ -1974,8 +1974,6 @@ bool ChangeResInGame(int w, int h)
 | 
				
			|||||||
	if ((_screen.width != w || _screen.height != h) && !_video_driver->change_resolution(w, h))
 | 
						if ((_screen.width != w || _screen.height != h) && !_video_driver->change_resolution(w, h))
 | 
				
			||||||
		return false;
 | 
							return false;
 | 
				
			||||||
 | 
					
 | 
				
			||||||
	_cur_resolution[0] = w;
 | 
					 | 
				
			||||||
	_cur_resolution[1] = h;
 | 
					 | 
				
			||||||
	return true;
 | 
						return true;
 | 
				
			||||||
}
 | 
					}
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 
 | 
				
			|||||||
@@ -2478,6 +2478,8 @@ void ShowVitalWindows(void)
 | 
				
			|||||||
 | 
					
 | 
				
			||||||
void GameSizeChanged(void)
 | 
					void GameSizeChanged(void)
 | 
				
			||||||
{
 | 
					{
 | 
				
			||||||
 | 
						_cur_resolution[0] = _screen.width;
 | 
				
			||||||
 | 
						_cur_resolution[1] = _screen.height;
 | 
				
			||||||
	RelocateAllWindows(_screen.width, _screen.height);
 | 
						RelocateAllWindows(_screen.width, _screen.height);
 | 
				
			||||||
	ScreenSizeChanged();
 | 
						ScreenSizeChanged();
 | 
				
			||||||
	MarkWholeScreenDirty();
 | 
						MarkWholeScreenDirty();
 | 
				
			||||||
 
 | 
				
			|||||||
		Reference in New Issue
	
	Block a user