[Scummvm-cvs-logs] SF.net SVN: scummvm: [24488] scummvm/trunk
fingolfin at users.sourceforge.net
fingolfin at users.sourceforge.net
Tue Oct 24 11:44:31 CEST 2006
Revision: 24488
http://svn.sourceforge.net/scummvm/?rev=24488&view=rev
Author: fingolfin
Date: 2006-10-24 02:44:20 -0700 (Tue, 24 Oct 2006)
Log Message:
-----------
const correctness
Modified Paths:
--------------
scummvm/trunk/common/advancedDetector.cpp
scummvm/trunk/common/advancedDetector.h
scummvm/trunk/engines/agos/game.cpp
scummvm/trunk/engines/cine/detection.cpp
scummvm/trunk/engines/saga/game.cpp
scummvm/trunk/engines/scumm/dialogs.cpp
Modified: scummvm/trunk/common/advancedDetector.cpp
===================================================================
--- scummvm/trunk/common/advancedDetector.cpp 2006-10-24 08:11:43 UTC (rev 24487)
+++ scummvm/trunk/common/advancedDetector.cpp 2006-10-24 09:44:20 UTC (rev 24488)
@@ -36,7 +36,7 @@
String AdvancedDetector::getDescription(int num) {
char tmp[256];
- ADGameDescription *g = _gameDescriptions[num];
+ const ADGameDescription *g = _gameDescriptions[num];
snprintf(tmp, 256, "%s (%s %s/%s)", g->name, g->extra,
getPlatformDescription(g->platform), getLanguageDescription(g->language));
Modified: scummvm/trunk/common/advancedDetector.h
===================================================================
--- scummvm/trunk/common/advancedDetector.h 2006-10-24 08:11:43 UTC (rev 24487)
+++ scummvm/trunk/common/advancedDetector.h 2006-10-24 09:44:20 UTC (rev 24488)
@@ -42,7 +42,7 @@
};
typedef Array<int> ADList;
-typedef Array<ADGameDescription*> ADGameDescList;
+typedef Array<const ADGameDescription*> ADGameDescList;
class AdvancedDetector {
@@ -51,7 +51,7 @@
~AdvancedDetector() {};
- void registerGameDescriptions(Array<ADGameDescription*> gameDescriptions) {
+ void registerGameDescriptions(ADGameDescList gameDescriptions) {
_gameDescriptions = gameDescriptions;
}
Modified: scummvm/trunk/engines/agos/game.cpp
===================================================================
--- scummvm/trunk/engines/agos/game.cpp 2006-10-24 08:11:43 UTC (rev 24487)
+++ scummvm/trunk/engines/agos/game.cpp 2006-10-24 09:44:20 UTC (rev 24488)
@@ -205,7 +205,7 @@
// over again...
for (int i = 0; i < ARRAYSIZE(gameDescriptions); i++)
- descList.push_back((ADGameDescription *)&gameDescriptions[i]);
+ descList.push_back((const ADGameDescription *)&gameDescriptions[i]);
AdvDetector.registerGameDescriptions(descList);
AdvDetector.setFileMD5Bytes(FILE_MD5_BYTES);
@@ -239,7 +239,7 @@
Common::ADGameDescList descList;
for (int i = 0; i < ARRAYSIZE(gameDescriptions); i++)
- descList.push_back((ADGameDescription *)&gameDescriptions[i]);
+ descList.push_back((const ADGameDescription *)&gameDescriptions[i]);
AdvDetector.registerGameDescriptions(descList);
AdvDetector.setFileMD5Bytes(FILE_MD5_BYTES);
Modified: scummvm/trunk/engines/cine/detection.cpp
===================================================================
--- scummvm/trunk/engines/cine/detection.cpp 2006-10-24 08:11:43 UTC (rev 24487)
+++ scummvm/trunk/engines/cine/detection.cpp 2006-10-24 09:44:20 UTC (rev 24488)
@@ -662,7 +662,7 @@
// over again...
for (int i = 0; i < ARRAYSIZE(gameDescriptions); i++)
- descList.push_back((ADGameDescription *)&gameDescriptions[i]);
+ descList.push_back((const ADGameDescription *)&gameDescriptions[i]);
AdvDetector.registerGameDescriptions(descList);
AdvDetector.setFileMD5Bytes(FILE_MD5_BYTES);
@@ -696,7 +696,7 @@
Common::ADGameDescList descList;
for (int i = 0; i < ARRAYSIZE(gameDescriptions); i++)
- descList.push_back((ADGameDescription *)&gameDescriptions[i]);
+ descList.push_back((const ADGameDescription *)&gameDescriptions[i]);
AdvDetector.registerGameDescriptions(descList);
AdvDetector.setFileMD5Bytes(FILE_MD5_BYTES);
Modified: scummvm/trunk/engines/saga/game.cpp
===================================================================
--- scummvm/trunk/engines/saga/game.cpp 2006-10-24 08:11:43 UTC (rev 24487)
+++ scummvm/trunk/engines/saga/game.cpp 2006-10-24 09:44:20 UTC (rev 24488)
@@ -136,7 +136,7 @@
for (int i = 0; i < ARRAYSIZE(gameDescriptions); i++)
- descList.push_back((ADGameDescription *)&gameDescriptions[i]);
+ descList.push_back((const ADGameDescription *)&gameDescriptions[i]);
AdvDetector.registerGameDescriptions(descList);
AdvDetector.setFileMD5Bytes(FILE_MD5_BYTES);
@@ -181,7 +181,7 @@
Common::ADGameDescList descList;
for (int i = 0; i < ARRAYSIZE(gameDescriptions); i++)
- descList.push_back((ADGameDescription *)&gameDescriptions[i]);
+ descList.push_back((const ADGameDescription *)&gameDescriptions[i]);
AdvDetector.registerGameDescriptions(descList);
AdvDetector.setFileMD5Bytes(FILE_MD5_BYTES);
Modified: scummvm/trunk/engines/scumm/dialogs.cpp
===================================================================
--- scummvm/trunk/engines/scumm/dialogs.cpp 2006-10-24 08:11:43 UTC (rev 24487)
+++ scummvm/trunk/engines/scumm/dialogs.cpp 2006-10-24 09:44:20 UTC (rev 24488)
@@ -778,13 +778,13 @@
const Common::String InfoDialog::queryResString(int stringno) {
byte buf[256];
- byte *result;
+ const byte *result;
if (stringno == 0)
return String();
if (_vm->_game.version == 8)
- result = (byte *)string_map_table_v8[stringno - 1].string;
+ result = (const byte *)string_map_table_v8[stringno - 1].string;
else if (_vm->_game.version == 7)
result = _vm->getStringAddressVar(string_map_table_v7[stringno - 1].num);
else if (_vm->_game.version == 6)
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