[Scummvm-cvs-logs] SF.net SVN: scummvm:[53112] scummvm/trunk/gui/message.cpp

eriktorbjorn at users.sourceforge.net eriktorbjorn at users.sourceforge.net
Sun Oct 10 12:11:34 CEST 2010


Revision: 53112
          http://scummvm.svn.sourceforge.net/scummvm/?rev=53112&view=rev
Author:   eriktorbjorn
Date:     2010-10-10 10:11:33 +0000 (Sun, 10 Oct 2010)

Log Message:
-----------
GUI: Clean up my previous commit.

Modified Paths:
--------------
    scummvm/trunk/gui/message.cpp

Modified: scummvm/trunk/gui/message.cpp
===================================================================
--- scummvm/trunk/gui/message.cpp	2010-10-10 10:00:55 UTC (rev 53111)
+++ scummvm/trunk/gui/message.cpp	2010-10-10 10:11:33 UTC (rev 53112)
@@ -58,10 +58,7 @@
 	int maxlineWidth = g_gui.getFont().wordWrapText(message, screenW - 2 * 20, lines);
 
 	// Calculate the desired dialog size (maxing out at 300*180 for now)
-	if (maxlineWidth > buttonWidth)
-		_w = maxlineWidth + 20;
-	else
-		_w = buttonWidth + 20;
+	_w = MAX(maxlineWidth, buttonWidth) + 20;
 	lineCount = lines.size();
 
 	_h = 16;


This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.




More information about the Scummvm-git-logs mailing list