source: xtideuniversalbios/trunk/Assembly_Library/Src/Menu/Menu.asm@ 44

Last change on this file since 44 was 41, checked in by Tomi Tilli, 14 years ago

Initial commit for Assembly Library.

File size: 2.8 KB
Line 
1; File name : Menu.asm
2; Project name : Assembly Library
3; Created date : 3.8.2010
4; Last update : 15.9.2010
5; Author : Tomi Tilli
6; Description : Menu Library functions for CALL_MENU_LIBRARY macro
7; that users should use to make library call.
8
9; Section containing code
10SECTION .text
11
12;--------------------------------------------------------------------
13; MenuFunctionFromDI
14; Parameters:
15; DI: Function to call (MENU_LIB.functionName)
16; BP: Menu handle
17; Others: Depends on function to call
18; Returns:
19; Depends on function to call
20; Corrupts registers:
21; AX (unless used as a return register), DI
22;--------------------------------------------------------------------
23ALIGN JUMP_ALIGN
24Menu_FunctionFromDI:
25 push si
26 push dx
27 push cx
28 push bx
29 call [cs:di+.rgfnMenuLibraryFunctions]
30 pop bx
31 pop cx
32 pop dx
33 pop si
34 ret
35
36
37ALIGN WORD_ALIGN
38.rgfnMenuLibraryFunctions:
39istruc MENU_LIB
40 at MENU_LIB.DisplayWithHandlerInBXandUserDataInDXAX, dw MenuInit_DisplayMenuWithHandlerInBXandUserDataInDXAX
41 ;at MENU_LIB.Close, dw MenuInit_CloseMenuWindow ; Special case in CALL_MENU_LIBRARY
42 at MENU_LIB.RefreshWindow, dw MenuInit_RefreshMenuWindow
43
44 ;at MENU_LIB.SetUserDataFromDSSI, dw MenuInit_SetUserDataFromDSSI ; Special case in CALL_MENU_LIBRARY
45 ;at MENU_LIB.GetUserDataToDSSI, dw MenuInit_GetUserDataToDSSI ; Special case in CALL_MENU_LIBRARY
46
47 ;at MENU_LIB.SetTitleHeightFromAL, dw MenuInit_SetTitleHeightFromAL ; Special case in CALL_MENU_LIBRARY
48 at MENU_LIB.RefreshTitle, dw MenuText_RefreshTitle
49
50 at MENU_LIB.HighlightItemFromAX, dw MenuInit_HighlightItemFromAX
51 ;at MENU_LIB.SetTotalItemsFromAX, dw MenuInit_SetTotalItemsFromAX ; Special case in CALL_MENU_LIBRARY
52 at MENU_LIB.RefreshItemFromAX, dw MenuText_RefreshItemFromAX
53
54 ;at MENU_LIB.SetInformationHeightFromAL, dw MenuInit_SetInformationHeightFromAL ; Special case in CALL_MENU_LIBRARY
55 at MENU_LIB.RefreshInformation, dw MenuText_RefreshInformation
56
57 at MENU_LIB.RestartTimeout, dw MenuTime_RestartSelectionTimeout
58 ;at MENU_LIB.SetTimeoutValueFromAX, dw MenuTime_SetSelectionTimeoutValueFromAX ; Special case in CALL_MENU_LIBRARY
59
60%ifdef INCLUDE_MENU_DIALOGS
61 at MENU_LIB.StartProgressTaskWithIoInDSSIandParamInDXAX, dw DialogProgress_StartProgressTaskWithIoInDSSIandParamInDXAX
62 at MENU_LIB.SetProgressValueFromAX, dw DialogProgress_SetProgressValueFromAX
63
64 at MENU_LIB.DisplayMessageWithInputInDSSI, dw DialogMessage_DisplayMessageWithInputInDSSI
65 at MENU_LIB.GetSelectionToAXwithInputInDSSI, dw DialogSelection_GetSelectionToAXwithInputInDSSI
66 at MENU_LIB.GetWordWithIoInDSSI, dw DialogWord_GetWordWithIoInDSSI
67 at MENU_LIB.GetStringWithIoInDSSI, dw DialogString_GetStringWithIoInDSSI
68 at MENU_LIB.GetFileNameWithIoInDSSI, dw DialogFile_GetFileNameWithIoInDSSI
69%endif
70iend
Note: See TracBrowser for help on using the repository browser.