[Scummvm-cvs-logs] CVS: scummvm/base main.cpp,1.23,1.24
Max Horn
fingolfin at users.sourceforge.net
Fri Nov 7 06:19:26 CET 2003
- Previous message: [Scummvm-cvs-logs] CVS: scummvm/queen logic.cpp,1.80,1.81 talk.cpp,1.31,1.32
- Next message: [Scummvm-cvs-logs] CVS: scummvm/gui TabWidget.cpp,1.5,1.6 TabWidget.h,1.2,1.3 dialog.cpp,1.38,1.39 widget.cpp,1.25,1.26 widget.h,1.30,1.31
- Messages sorted by:
[ date ]
[ thread ]
[ subject ]
[ author ]
Update of /cvsroot/scummvm/scummvm/base
In directory sc8-pr-cvs1:/tmp/cvs-serv2918
Modified Files:
main.cpp
Log Message:
err, *strnlen(,,3)* used to check for empty strings? I think not :-)
Index: main.cpp
===================================================================
RCS file: /cvsroot/scummvm/scummvm/base/main.cpp,v
retrieving revision 1.23
retrieving revision 1.24
diff -u -d -r1.23 -r1.24
--- main.cpp 7 Nov 2003 14:00:33 -0000 1.23
+++ main.cpp 7 Nov 2003 14:17:34 -0000 1.24
@@ -258,17 +258,15 @@
if (detector.detectMain()) {
// Set the window caption to the game name
- prop.caption = ConfMan.get("description", detector._targetName).c_str();
- if (strnlen(prop.caption, 3) == 0)
- prop.caption = detector._game.description;
- if (strnlen(prop.caption, 3) == 0)
- prop.caption = detector._targetName.c_str();
- if (strnlen(prop.caption, 3) != 0)
+ Common::String caption(ConfMan.get("description", detector._targetName));
+ if (caption.isEmpty() && detector._game.description)
+ caption = detector._game.description;
+ if (caption.isEmpty())
+ caption = detector._targetName;
+ if (!caption.isEmpty()) {
+ prop.caption = caption.c_str();
system->property(OSystem::PROP_SET_WINDOW_CAPTION, &prop);
-
- // FIXME: It seem not logical that we first might set the gfx mode to
- // 1x, and then immediately after might override it again. We probably
- // should combine both checks into one.
+ }
// See if the game should default to 1x scaler
if (!ConfMan.hasKey("gfx_mode", detector._targetName) &&
- Previous message: [Scummvm-cvs-logs] CVS: scummvm/queen logic.cpp,1.80,1.81 talk.cpp,1.31,1.32
- Next message: [Scummvm-cvs-logs] CVS: scummvm/gui TabWidget.cpp,1.5,1.6 TabWidget.h,1.2,1.3 dialog.cpp,1.38,1.39 widget.cpp,1.25,1.26 widget.h,1.30,1.31
- Messages sorted by:
[ date ]
[ thread ]
[ subject ]
[ author ]
More information about the Scummvm-git-logs
mailing list