[Scummvm-cvs-logs] CVS: scummvm/gui newgui.cpp,1.111,1.112

Max Horn fingolfin at users.sourceforge.net
Sun May 15 10:09:39 CEST 2005


Update of /cvsroot/scummvm/scummvm/gui
In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv22357

Modified Files:
	newgui.cpp 
Log Message:
Add a switch which allows turning off the automatic GUI scaling easily

Index: newgui.cpp
===================================================================
RCS file: /cvsroot/scummvm/scummvm/gui/newgui.cpp,v
retrieving revision 1.111
retrieving revision 1.112
diff -u -d -r1.111 -r1.112
--- newgui.cpp	12 May 2005 15:46:02 -0000	1.111
+++ newgui.cpp	15 May 2005 17:08:44 -0000	1.112
@@ -49,8 +49,10 @@
 };
 
 
+#define USE_AUTO_SCALING	true
+
 // Constructor
-NewGui::NewGui() : _scaleEnable(true), _needRedraw(false),
+NewGui::NewGui() : _scaleEnable(USE_AUTO_SCALING), _needRedraw(false),
 	_stateIsSaved(false), _font(0), _cursorAnimateCounter(0), _cursorAnimateTimer(0) {
 
 	_system = &OSystem::instance();
@@ -106,7 +108,7 @@
 	// EVENT_SCREEN_CHANGED is received. However, not yet all backends support
 	// that event, so we also do it "manually" whenever a run loop is entered.
 	updateColors();
-	_scaleEnable = activeDialog->wantsScaling();
+	_scaleEnable = USE_AUTO_SCALING && activeDialog->wantsScaling();
 	updateScaleFactor();
 
 	if (!_stateIsSaved) {
@@ -125,7 +127,7 @@
 			for (int i = 0; i < _dialogStack.size(); i++) {
 				// For each dialog we draw we have to ensure the correct
 				// scaling mode is active.
-				_scaleEnable = _dialogStack[i]->wantsScaling();
+				_scaleEnable = USE_AUTO_SCALING && _dialogStack[i]->wantsScaling();
 				updateScaleFactor();
 				_dialogStack[i]->drawDialog();
 			}





More information about the Scummvm-git-logs mailing list