source: xtideuniversalbios/trunk/Assembly_Library/Src/Menu/Dialog/DialogSelection.asm @ 376

Last change on this file since 376 was 376, checked in by gregli@…, 12 years ago

WIDE checkin... Added copyright and license information to sorce files, as per the GPL instructions for usage.

File size: 2.7 KB
Line 
1; File name     :   DialogSelection.asm
2; Project name  :   Assembly Library
3; Created date  :   13.8.2010
4; Last update   :   18.11.2010
5; Author        :   Tomi Tilli
6; Description   :   Displays selection dialog.
7
8;
9; XTIDE Universal BIOS and Associated Tools 
10; Copyright (C) 2009-2010 by Tomi Tilli, 2011-2012 by XTIDE Universal BIOS Team.
11;
12; This program is free software; you can redistribute it and/or modify
13; it under the terms of the GNU General Public License as published by
14; the Free Software Foundation; either version 2 of the License, or
15; (at your option) any later version.
16; 
17; This program is distributed in the hope that it will be useful,
18; but WITHOUT ANY WARRANTY; without even the implied warranty of
19; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
20; GNU General Public License for more details.     
21; Visit http://www.gnu.org/licenses/old-licenses/gpl-2.0.html
22;
23       
24
25; Section containing code
26SECTION .text
27
28;--------------------------------------------------------------------
29; DialogSelection_GetSelectionToAXwithInputInDSSI
30;   Parameters:
31;       DS:SI:  Ptr to DIALOG_INPUT
32;       SS:BP:  Ptr to parent MENU
33;   Returns:
34;       Nothing
35;   Corrupts registers:
36;       AX, BX, CX, DX, SI, DI
37;--------------------------------------------------------------------
38ALIGN JUMP_ALIGN
39DialogSelection_GetSelectionToAXwithInputInDSSI:
40    mov     bx, SelectionEventHandler
41    jmp     Dialog_DisplayWithDialogInputInDSSIandHandlerInBX
42
43
44;--------------------------------------------------------------------
45; SelectionEventHandler
46;   Common parameters for all events:
47;       BX:         Menu event (anything from MENUEVENT struct)
48;       SS:BP:      Ptr to DIALOG
49;   Common return values for all events:
50;       CF:         Set if event processed
51;                   Cleared if event not processed
52;   Corrupts registers:
53;       All
54;--------------------------------------------------------------------
55ALIGN JUMP_ALIGN
56SelectionEventHandler:
57    jmp     [cs:bx+.rgfnEventHandlers]
58
59
60ALIGN JUMP_ALIGN
61.InitializeMenuinitFromDSSI:
62    xor     ax, ax
63    jmp     Dialog_EventInitializeMenuinitFromDSSIwithHighlightedItemInAX
64
65
66ALIGN WORD_ALIGN
67.rgfnEventHandlers:
68istruc MENUEVENT
69    at  MENUEVENT.InitializeMenuinitFromDSSI,   dw  .InitializeMenuinitFromDSSI
70    at  MENUEVENT.ExitMenu,                     dw  Dialog_EventExitMenu
71    at  MENUEVENT.IdleProcessing,               dw  Dialog_EventNotHandled
72    at  MENUEVENT.ItemHighlightedFromCX,        dw  Dialog_EventNotHandled
73    at  MENUEVENT.ItemSelectedFromCX,           dw  Dialog_EventAnyThatClosesDialog
74    at  MENUEVENT.KeyStrokeInAX,                dw  Dialog_EventNotHandled
75    at  MENUEVENT.RefreshTitle,                 dw  Dialog_EventRefreshTitle
76    at  MENUEVENT.RefreshInformation,           dw  Dialog_EventRefreshInformation
77    at  MENUEVENT.RefreshItemFromCX,            dw  Dialog_EventRefreshItemFromCX
78iend
Note: See TracBrowser for help on using the repository browser.