Mac OS 7.1 Source Docs

Documentation for the Mac OS 7.1 Source Code Reconstruction

View the Project on GitHub belikh/sys71src

Data Models

This document outlines key data structures and memory models used in System 7.1.

Memory Models

The Heap

Memory is divided into heaps.

Data Types:

Resources

Data is often stored in the Resource Fork of a file.

Core Entities

WindowRecord (WindowPtr)

Represents a window on the screen.

DialogRecord (DialogPtr)

Extends WindowRecord for dialog boxes.

EventRecord

Represents a user or system event.

File System Catalog

Schema Diagram (Conceptual)

classDiagram
    class EventRecord {
        +int what
        +long message
        +long when
        +Point where
        +int modifiers
    }

    class WindowRecord {
        +GrafPort port
        +short windowKind
        +boolean visible
        +boolean hilited
        +long refCon
    }

    class DialogRecord {
        +WindowRecord window
        +Handle items
        +TEHandle textH
    }

    class FileInfo {
        +OSType fdType
        +OSType fdCreator
        +short fdFlags
        +Point fdLocation
    }

    DialogRecord --|> WindowRecord : Extends
    EventRecord ..> WindowRecord : References