aboutsummaryrefslogtreecommitdiff
path: root/engines
diff options
context:
space:
mode:
authorEinar Johan Trøan Sømåen2012-05-09 20:04:11 +0200
committerEinar Johan Trøan Sømåen2012-06-02 12:42:10 +0200
commitf07690cb9699b670198dce2445514967ccafb1cb (patch)
treece84489f8896756852efa4d1ae6442618dea4a26 /engines
parentb6f512f392ea6b3819f322949315a0f3f3a616e3 (diff)
downloadscummvm-rg350-f07690cb9699b670198dce2445514967ccafb1cb.tar.gz
scummvm-rg350-f07690cb9699b670198dce2445514967ccafb1cb.tar.bz2
scummvm-rg350-f07690cb9699b670198dce2445514967ccafb1cb.zip
WINTERMUTE: Make the messiest warnings warn just once.
Diffstat (limited to 'engines')
-rw-r--r--engines/wintermute/BFileManager.cpp2
-rw-r--r--engines/wintermute/BSurfaceSDL.cpp9
2 files changed, 9 insertions, 2 deletions
diff --git a/engines/wintermute/BFileManager.cpp b/engines/wintermute/BFileManager.cpp
index 0cc96323cc..24bc886e9c 100644
--- a/engines/wintermute/BFileManager.cpp
+++ b/engines/wintermute/BFileManager.cpp
@@ -820,7 +820,7 @@ CBFile *CBFileManager::OpenFileRaw(const char *Filename) {
return NULL;
}
}
- warning("BFileManager::OpenFileRaw(%s)", Filename);
+
CBDiskFile *DiskFile = new CBDiskFile(Game);
if (SUCCEEDED(DiskFile->Open(Filename))) return DiskFile;
diff --git a/engines/wintermute/BSurfaceSDL.cpp b/engines/wintermute/BSurfaceSDL.cpp
index e3853fb252..b976585b0b 100644
--- a/engines/wintermute/BSurfaceSDL.cpp
+++ b/engines/wintermute/BSurfaceSDL.cpp
@@ -135,7 +135,14 @@ HRESULT CBSurfaceSDL::Create(char *Filename, bool default_ck, byte ck_red, byte
//SDL_SetHint(SDL_HINT_RENDER_SCALE_QUALITY, "best"); //TODO
//_texture = SdlUtil::CreateTextureFromSurface(renderer->GetSdlRenderer(), surf);
- warning("Surface-textures not fully ported yet");
+
+ // This particular warning is rather messy, as this function is called a ton,
+ // thus we avoid printing it more than once.
+ static bool hasWarned = false;
+ if (!hasWarned) {
+ warning("Surface-textures not fully ported yet");
+ hasWarned = true;
+ }
#if 0
_texture = SDL_CreateTextureFromSurface(renderer->GetSdlRenderer(), surf);
if (!_texture) {