mirror of
https://github.com/ksherlock/mpw.git
synced 2024-11-25 04:31:52 +00:00
MoveHHi
This commit is contained in:
parent
0d165d9525
commit
bf47a41ecc
@ -201,6 +201,29 @@ namespace MM
|
||||
return 0x0f0000;
|
||||
}
|
||||
|
||||
uint16_t MoveHHi(uint16_t trap)
|
||||
{
|
||||
/*
|
||||
* on entry:
|
||||
* A0: Handle to move
|
||||
*
|
||||
* on exit:
|
||||
* D0: Result code.
|
||||
*
|
||||
*/
|
||||
|
||||
uint32_t theHandle = cpuGetAReg(0);
|
||||
|
||||
Log("%04x MoveHHi(%08x)\n", trap, theHandle);
|
||||
|
||||
// check if it's valid.
|
||||
|
||||
auto iter = HandleMap.find(theHandle);
|
||||
if (iter == HandleMap.end()) return SetMemError(memWZErr);
|
||||
|
||||
return SetMemError(0);
|
||||
}
|
||||
|
||||
|
||||
|
||||
#pragma mark Pointers
|
||||
|
@ -45,6 +45,9 @@ namespace MM
|
||||
|
||||
uint16_t HLock(uint16_t trap);
|
||||
uint16_t HUnlock(uint16_t trap);
|
||||
|
||||
uint16_t MoveHHi(uint16_t trap);
|
||||
|
||||
}
|
||||
|
||||
|
||||
|
@ -84,6 +84,10 @@ namespace ToolBox {
|
||||
d0 = MM::CompactMem(trap);
|
||||
break;
|
||||
|
||||
// MoveHHi (h: Handle);
|
||||
case 0xa064:
|
||||
d0 = MM::MoveHHi(trap);
|
||||
break;
|
||||
|
||||
// ReadDateTime (VAR sees: LONGINT) : OSErr;
|
||||
case 0xa039:
|
||||
|
Loading…
Reference in New Issue
Block a user