diff options
author | Bertrand Augereau | 2011-11-28 11:28:59 +0100 |
---|---|---|
committer | Bertrand Augereau | 2011-11-28 15:47:24 +0100 |
commit | 87571f0c8c9dca4699750adf7771e85d203bf022 (patch) | |
tree | b25c5ba0a87743b6b010ae6434eb3fa8df0ae80c | |
parent | 00eaf55fdfdb447a4071eb82eca54764aefbfffc (diff) | |
download | scummvm-rg350-87571f0c8c9dca4699750adf7771e85d203bf022.tar.gz scummvm-rg350-87571f0c8c9dca4699750adf7771e85d203bf022.tar.bz2 scummvm-rg350-87571f0c8c9dca4699750adf7771e85d203bf022.zip |
DREAMWEB: 'viewfolder' ported to C++
-rwxr-xr-x | devtools/tasmrecover/tasm-recover | 1 | ||||
-rw-r--r-- | engines/dreamweb/dreamgen.cpp | 31 | ||||
-rw-r--r-- | engines/dreamweb/dreamgen.h | 5 | ||||
-rw-r--r-- | engines/dreamweb/stubs.h | 1 | ||||
-rw-r--r-- | engines/dreamweb/use.cpp | 34 |
5 files changed, 38 insertions, 34 deletions
diff --git a/devtools/tasmrecover/tasm-recover b/devtools/tasmrecover/tasm-recover index adcd5a2bc4..9a3354c538 100755 --- a/devtools/tasmrecover/tasm-recover +++ b/devtools/tasmrecover/tasm-recover @@ -301,6 +301,7 @@ generator = cpp(context, "DreamGen", blacklist = [ 'restoreall', 'restorereels', 'allocateload', + 'viewfolder', ], skip_output = [ # These functions are processed but not output 'dreamweb', diff --git a/engines/dreamweb/dreamgen.cpp b/engines/dreamweb/dreamgen.cpp index cbbfc6df88..1e629a8ca9 100644 --- a/engines/dreamweb/dreamgen.cpp +++ b/engines/dreamweb/dreamgen.cpp @@ -9760,37 +9760,6 @@ void DreamGenContext::loadmenu() { loadintotemp2(); } -void DreamGenContext::viewfolder() { - STACK_CHECK; - data.byte(kManisoffscreen) = 1; - getridofall(); - loadfolder(); - data.byte(kFolderpage) = 0; - showfolder(); - worktoscreenm(); - data.byte(kGetback) = 0; -folderloop: - delpointer(); - readmouse(); - showpointer(); - vsync(); - dumppointer(); - dumptextline(); - bx = offset_folderlist; - checkcoords(); - _cmp(data.byte(kGetback), 0); - if (flags.z()) - goto folderloop; - data.byte(kManisoffscreen) = 0; - getridoftemp(); - getridoftemp2(); - getridoftemp3(); - getridoftempcharset(); - restoreall(); - redrawmainscrn(); - worktoscreenm(); -} - void DreamGenContext::nextfolder() { STACK_CHECK; _cmp(data.byte(kFolderpage), 12); diff --git a/engines/dreamweb/dreamgen.h b/engines/dreamweb/dreamgen.h index f3c9873b13..8e1a8074e5 100644 --- a/engines/dreamweb/dreamgen.h +++ b/engines/dreamweb/dreamgen.h @@ -184,7 +184,6 @@ public: static const uint16 addr_lastfolder = 0xc7c0; static const uint16 addr_folderhints = 0xc7bc; static const uint16 addr_nextfolder = 0xc7b8; - static const uint16 addr_viewfolder = 0xc7b4; static const uint16 addr_loadmenu = 0xc7b0; static const uint16 addr_showmenu = 0xc7ac; static const uint16 addr_dumpmenu = 0xc79c; @@ -1273,7 +1272,6 @@ public: //void hangoncurs(); //void getblockofpixel(); //void kernchars(); - //void printcurs(); //void convertkey(); void outofopen(); //void dealwithspecial(); @@ -1497,7 +1495,7 @@ public: //void readmouse2(); //void zoom(); void outofinv(); - void viewfolder(); + //void printcurs(); //void walking(); void diarykeyp(); //void readabyte(); @@ -1525,6 +1523,7 @@ public: void purgealocation(); void sparkydrip(); //void paltostartpal(); + //void viewfolder(); void getridofpit(); //void convnum(); //void checkifset(); diff --git a/engines/dreamweb/stubs.h b/engines/dreamweb/stubs.h index a09cd64896..029b99a93e 100644 --- a/engines/dreamweb/stubs.h +++ b/engines/dreamweb/stubs.h @@ -354,4 +354,5 @@ void loadRoomData(const Room* room, bool skipDat); void restoreall(); void restorereels(); + void viewfolder(); diff --git a/engines/dreamweb/use.cpp b/engines/dreamweb/use.cpp index 278767aa7c..6e2de2e173 100644 --- a/engines/dreamweb/use.cpp +++ b/engines/dreamweb/use.cpp @@ -194,5 +194,39 @@ void DreamGenContext::showseconduse() { hangonp(400); } +void DreamGenContext::viewfolder() { + data.byte(kManisoffscreen) = 1; + getridofall(); + loadfolder(); + data.byte(kFolderpage) = 0; + showfolder(); + worktoscreenm(); + data.byte(kGetback) = 0; + do { + delpointer(); + readmouse(); + showpointer(); + vsync(); + dumppointer(); + dumptextline(); + RectWithCallback folderlist[] = { + { 280,320,160,200,&DreamGenContext::quitkey }, + { 143,300,6,194,&DreamGenContext::nextfolder }, + { 0,143,6,194,&DreamGenContext::lastfolder }, + { 0,320,0,200,&DreamGenContext::blank }, + { 0xFFFF,0,0,0,0 } + }; + checkcoords(folderlist); + } while (data.byte(kGetback) == 0); + data.byte(kManisoffscreen) = 0; + getridoftemp(); + getridoftemp2(); + getridoftemp3(); + getridoftempcharset(); + restoreall(); + redrawmainscrn(); + worktoscreenm(); +} + } /*namespace dreamgen */ |