[41] | 1 | ; File name : MenuEvents.inc
|
---|
| 2 | ; Project name : Assembly Library
|
---|
| 3 | ; Created date : 13.7.2010
|
---|
[58] | 4 | ; Last update : 18.10.2010
|
---|
[41] | 5 | ; Author : Tomi Tilli
|
---|
| 6 | ; Description : Defines for Menu events send to the user.
|
---|
| 7 | %ifndef MENUEVENTS_INC
|
---|
| 8 | %define MENUEVENTS_INC
|
---|
| 9 |
|
---|
| 10 | ;--------------------------------------------------------------------
|
---|
| 11 | ; Events to be processed in user implemented handler.
|
---|
| 12 | ; Common parameters for all events:
|
---|
| 13 | ; BX: Menu event (anything from MENUEVENT struct)
|
---|
| 14 | ; SS:BP: Menu library handle
|
---|
| 15 | ; Common return values for all events:
|
---|
| 16 | ; CF: Set if event processed
|
---|
| 17 | ; Cleared if event not processed
|
---|
| 18 | ; Corrupts registers:
|
---|
| 19 | ; All
|
---|
| 20 | ;--------------------------------------------------------------------
|
---|
| 21 | struc MENUEVENT
|
---|
| 22 | ; Parameters:
|
---|
| 23 | ; DS:SI: Ptr to MENUINIT struct to initialize
|
---|
| 24 | ; Returns:
|
---|
| 25 | ; DS:SI: Ptr to initialized MENUINIT struct
|
---|
| 26 | .InitializeMenuinitFromDSSI resb 2
|
---|
| 27 |
|
---|
| 28 | ; Parameters:
|
---|
| 29 | ; None
|
---|
[58] | 30 | ; Returns:
|
---|
| 31 | ; CF: Set to exit menu
|
---|
| 32 | ; Clear to cancel exit
|
---|
[41] | 33 | .ExitMenu resb 2
|
---|
| 34 |
|
---|
| 35 | ; Parameters:
|
---|
| 36 | ; None
|
---|
| 37 | .IdleProcessing resb 2
|
---|
| 38 |
|
---|
| 39 | ; Parameters:
|
---|
| 40 | ; CX: Index of new highlighted item
|
---|
| 41 | ; DX: Index of previously highlighted item or NO_ITEM_HIGHLIGHTED
|
---|
| 42 | .ItemHighlightedFromCX resb 2
|
---|
| 43 |
|
---|
| 44 | ; Parameters:
|
---|
| 45 | ; CX: Index of selected item
|
---|
| 46 | .ItemSelectedFromCX resb 2
|
---|
| 47 |
|
---|
| 48 | ; Parameters:
|
---|
| 49 | ; AL: ASCII character for the key
|
---|
| 50 | ; AH: Keyboard library scan code for the key
|
---|
| 51 | .KeyStrokeInAX resb 2
|
---|
| 52 |
|
---|
| 53 | ; Parameters:
|
---|
[48] | 54 | ; CX: Index of highlighted item
|
---|
| 55 | ; Cursor has been positioned to the beginning of first line
|
---|
[41] | 56 | .RefreshTitle resb 2
|
---|
| 57 | .RefreshInformation resb 2
|
---|
| 58 |
|
---|
| 59 | ; Parameters:
|
---|
| 60 | ; CX: Index of item to refresh
|
---|
| 61 | ; Cursor has been positioned to the beginning of item line
|
---|
| 62 | .RefreshItemFromCX resb 2
|
---|
| 63 | endstruc
|
---|
| 64 |
|
---|
| 65 |
|
---|
| 66 | %endif ; MENUEVENTS_INC
|
---|