mirror of
https://github.com/elasota/Aerofoil.git
synced 2025-12-14 03:59:36 +00:00
API cleanup, fix some lingering InvalWindowRects
This commit is contained in:
@@ -61,7 +61,7 @@ void DoAbout (void)
|
|||||||
{
|
{
|
||||||
messagePtr = (**version).shortVersion + 1 + (**version).shortVersion[0];
|
messagePtr = (**version).shortVersion + 1 + (**version).shortVersion[0];
|
||||||
|
|
||||||
BlockMove((Ptr)messagePtr, &longVersion, ((UInt8)*messagePtr) + 1);
|
memcpy(&longVersion, messagePtr, ((UInt8)*messagePtr) + 1);
|
||||||
SetDialogString(aboutDialog, kTextItemVers, longVersion);
|
SetDialogString(aboutDialog, kTextItemVers, longVersion);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -56,6 +56,7 @@ PLError_t DoOpenDocAE (const AppleEvent *theAE, AppleEvent *reply, UInt32 ref)
|
|||||||
DescType returnedType;
|
DescType returnedType;
|
||||||
PLError_t theErr, whoCares;
|
PLError_t theErr, whoCares;
|
||||||
short i;
|
short i;
|
||||||
|
bool redrawMainWindow = false;
|
||||||
|
|
||||||
theErr = AEGetParamDesc(theAE, keyDirectObject, typeAEList, &docList);
|
theErr = AEGetParamDesc(theAE, keyDirectObject, typeAEList, &docList);
|
||||||
if (theErr != PLErrors::kNone)
|
if (theErr != PLErrors::kNone)
|
||||||
@@ -112,7 +113,7 @@ PLError_t DoOpenDocAE (const AppleEvent *theAE, AppleEvent *reply, UInt32 ref)
|
|||||||
Rect updateRect;
|
Rect updateRect;
|
||||||
|
|
||||||
SetRect(&updateRect, splashOriginH + 474, splashOriginV + 304, splashOriginH + 474 + 166, splashOriginV + 304 + 12);
|
SetRect(&updateRect, splashOriginH + 474, splashOriginV + 304, splashOriginH + 474 + 166, splashOriginV + 304 + 12);
|
||||||
InvalWindowRect(mainWindow, &updateRect);
|
redrawMainWindow = true;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -120,6 +121,9 @@ PLError_t DoOpenDocAE (const AppleEvent *theAE, AppleEvent *reply, UInt32 ref)
|
|||||||
}
|
}
|
||||||
#endif
|
#endif
|
||||||
whoCares = AEDisposeDesc(&docList);
|
whoCares = AEDisposeDesc(&docList);
|
||||||
|
|
||||||
|
if (redrawMainWindow)
|
||||||
|
UpdateMainWindow();
|
||||||
|
|
||||||
return theErr;
|
return theErr;
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -648,8 +648,8 @@ void CheckDuplicateFloorSuite (void)
|
|||||||
{
|
{
|
||||||
bitPlace = (((*thisHouse)->rooms[i].floor + 7) * 128) +
|
bitPlace = (((*thisHouse)->rooms[i].floor + 7) * 128) +
|
||||||
(*thisHouse)->rooms[i].suite;
|
(*thisHouse)->rooms[i].suite;
|
||||||
if ((bitPlace < 0) || (bitPlace >= 8192))
|
//if ((bitPlace < 0) || (bitPlace >= 8192))
|
||||||
DebugStr(PSTR("Blew array"));
|
// DebugStr(PSTR("Blew array"));
|
||||||
if (pidgeonHoles[bitPlace] != 0)
|
if (pidgeonHoles[bitPlace] != 0)
|
||||||
{
|
{
|
||||||
houseErrors++;
|
houseErrors++;
|
||||||
|
|||||||
@@ -173,7 +173,7 @@ void VariableInit (void)
|
|||||||
fadeInSequence[14] = 9;
|
fadeInSequence[14] = 9;
|
||||||
fadeInSequence[15] = 10;
|
fadeInSequence[15] = 10;
|
||||||
|
|
||||||
doubleTime = GetDblTime();
|
doubleTime = 30; // PL_NotYetImplemented_TODO: Get this from the system settings
|
||||||
|
|
||||||
mirrorRects = nil;
|
mirrorRects = nil;
|
||||||
mainWindow = nil;
|
mainWindow = nil;
|
||||||
|
|||||||
@@ -206,7 +206,6 @@ void UpdateLinkWindow (void)
|
|||||||
return;
|
return;
|
||||||
|
|
||||||
SetPortWindowPort(linkWindow);
|
SetPortWindowPort(linkWindow);
|
||||||
DrawControls(linkWindow);
|
|
||||||
UpdateLinkControl();
|
UpdateLinkControl();
|
||||||
#endif
|
#endif
|
||||||
}
|
}
|
||||||
@@ -259,6 +258,8 @@ void OpenLinkWindow (void)
|
|||||||
linkObject = 255;
|
linkObject = 255;
|
||||||
|
|
||||||
isLinkOpen = true;
|
isLinkOpen = true;
|
||||||
|
|
||||||
|
UpdateLinkWindow();
|
||||||
}
|
}
|
||||||
#endif
|
#endif
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -187,7 +187,7 @@ void UpdateClipboardMenus (void)
|
|||||||
mm->SetItemText(houseMenu, iCopy - 1, title);
|
mm->SetItemText(houseMenu, iCopy - 1, title);
|
||||||
GetLocalizedString(38, title);
|
GetLocalizedString(38, title);
|
||||||
mm->SetItemText(houseMenu, iClear - 1, title);
|
mm->SetItemText(houseMenu, iClear - 1, title);
|
||||||
mm->SetItemEnabled(houseMenu, iDuplicate - 1, false);
|
mm->SetItemEnabled(houseMenu, iDuplicate - 1, true);
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
|
|||||||
@@ -222,7 +222,7 @@ PLError_t LoadMusicSounds (void)
|
|||||||
if (theMusicData[i] == nil)
|
if (theMusicData[i] == nil)
|
||||||
return PLErrors::kOutOfMemory;
|
return PLErrors::kOutOfMemory;
|
||||||
|
|
||||||
BlockMove(static_cast<Byte*>(*theSound), theMusicData[i], soundDataSize);
|
memcpy(theMusicData[i], static_cast<Byte*>(*theSound), soundDataSize);
|
||||||
theSound.Dispose();
|
theSound.Dispose();
|
||||||
}
|
}
|
||||||
return (theErr);
|
return (theErr);
|
||||||
|
|||||||
@@ -306,7 +306,7 @@ void DragHandle (Window *window, DrawSurface *surface, Point where)
|
|||||||
DragMarqueeHandle(window, surface, where, &hDelta);
|
DragMarqueeHandle(window, surface, where, &hDelta);
|
||||||
thisRoom->objects[objActive].data.f.length = hDelta;
|
thisRoom->objects[objActive].data.f.length = hDelta;
|
||||||
whoCares = KeepObjectLegal();
|
whoCares = KeepObjectLegal();
|
||||||
InvalWindowRect(mainWindow, &mainWindowRect);
|
redrawMainWindow = true;
|
||||||
GetThisRoomsObjRects();
|
GetThisRoomsObjRects();
|
||||||
ReadyBackground(thisRoom->background, thisRoom->tiles);
|
ReadyBackground(thisRoom->background, thisRoom->tiles);
|
||||||
DrawThisRoomsObjects();
|
DrawThisRoomsObjects();
|
||||||
@@ -1150,6 +1150,7 @@ void DuplicateObject (void)
|
|||||||
Point placePt;
|
Point placePt;
|
||||||
short direction, dist;
|
short direction, dist;
|
||||||
Boolean handled;
|
Boolean handled;
|
||||||
|
bool redrawMainWindow = false;
|
||||||
|
|
||||||
tempObject = thisRoom->objects[objActive];
|
tempObject = thisRoom->objects[objActive];
|
||||||
|
|
||||||
@@ -1313,7 +1314,7 @@ void DuplicateObject (void)
|
|||||||
ReadyBackground(thisRoom->background, thisRoom->tiles);
|
ReadyBackground(thisRoom->background, thisRoom->tiles);
|
||||||
GetThisRoomsObjRects();
|
GetThisRoomsObjRects();
|
||||||
DrawThisRoomsObjects();
|
DrawThisRoomsObjects();
|
||||||
InvalWindowRect(mainWindow, &mainWindowRect);
|
redrawMainWindow = true;
|
||||||
|
|
||||||
if (handled)
|
if (handled)
|
||||||
{
|
{
|
||||||
@@ -1323,6 +1324,9 @@ void DuplicateObject (void)
|
|||||||
else
|
else
|
||||||
StartMarquee(&roomObjectRects[objActive]);
|
StartMarquee(&roomObjectRects[objActive]);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (redrawMainWindow)
|
||||||
|
UpdateMainWindow();
|
||||||
}
|
}
|
||||||
|
|
||||||
//-------------------------------------------------------------- MoveObject
|
//-------------------------------------------------------------- MoveObject
|
||||||
@@ -1657,51 +1661,6 @@ void MoveObject (short whichWay, Boolean shiftDown)
|
|||||||
UpdateMenus(false);
|
UpdateMenus(false);
|
||||||
GetThisRoomsObjRects();
|
GetThisRoomsObjRects();
|
||||||
|
|
||||||
if (objActive == kInitialGliderSelected)
|
|
||||||
{
|
|
||||||
InvalWindowRect(mainWindow, &wasRect);
|
|
||||||
InvalWindowRect(mainWindow, &initialGliderRect);
|
|
||||||
}
|
|
||||||
else if (objActive == kLeftGliderSelected)
|
|
||||||
{
|
|
||||||
InvalWindowRect(mainWindow, &wasRect);
|
|
||||||
InvalWindowRect(mainWindow, &leftStartGliderDest);
|
|
||||||
}
|
|
||||||
else if (objActive == kRightGliderSelected)
|
|
||||||
{
|
|
||||||
InvalWindowRect(mainWindow, &wasRect);
|
|
||||||
InvalWindowRect(mainWindow, &rightStartGliderDest);
|
|
||||||
}
|
|
||||||
else
|
|
||||||
{
|
|
||||||
switch (thisRoom->objects[objActive].what)
|
|
||||||
{
|
|
||||||
case kTiki:
|
|
||||||
case kTable:
|
|
||||||
case kShelf:
|
|
||||||
case kCabinet:
|
|
||||||
case kDeckTable:
|
|
||||||
case kStool:
|
|
||||||
case kCounter:
|
|
||||||
case kDresser:
|
|
||||||
case kGreaseRt:
|
|
||||||
case kGreaseLf:
|
|
||||||
case kSlider:
|
|
||||||
case kMailboxLf:
|
|
||||||
case kMailboxRt:
|
|
||||||
case kTrackLight:
|
|
||||||
case kMirror:
|
|
||||||
case kWallWindow:
|
|
||||||
InvalWindowRect(mainWindow, &mainWindowRect);
|
|
||||||
break;
|
|
||||||
|
|
||||||
default:
|
|
||||||
InvalWindowRect(mainWindow, &wasRect);
|
|
||||||
InvalWindowRect(mainWindow, &roomObjectRects[objActive]);
|
|
||||||
break;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
ReadyBackground(thisRoom->background, thisRoom->tiles);
|
ReadyBackground(thisRoom->background, thisRoom->tiles);
|
||||||
DrawThisRoomsObjects();
|
DrawThisRoomsObjects();
|
||||||
|
|
||||||
@@ -1721,6 +1680,8 @@ void MoveObject (short whichWay, Boolean shiftDown)
|
|||||||
else
|
else
|
||||||
StartMarquee(&roomObjectRects[objActive]);
|
StartMarquee(&roomObjectRects[objActive]);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
UpdateMainWindow();
|
||||||
#endif
|
#endif
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -967,7 +967,6 @@ void BringSendFrontBack (Boolean bringFront)
|
|||||||
|
|
||||||
fileDirty = true;
|
fileDirty = true;
|
||||||
UpdateMenus(false);
|
UpdateMenus(false);
|
||||||
InvalWindowRect(mainWindow, &mainWindowRect);
|
|
||||||
DeselectObject();
|
DeselectObject();
|
||||||
GetThisRoomsObjRects();
|
GetThisRoomsObjRects();
|
||||||
ReadyBackground(thisRoom->background, thisRoom->tiles);
|
ReadyBackground(thisRoom->background, thisRoom->tiles);
|
||||||
@@ -975,6 +974,8 @@ void BringSendFrontBack (Boolean bringFront)
|
|||||||
GenerateRetroLinks();
|
GenerateRetroLinks();
|
||||||
|
|
||||||
InitCursor();
|
InitCursor();
|
||||||
|
|
||||||
|
UpdateMainWindow();
|
||||||
}
|
}
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
|||||||
@@ -229,7 +229,6 @@ int16_t LoadFilter(Dialog *dial, const TimeTaggedVOSEvent *evt)
|
|||||||
return kScrollDownItem;
|
return kScrollDownItem;
|
||||||
|
|
||||||
case PL_KEY_SPECIAL(kUpArrow):
|
case PL_KEY_SPECIAL(kUpArrow):
|
||||||
InvalWindowRect(dial->GetWindow(), &loadHouseRects[thisHouseIndex]);
|
|
||||||
thisHouseIndex -= 4;
|
thisHouseIndex -= 4;
|
||||||
if (thisHouseIndex < 0)
|
if (thisHouseIndex < 0)
|
||||||
{
|
{
|
||||||
@@ -243,23 +242,20 @@ int16_t LoadFilter(Dialog *dial, const TimeTaggedVOSEvent *evt)
|
|||||||
if (thisHouseIndex >= screenCount)
|
if (thisHouseIndex >= screenCount)
|
||||||
thisHouseIndex -= 4;
|
thisHouseIndex -= 4;
|
||||||
}
|
}
|
||||||
InvalWindowRect(dial->GetWindow(), &loadHouseRects[thisHouseIndex]);
|
UpdateLoadDialog(dial);
|
||||||
return 0;
|
return 0;
|
||||||
|
|
||||||
case PL_KEY_SPECIAL(kDownArrow):
|
case PL_KEY_SPECIAL(kDownArrow):
|
||||||
InvalWindowRect(dial->GetWindow(), &loadHouseRects[thisHouseIndex]);
|
|
||||||
thisHouseIndex += 4;
|
thisHouseIndex += 4;
|
||||||
screenCount = housesFound - housePage;
|
screenCount = housesFound - housePage;
|
||||||
if (screenCount > kDispFiles)
|
if (screenCount > kDispFiles)
|
||||||
screenCount = kDispFiles;
|
screenCount = kDispFiles;
|
||||||
if (thisHouseIndex >= screenCount)
|
if (thisHouseIndex >= screenCount)
|
||||||
thisHouseIndex %= 4;
|
thisHouseIndex %= 4;
|
||||||
InvalWindowRect(dial->GetWindow(), &loadHouseRects[thisHouseIndex]);
|
UpdateLoadDialog(dial);
|
||||||
|
|
||||||
return 0;
|
return 0;
|
||||||
|
|
||||||
case PL_KEY_SPECIAL(kLeftArrow):
|
case PL_KEY_SPECIAL(kLeftArrow):
|
||||||
InvalWindowRect(dial->GetWindow(), &loadHouseRects[thisHouseIndex]);
|
|
||||||
thisHouseIndex--;
|
thisHouseIndex--;
|
||||||
if (thisHouseIndex < 0)
|
if (thisHouseIndex < 0)
|
||||||
{
|
{
|
||||||
@@ -268,19 +264,18 @@ int16_t LoadFilter(Dialog *dial, const TimeTaggedVOSEvent *evt)
|
|||||||
screenCount = kDispFiles;
|
screenCount = kDispFiles;
|
||||||
thisHouseIndex = screenCount - 1;
|
thisHouseIndex = screenCount - 1;
|
||||||
}
|
}
|
||||||
InvalWindowRect(dial->GetWindow(), &loadHouseRects[thisHouseIndex]);
|
UpdateLoadDialog(dial);
|
||||||
return 0;
|
return 0;
|
||||||
|
|
||||||
case PL_KEY_SPECIAL(kTab):
|
case PL_KEY_SPECIAL(kTab):
|
||||||
case PL_KEY_SPECIAL(kRightArrow):
|
case PL_KEY_SPECIAL(kRightArrow):
|
||||||
InvalWindowRect(dial->GetWindow(), &loadHouseRects[thisHouseIndex]);
|
|
||||||
thisHouseIndex++;
|
thisHouseIndex++;
|
||||||
screenCount = housesFound - housePage;
|
screenCount = housesFound - housePage;
|
||||||
if (screenCount > kDispFiles)
|
if (screenCount > kDispFiles)
|
||||||
screenCount = kDispFiles;
|
screenCount = kDispFiles;
|
||||||
if (thisHouseIndex >= screenCount)
|
if (thisHouseIndex >= screenCount)
|
||||||
thisHouseIndex = 0;
|
thisHouseIndex = 0;
|
||||||
InvalWindowRect(dial->GetWindow(), &loadHouseRects[thisHouseIndex]);
|
UpdateLoadDialog(dial);
|
||||||
return 0;
|
return 0;
|
||||||
|
|
||||||
default:
|
default:
|
||||||
@@ -308,10 +303,7 @@ int16_t LoadFilter(Dialog *dial, const TimeTaggedVOSEvent *evt)
|
|||||||
thisHouseIndex = screenCount - 1;
|
thisHouseIndex = screenCount - 1;
|
||||||
}
|
}
|
||||||
if (wasIndex != thisHouseIndex)
|
if (wasIndex != thisHouseIndex)
|
||||||
{
|
UpdateLoadDialog(dial);
|
||||||
InvalWindowRect(dial->GetWindow(), &loadHouseRects[wasIndex]);
|
|
||||||
InvalWindowRect(dial->GetWindow(), &loadHouseRects[thisHouseIndex]);
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -205,7 +205,7 @@ PLError_t LoadTriggerSound (short soundID)
|
|||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
BlockMove((Byte*)(*theSound), theSoundData[kMaxSounds - 1], soundDataSize);
|
memcpy(theSoundData[kMaxSounds - 1], (Byte*)(*theSound), soundDataSize);
|
||||||
theSound.Dispose();
|
theSound.Dispose();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -246,7 +246,7 @@ PLError_t LoadBufferSounds (void)
|
|||||||
if (theSoundData[i] == nil)
|
if (theSoundData[i] == nil)
|
||||||
return (PLErrors::kOutOfMemory);
|
return (PLErrors::kOutOfMemory);
|
||||||
|
|
||||||
BlockMove(*theSound, theSoundData[i], soundDataSize);
|
memcpy(theSoundData[i], *theSound, soundDataSize);
|
||||||
theSound.Dispose();
|
theSound.Dispose();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -268,7 +268,7 @@ void CreatePointers (void)
|
|||||||
{
|
{
|
||||||
GP_STATIC_ASSERT(sizeof(demoType) == 6);
|
GP_STATIC_ASSERT(sizeof(demoType) == 6);
|
||||||
|
|
||||||
BlockMove(*tempHandle, demoData, kDemoLength);
|
memcpy(demoData, *tempHandle, kDemoLength);
|
||||||
tempHandle.Dispose();
|
tempHandle.Dispose();
|
||||||
}
|
}
|
||||||
#endif
|
#endif
|
||||||
|
|||||||
@@ -114,7 +114,9 @@ void RedAlert (short errorNumber)
|
|||||||
// CenterAlert(rDeathAlertID);
|
// CenterAlert(rDeathAlertID);
|
||||||
|
|
||||||
dummyInt = PortabilityLayer::DialogManager::GetInstance()->DisplayAlert(rDeathAlertID, &substitutions);
|
dummyInt = PortabilityLayer::DialogManager::GetInstance()->DisplayAlert(rDeathAlertID, &substitutions);
|
||||||
ExitToShell();
|
//ExitToShell();
|
||||||
|
|
||||||
|
PL_NotYetImplemented_TODO("Exit");
|
||||||
}
|
}
|
||||||
|
|
||||||
//-------------------------------------------------------------- CreateOffScreenBitMap
|
//-------------------------------------------------------------- CreateOffScreenBitMap
|
||||||
|
|||||||
@@ -42,6 +42,9 @@ namespace PortabilityLayer
|
|||||||
|
|
||||||
int16_t ButtonWidget::Capture(const Point &pos, WidgetUpdateCallback_t callback)
|
int16_t ButtonWidget::Capture(const Point &pos, WidgetUpdateCallback_t callback)
|
||||||
{
|
{
|
||||||
|
if (!m_enabled || !m_visible)
|
||||||
|
return 0;
|
||||||
|
|
||||||
bool drawingDownState = false;
|
bool drawingDownState = false;
|
||||||
bool isInBounds = m_rect.Contains(pos);
|
bool isInBounds = m_rect.Contains(pos);
|
||||||
for (;;)
|
for (;;)
|
||||||
|
|||||||
@@ -3,12 +3,6 @@
|
|||||||
#include "PLArrayViewIterator.h"
|
#include "PLArrayViewIterator.h"
|
||||||
#include "PLWidgets.h"
|
#include "PLWidgets.h"
|
||||||
|
|
||||||
int FindControl(Point point, WindowPtr window, ControlHandle *outControl)
|
|
||||||
{
|
|
||||||
PL_NotYetImplemented();
|
|
||||||
return 0;
|
|
||||||
}
|
|
||||||
|
|
||||||
int FindControl(Point point, WindowPtr window, PortabilityLayer::Widget **outControl)
|
int FindControl(Point point, WindowPtr window, PortabilityLayer::Widget **outControl)
|
||||||
{
|
{
|
||||||
// Returns clicked part
|
// Returns clicked part
|
||||||
@@ -32,78 +26,3 @@ int FindControl(Point point, WindowPtr window, PortabilityLayer::Widget **outCon
|
|||||||
*outControl = nullptr;
|
*outControl = nullptr;
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
void SetControlValue(ControlHandle control, int value)
|
|
||||||
{
|
|
||||||
PL_NotYetImplemented();
|
|
||||||
}
|
|
||||||
|
|
||||||
void SetControlMaximum(ControlHandle control, int value)
|
|
||||||
{
|
|
||||||
PL_NotYetImplemented();
|
|
||||||
}
|
|
||||||
|
|
||||||
void MoveControl(ControlHandle control, int x, int y)
|
|
||||||
{
|
|
||||||
PL_NotYetImplemented();
|
|
||||||
}
|
|
||||||
|
|
||||||
void SizeControl(ControlHandle control, int width, int height)
|
|
||||||
{
|
|
||||||
PL_NotYetImplemented();
|
|
||||||
}
|
|
||||||
|
|
||||||
int GetControlValue(ControlHandle control)
|
|
||||||
{
|
|
||||||
PL_NotYetImplemented();
|
|
||||||
return 0;
|
|
||||||
}
|
|
||||||
|
|
||||||
ControlHandle NewControl(WindowPtr window, const Rect *rect, const PLPasStr &label, Boolean visible, int value, int minValue, int maxValue, int cdef, long userdata)
|
|
||||||
{
|
|
||||||
PL_NotYetImplemented();
|
|
||||||
return nullptr;
|
|
||||||
}
|
|
||||||
|
|
||||||
ControlActionUPP NewControlActionUPP(ControlActionProc proc)
|
|
||||||
{
|
|
||||||
return proc;
|
|
||||||
}
|
|
||||||
|
|
||||||
void DisposeControlActionUPP(ControlActionUPP upp)
|
|
||||||
{
|
|
||||||
}
|
|
||||||
|
|
||||||
Boolean TrackControl(ControlHandle control, Point point, ControlActionUPP proc)
|
|
||||||
{
|
|
||||||
PL_NotYetImplemented();
|
|
||||||
return false;
|
|
||||||
}
|
|
||||||
|
|
||||||
Boolean TrackControl(PortabilityLayer::Widget *widget, Point point, ControlActionUPP proc)
|
|
||||||
{
|
|
||||||
PL_NotYetImplemented();
|
|
||||||
return false;
|
|
||||||
}
|
|
||||||
|
|
||||||
long GetControlReference(ControlHandle control)
|
|
||||||
{
|
|
||||||
PL_NotYetImplemented();
|
|
||||||
return 0;
|
|
||||||
}
|
|
||||||
|
|
||||||
ControlHandle GetNewControl(int resID, WindowPtr window)
|
|
||||||
{
|
|
||||||
PL_NotYetImplemented();
|
|
||||||
return nullptr;
|
|
||||||
}
|
|
||||||
|
|
||||||
void HiliteControl(ControlHandle control, int unknown)
|
|
||||||
{
|
|
||||||
PL_NotYetImplemented();
|
|
||||||
}
|
|
||||||
|
|
||||||
void HiliteControl(PortabilityLayer::Widget *widget, int unknown)
|
|
||||||
{
|
|
||||||
PL_NotYetImplemented();
|
|
||||||
}
|
|
||||||
|
|||||||
@@ -30,22 +30,5 @@ enum ControlParts
|
|||||||
|
|
||||||
|
|
||||||
int FindControl(Point point, WindowPtr window, PortabilityLayer::Widget **outControl); // Returns part
|
int FindControl(Point point, WindowPtr window, PortabilityLayer::Widget **outControl); // Returns part
|
||||||
int FindControl(Point point, WindowPtr window, ControlHandle *outControl);
|
|
||||||
|
|
||||||
|
|
||||||
void SetControlValue(ControlHandle control, int value);
|
|
||||||
void SetControlMaximum(ControlHandle control, int value);
|
|
||||||
void MoveControl(ControlHandle control, int x, int y);
|
|
||||||
void SizeControl(ControlHandle control, int width, int height);
|
|
||||||
int GetControlValue(ControlHandle control);
|
|
||||||
ControlHandle NewControl(WindowPtr window, const Rect *rect, const PLPasStr &label, Boolean visible, int value, int minValue, int maxValue, int cdef, long userdata);
|
|
||||||
ControlActionUPP NewControlActionUPP(ControlActionProc proc);
|
|
||||||
void DisposeControlActionUPP(ControlActionUPP upp);
|
|
||||||
Boolean TrackControl(ControlHandle control, Point point, ControlActionUPP proc);
|
|
||||||
Boolean TrackControl(PortabilityLayer::Widget *control, Point point, ControlActionUPP proc);
|
|
||||||
long GetControlReference(ControlHandle control); // Returns userdata
|
|
||||||
ControlHandle GetNewControl(int resID, WindowPtr window);
|
|
||||||
void HiliteControl(ControlHandle control, int unknown);
|
|
||||||
void HiliteControl(PortabilityLayer::Widget *widget, int unknown);
|
|
||||||
|
|
||||||
#endif
|
#endif
|
||||||
|
|||||||
@@ -538,12 +538,6 @@ void GetTime(DateTimeRec *dateTime)
|
|||||||
dateTime->minute = minute;
|
dateTime->minute = minute;
|
||||||
}
|
}
|
||||||
|
|
||||||
UInt32 GetDblTime()
|
|
||||||
{
|
|
||||||
PL_NotYetImplemented_Minor();
|
|
||||||
return 30;
|
|
||||||
}
|
|
||||||
|
|
||||||
void FlushEvents(int mask, int unknown)
|
void FlushEvents(int mask, int unknown)
|
||||||
{
|
{
|
||||||
PortabilityLayer::EventQueue *queue = PortabilityLayer::EventQueue::GetInstance();
|
PortabilityLayer::EventQueue *queue = PortabilityLayer::EventQueue::GetInstance();
|
||||||
@@ -558,11 +552,6 @@ void ExitToShell()
|
|||||||
PL_NotYetImplemented();
|
PL_NotYetImplemented();
|
||||||
}
|
}
|
||||||
|
|
||||||
void InvalWindowRect(WindowPtr window, const Rect *rect)
|
|
||||||
{
|
|
||||||
PL_NotYetImplemented();
|
|
||||||
}
|
|
||||||
|
|
||||||
Handle NewHandle(Size size)
|
Handle NewHandle(Size size)
|
||||||
{
|
{
|
||||||
PortabilityLayer::MMHandleBlock *hBlock = PortabilityLayer::MemoryManager::GetInstance()->AllocHandle(size);
|
PortabilityLayer::MMHandleBlock *hBlock = PortabilityLayer::MemoryManager::GetInstance()->AllocHandle(size);
|
||||||
@@ -608,11 +597,6 @@ void DisposePtr(void *ptr)
|
|||||||
PortabilityLayer::MemoryManager::GetInstance()->Release(ptr);
|
PortabilityLayer::MemoryManager::GetInstance()->Release(ptr);
|
||||||
}
|
}
|
||||||
|
|
||||||
void BlockMove(const void *src, void *dest, Size size)
|
|
||||||
{
|
|
||||||
memcpy(dest, src, size);
|
|
||||||
}
|
|
||||||
|
|
||||||
bool WaitForEvent(TimeTaggedVOSEvent *eventOut, uint32_t ticks)
|
bool WaitForEvent(TimeTaggedVOSEvent *eventOut, uint32_t ticks)
|
||||||
{
|
{
|
||||||
for (;;)
|
for (;;)
|
||||||
@@ -631,21 +615,6 @@ bool WaitForEvent(TimeTaggedVOSEvent *eventOut, uint32_t ticks)
|
|||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
void DrawControls(WindowPtr window)
|
|
||||||
{
|
|
||||||
PL_NotYetImplemented();
|
|
||||||
}
|
|
||||||
|
|
||||||
void DrawGrowIcon(WindowPtr window)
|
|
||||||
{
|
|
||||||
PL_NotYetImplemented();
|
|
||||||
}
|
|
||||||
|
|
||||||
void DebugStr(const PLPasStr &str)
|
|
||||||
{
|
|
||||||
PL_NotYetImplemented();
|
|
||||||
}
|
|
||||||
|
|
||||||
void PL_NotYetImplemented()
|
void PL_NotYetImplemented()
|
||||||
{
|
{
|
||||||
assert(false);
|
assert(false);
|
||||||
|
|||||||
@@ -247,7 +247,6 @@ static const int nullEvent = 0;
|
|||||||
//void FlushEvents(int eventMask, int stopMask);
|
//void FlushEvents(int eventMask, int stopMask);
|
||||||
|
|
||||||
void InitCursor();
|
void InitCursor();
|
||||||
CursHandle GetCursor(int cursorID);
|
|
||||||
void HideCursor();
|
void HideCursor();
|
||||||
|
|
||||||
void Delay(int ticks, UInt32 *endTickCount);
|
void Delay(int ticks, UInt32 *endTickCount);
|
||||||
@@ -295,12 +294,8 @@ Boolean WaitMouseUp();
|
|||||||
|
|
||||||
short Random();
|
short Random();
|
||||||
void GetTime(DateTimeRec *dateTime);
|
void GetTime(DateTimeRec *dateTime);
|
||||||
UInt32 GetDblTime();
|
|
||||||
|
|
||||||
void FlushEvents(int mask, int unknown);
|
void FlushEvents(int mask, int unknown);
|
||||||
void ExitToShell();
|
|
||||||
|
|
||||||
void InvalWindowRect(WindowPtr window, const Rect *rect);
|
|
||||||
|
|
||||||
Handle NewHandle(Size size);
|
Handle NewHandle(Size size);
|
||||||
long GetHandleSize(Handle handle);
|
long GetHandleSize(Handle handle);
|
||||||
@@ -311,15 +306,9 @@ void *NewPtr(Size size);
|
|||||||
void *NewPtrClear(Size size);
|
void *NewPtrClear(Size size);
|
||||||
void DisposePtr(void *ptr);
|
void DisposePtr(void *ptr);
|
||||||
|
|
||||||
void BlockMove(const void *src, void *dest, Size size);
|
|
||||||
|
|
||||||
bool WaitForEvent(TimeTaggedVOSEvent *evt, uint32_t ticks);
|
bool WaitForEvent(TimeTaggedVOSEvent *evt, uint32_t ticks);
|
||||||
|
|
||||||
void DrawControls(WindowPtr window);
|
|
||||||
void DrawGrowIcon(WindowPtr window);
|
|
||||||
|
|
||||||
void DebugStr(const PLPasStr &str);
|
|
||||||
|
|
||||||
static const Boolean PL_TRUE = 1;
|
static const Boolean PL_TRUE = 1;
|
||||||
static const Boolean PL_FALSE = 0;
|
static const Boolean PL_FALSE = 0;
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user