diff options
author | Chris Apers | 2007-02-18 12:21:25 +0000 |
---|---|---|
committer | Chris Apers | 2007-02-18 12:21:25 +0000 |
commit | 227d83ea6e0e26f28c0e8a15042b19dff5931802 (patch) | |
tree | 8902c37b0b58a1e8ae14b4cb4b3040b95924c8c1 | |
parent | 2bb012701a5791be0f9a6e98c4aad144125cb274 (diff) | |
download | scummvm-rg350-227d83ea6e0e26f28c0e8a15042b19dff5931802.tar.gz scummvm-rg350-227d83ea6e0e26f28c0e8a15042b19dff5931802.tar.bz2 scummvm-rg350-227d83ea6e0e26f28c0e8a15042b19dff5931802.zip |
Bad hack to make this engine works on PalmOS (compiler still seems to hate some global objects)
svn-id: r25684
-rw-r--r-- | engines/cine/cine.cpp | 9 | ||||
-rw-r--r-- | engines/cine/pal.cpp | 2 | ||||
-rw-r--r-- | engines/cine/various.cpp | 2 | ||||
-rw-r--r-- | engines/cine/various.h | 8 |
4 files changed, 17 insertions, 4 deletions
diff --git a/engines/cine/cine.cpp b/engines/cine/cine.cpp index 375258a666..5f2ded13a0 100644 --- a/engines/cine/cine.cpp +++ b/engines/cine/cine.cpp @@ -71,6 +71,12 @@ CineEngine::~CineEngine() { freePoldatDat(); freeErrmessDat(); } + + if (palFileHandleP); + delete palFileHandleP; + + if (partFileHandleP); + delete partFileHandleP; } int CineEngine::init() { @@ -79,6 +85,9 @@ int CineEngine::init() { GUIErrorMessage("No valid games were found in the specified directory."); return -1; } + + palFileHandleP = new Common::File(); + partFileHandleP = new Common::File(); // Initialize backend _system->beginGFXTransaction(); diff --git a/engines/cine/pal.cpp b/engines/cine/pal.cpp index eee9717b5b..6d3845ad78 100644 --- a/engines/cine/pal.cpp +++ b/engines/cine/pal.cpp @@ -34,7 +34,7 @@ byte palette256[256 * 3]; uint16 palEntriesCount; -Common::File palFileHandle; +Common::File *palFileHandleP = NULL; PalEntry *palPtr; diff --git a/engines/cine/various.cpp b/engines/cine/various.cpp index d6805c2ec4..c892e07ef7 100644 --- a/engines/cine/various.cpp +++ b/engines/cine/various.cpp @@ -60,7 +60,7 @@ void blitRawScreen(byte *frontBuffer) { gfxFlipRawPage(frontBuffer); } -Common::File partFileHandle; +Common::File *partFileHandleP = NULL; void waitPlayerInput(void) { } diff --git a/engines/cine/various.h b/engines/cine/various.h index dfd40fa7d1..9784f33d34 100644 --- a/engines/cine/various.h +++ b/engines/cine/various.h @@ -79,8 +79,12 @@ extern uint16 var3; extern uint16 var4; extern uint16 var5; -extern Common::File palFileHandle; -extern Common::File partFileHandle; +extern Common::File *palFileHandleP; +extern Common::File *partFileHandleP; + +#define palFileHandle (*palFileHandleP) +#define partFileHandle (*partFileHandleP) + void freeAnimDataTable(void); void mainLoopSub1(void); |