Retired Document
Important: This sample code may not represent best practices for current development. The project may use deprecated symbols and illustrate technologies and techniques that are no longer recommended.
source/eventloop.c
/****************************************************/ |
/* */ |
/* File: eventloop.c */ |
/* */ |
/* Program: Imageer */ |
/* */ |
/* By: Jason Hodges-Harris */ |
/* */ |
/* Created: 26/10/95 00:00:00 AM */ |
/* */ |
/* Version: 1.0.0d3 */ |
/* */ |
/* Copyright: © 1995-96 Apple Computer, Inc., */ |
/* all rights reserved. */ |
/* */ |
/****************************************************/ |
/**** Macintosh Toolbox Headers *****/ |
#ifndef __EVENTS__ |
#include <Events.h> |
#endif |
/**** Application headers and prototypes ****/ |
#ifndef __IMAGEERAPPHEADER__ |
#include "Imageer.app.h" |
#endif |
#ifndef __IMAGEERPROTOSHEADER__ |
#include "Imageer.protos.h" |
#endif |
// Global Variables |
extern Boolean gDone; // program loop test condition |
// EventLoop handles the application's main WNE loop |
// and is called from within the main() function. |
#pragma segment Main |
void EventLoop (void) |
{ |
EventRecord event; |
while (!gDone) |
{ |
if (WaitNextEvent (everyEvent,&event,kSleep,nil)) |
{ |
DoEvent (&event); |
} |
} |
} |
Copyright © 2003 Apple Computer, Inc. All Rights Reserved. Terms of Use | Privacy Policy | Updated: 2003-01-14