(svn r2955) Fix: make ottd start with the last resolution you had set (custom) (win32)
authorDarkvater
Thu, 15 Sep 2005 22:42:59 +0000
changeset 2429 94cc76052d36
parent 2428 b2e4fb6665d0
child 2430 e1da54e6bf91
(svn r2955) Fix: make ottd start with the last resolution you had set (custom) (win32)
gfx.c
main_gui.c
--- a/gfx.c	Thu Sep 15 21:59:07 2005 +0000
+++ b/gfx.c	Thu Sep 15 22:42:59 2005 +0000
@@ -1974,8 +1974,6 @@
 	if ((_screen.width != w || _screen.height != h) && !_video_driver->change_resolution(w, h))
 		return false;
 
-	_cur_resolution[0] = w;
-	_cur_resolution[1] = h;
 	return true;
 }
 
--- a/main_gui.c	Thu Sep 15 21:59:07 2005 +0000
+++ b/main_gui.c	Thu Sep 15 22:42:59 2005 +0000
@@ -2478,6 +2478,8 @@
 
 void GameSizeChanged(void)
 {
+	_cur_resolution[0] = _screen.width;
+	_cur_resolution[1] = _screen.height;
 	RelocateAllWindows(_screen.width, _screen.height);
 	ScreenSizeChanged();
 	MarkWholeScreenDirty();