EasyManua.ls Logo

Texas Instruments TI-89 - Page 958

Texas Instruments TI-89
1398 pages
Print Icon
To Next Page IconTo Next Page
To Next Page IconTo Next Page
To Previous Page IconTo Previous Page
To Previous Page IconTo Previous Page
Loading...
916
Appendix A: System Routines — Operating System
TI
-
89 / TI
-
92 Plus Developer Guide
Not for Distribution
Beta Version January 26, 2001
EV_captureEvents
(continued)
/* Display my window */
if (! WinOpen(&myWindow, &r, WF_SAVE_SCR|WF_ROUNDEDBORDER|WF_TITLE|WF_TTY,
"MY WINDOW"))
{
EV_restorePainting(oldPaintState);
return;
}
WinActivate(&myWindow);
WinBeginPaint(&myWindow);
WinAttr(&myWindow, A_REPLACE);
myWindow.Flags &= ~WF_DIRTY; /* I will repaint this window myself */
myWindow.TaskId = AP_NONE; /* no task owns this window */
paint();
/* Install event handler */
oldEventHandler = EV_captureEvents(myEventHandler);
}
static void myEventHandler(PEvent e)
{
if (e->command == CM_KEY_PRESS)
{
switch (e->info.keyInfo.keyCode)
{
case KB_ENTER:
case KB_ESC:
cancel(); /* cancel dialog */
break;
case KB_SWITCH:
case KB_VARLINK:
case KB_CHAR:
case KB_MATH:
case KB_MODE:
case KB_MENU:
case KB_MEM:
case KB_QUIT:
case KB_HOME:
case KB_YEQ:
case KB_RANGE:
case KB_GRAPH:
case KB_TBLSET:
case KB_TABLE:
case KB_OFF:
cancel(); /* cancel dialog */
EV_defaultHandler(e); /* allow default handling */
break;
(continued)

Table of Contents

Other manuals for Texas Instruments TI-89

Related product manuals