[Scummvm-cvs-logs] CVS: scummvm/gui gui.cpp,1.12,1.13 message.cpp,1.1,1.2
Max Horn
fingolfin at users.sourceforge.net
Thu Sep 26 05:30:03 CEST 2002
- Previous message: [Scummvm-cvs-logs] CVS: scummvm/backends/wince findgame.cpp,1.1.1.1,1.2 pocketpc.cpp,1.3,1.4
- Next message: [Scummvm-cvs-logs] CVS: scummvm/common config-file.h,1.2,1.3 engine.cpp,1.5,1.6 gameDetector.cpp,1.9,1.10 main.cpp,1.7,1.8 str.cpp,1.6,1.7 str.h,1.4,1.5
- Messages sorted by:
[ date ]
[ thread ]
[ subject ]
[ author ]
Update of /cvsroot/scummvm/scummvm/gui
In directory usw-pr-cvs1:/tmp/cvs-serv14260/gui
Modified Files:
gui.cpp message.cpp
Log Message:
some fixes for the message dialog; added some comments
Index: gui.cpp
===================================================================
RCS file: /cvsroot/scummvm/scummvm/gui/gui.cpp,v
retrieving revision 1.12
retrieving revision 1.13
diff -u -d -r1.12 -r1.13
--- gui.cpp 22 Sep 2002 01:17:53 -0000 1.12
+++ gui.cpp 26 Sep 2002 12:29:10 -0000 1.13
@@ -596,10 +596,10 @@
_s->_mixer->setVolume(_s->_sound->_sound_volume_sfx);
_s->_mixer->setMusicVolume(_s->_sound->_sound_volume_music);
- scummcfg->setInt("master_volume", _s->_sound->_sound_volume_master);
- scummcfg->setInt("music_volume", _s->_sound->_sound_volume_music);
- scummcfg->setInt("sfx_volume", _s->_sound->_sound_volume_sfx);
- scummcfg->flush();
+ g_config->setInt("master_volume", _s->_sound->_sound_volume_master);
+ g_config->setInt("music_volume", _s->_sound->_sound_volume_music);
+ g_config->setInt("sfx_volume", _s->_sound->_sound_volume_sfx);
+ g_config->flush();
close();
} else {
Index: message.cpp
===================================================================
RCS file: /cvsroot/scummvm/scummvm/gui/message.cpp,v
retrieving revision 1.1
retrieving revision 1.2
diff -u -d -r1.1 -r1.2
--- message.cpp 26 Sep 2002 11:44:02 -0000 1.1
+++ message.cpp 26 Sep 2002 12:29:10 -0000 1.2
@@ -43,24 +43,24 @@
tmp = String(start, str - start);
lines.push_back(tmp);
lineWidth = _gui->getStringWidth(tmp);
- if (maxlineWidth < lineWidth)
+ if (maxlineWidth < lineWidth)
maxlineWidth = lineWidth;
start = str + 1;
}
++str;
}
- if (*start) {
- tmp = String(start, str - start);
- lines.push_back(tmp);
- lineWidth = _gui->getStringWidth(tmp);
- if (maxlineWidth < lineWidth)
- maxlineWidth = lineWidth;
- }
+
+ // Add in the last line
+ tmp = String(start, str - start);
+ lines.push_back(tmp);
+ lineWidth = _gui->getStringWidth(tmp);
+ if (maxlineWidth < lineWidth)
+ maxlineWidth = lineWidth;
// TODO - we should probably check for over/underflows here
_w = maxlineWidth + 20;
- _h = lines.size() * kLineHeight + 30;
+ _h = lines.size() * kLineHeight + 34;
_x = (320 - _w) / 2;
for (int i = 0; i < lines.size(); i++) {
@@ -69,5 +69,5 @@
}
// FIXME - the vertical position has to be adjusted
- addButton((_w - 54)/2, _h - 20, 54, 16, "OK", kCloseCmd, '\n'); // Confirm dialog
+ addButton((_w - 54)/2, _h - 24, 54, 16, "OK", kCloseCmd, '\n'); // Confirm dialog
}
- Previous message: [Scummvm-cvs-logs] CVS: scummvm/backends/wince findgame.cpp,1.1.1.1,1.2 pocketpc.cpp,1.3,1.4
- Next message: [Scummvm-cvs-logs] CVS: scummvm/common config-file.h,1.2,1.3 engine.cpp,1.5,1.6 gameDetector.cpp,1.9,1.10 main.cpp,1.7,1.8 str.cpp,1.6,1.7 str.h,1.4,1.5
- Messages sorted by:
[ date ]
[ thread ]
[ subject ]
[ author ]
More information about the Scummvm-git-logs
mailing list