Changeset 133 in xtideuniversalbios for trunk/Assembly_Library/Src/Menu
- Timestamp:
- Mar 12, 2011, 1:48:48 PM (14 years ago)
- google:author:
- krille_n_@hotmail.com
- Location:
- trunk/Assembly_Library/Src/Menu
- Files:
-
- 7 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/Assembly_Library/Src/Menu/Dialog/ItemLineSplitter.asm
r52 r133 1 ; File name : ItemLineSplitter.asm2 1 ; Project name : Assembly Library 3 ; Created date : 12.10.20104 ; Last update : 12.10.20105 ; Author : Tomi Tilli6 2 ; Description : Functions for splitting strings to item lines. 7 3 … … 130 126 131 127 inc bx ; Increment line 132 xor cx, cx ; Zero character counter 128 xor cx, cx ; Zero character counter (and clear CF) 133 129 mov si, di ; Start from complete word 134 130 mov [bp+ITEM_LINE_SPLITTER.wStartOfLine], di 135 clc136 131 ret 137 132 -
trunk/Assembly_Library/Src/Menu/MenuEvent.asm
r104 r133 21 21 pop ds 22 22 mov si, bp 23 mov b x, MENUEVENT.InitializeMenuinitFromDSSI23 mov bl, MENUEVENT.InitializeMenuinitFromDSSI 24 24 jmp SHORT MenuEvent_SendFromBX 25 25 … … 37 37 ALIGN JUMP_ALIGN 38 38 MenuEvent_ExitMenu: 39 mov b x, MENUEVENT.ExitMenu39 mov bl, MENUEVENT.ExitMenu 40 40 jmp SHORT MenuEvent_SendFromBX 41 41 … … 53 53 ALIGN JUMP_ALIGN 54 54 MenuEvent_IdleProcessing: 55 mov b x, MENUEVENT.IdleProcessing55 mov bl, MENUEVENT.IdleProcessing 56 56 jmp SHORT MenuEvent_SendFromBX 57 57 … … 71 71 ALIGN JUMP_ALIGN 72 72 MenuEvent_RefreshTitle: 73 mov b x, MENUEVENT.RefreshTitle74 jmp SHORT LoadHighlightedItemToCXandSendMessageFromBX73 mov bl, MENUEVENT.RefreshTitle 74 SKIP2B cx ; mov cx, <next instruction> 75 75 76 ALIGN JUMP_ALIGN77 76 MenuEvent_RefreshInformation: 78 mov bx, MENUEVENT.RefreshInformation 79 LoadHighlightedItemToCXandSendMessageFromBX: 77 mov bl, MENUEVENT.RefreshInformation 80 78 mov cx, [bp+MENUINIT.wHighlightedItem] 81 79 jmp SHORT MenuEvent_SendFromBX … … 96 94 ALIGN JUMP_ALIGN 97 95 MenuEvent_RefreshItemFromCX: 98 mov b x, MENUEVENT.RefreshItemFromCX96 mov bl, MENUEVENT.RefreshItemFromCX 99 97 jmp SHORT MenuEvent_SendFromBX 100 98 … … 116 114 push dx 117 115 118 mov b x, MENUEVENT.ItemHighlightedFromCX116 mov bl, MENUEVENT.ItemHighlightedFromCX 119 117 call MenuEvent_SendFromBX 120 118 … … 139 137 ALIGN JUMP_ALIGN 140 138 MenuEvent_KeyStrokeInAX: 141 mov b x, MENUEVENT.KeyStrokeInAX142 jmp SHORT MenuEvent_SendFromBX139 mov bl, MENUEVENT.KeyStrokeInAX 140 SKIP2B dx ; mov dx, <next instruction> 143 141 144 142 … … 154 152 ; AX, BX, DX 155 153 ;-------------------------------------------------------------------- 156 ALIGN JUMP_ALIGN157 154 MenuEvent_ItemSelectedFromCX: 158 mov b x, MENUEVENT.ItemSelectedFromCX159 jmp SHORTMenuEvent_SendFromBX155 mov bl, MENUEVENT.ItemSelectedFromCX 156 ; Fall to MenuEvent_SendFromBX 160 157 161 158 … … 163 160 ; MenuEvent_SendFromBX 164 161 ; Parameters 165 ; B X: Menu event to send162 ; BL: Menu event to send 166 163 ; SS:BP: Ptr to MENU 167 164 ; Other registers: Event specific parameters … … 180 177 push si 181 178 push cx 179 xor bh, bh 182 180 call [bp+MENU.fnEventHandler] 183 181 pop cx -
trunk/Assembly_Library/Src/Menu/MenuInit.asm
r129 r133 57 57 CALL_DISPLAY_LIBRARY SetCursorShapeFromAX 58 58 call MenuEvent_InitializeMenuinit ; User initialization 59 %ifndef USE_186 59 60 call MenuInit_RefreshMenuWindow 60 61 jmp MenuLoop_Enter 62 %else 63 push MenuLoop_Enter 64 ; Fall to MenuInit_RefreshMenuWindow 65 %endif 61 66 62 67 … … 117 122 ; Nothing 118 123 ;-------------------------------------------------------------------- 124 %ifndef EXCLUDE_FROM_XTIDE_UNIVERSAL_BIOS 119 125 ALIGN JUMP_ALIGN 120 126 MenuInit_GetHighlightedItemToAX: 121 127 mov ax, [bp+MENUINIT.wHighlightedItem] 122 128 ret 129 %endif 123 130 124 131 … … 135 142 ; Nothing 136 143 ;-------------------------------------------------------------------- 144 %ifndef EXCLUDE_FROM_XTIDE_UNIVERSAL_BIOS 137 145 ALIGN JUMP_ALIGN 138 146 MenuInit_SetTitleHeightFromAL: … … 149 157 mov [bp+MENUINIT.wItems], ax 150 158 ret 159 %endif 151 160 152 161 … … 162 171 ; Nothing 163 172 ;-------------------------------------------------------------------- 173 %ifndef EXCLUDE_FROM_XTIDE_UNIVERSAL_BIOS 164 174 ALIGN JUMP_ALIGN 165 175 MenuInit_SetUserDataFromDSSI: … … 172 182 lds si, [bp+MENU.dwUserData] 173 183 ret 184 %endif -
trunk/Assembly_Library/Src/Menu/MenuLoop.asm
r105 r133 56 56 ; SS:BP: Ptr to MENU 57 57 ; Returns: 58 ; Nothing 58 ; Nothing 59 59 ; Corrupts registers: 60 60 ; AX, BX, CX, DX, SI, DI … … 92 92 test BYTE [bp+MENU.bFlags], FLG_MENU_USER_HANDLES_SCROLLING 93 93 jz SHORT MenuLoop_ProcessScrollingKeysFromAX 94 clc ; Clear CF since keystroke not processed 95 ret 94 ret ; Return with CF cleared since keystroke not processed 96 95 97 96 ALIGN JUMP_ALIGN -
trunk/Assembly_Library/Src/Menu/MenuScrollbars.asm
r105 r133 59 59 ; Corrupts registers: 60 60 ; CX, DX 61 ;-------------------------------------------------------------------- 61 ;-------------------------------------------------------------------- 62 62 ALIGN JUMP_ALIGN 63 63 .GetLastThumbLineToAX: … … 161 161 .RotateItemInCX: 162 162 mov dx, [bp+MENUINIT.wItems] 163 cmp cx, BYTE 0164 j lSHORT .RotateNegativeItemInCX163 test cx, cx 164 js SHORT .RotateNegativeItemInCX 165 165 cmp cx, dx 166 166 jae SHORT .RotatePositiveItemInCX … … 193 193 ALIGN JUMP_ALIGN 194 194 MenuScrollbars_IsItemInCXonVisiblePage: 195 cmp cx, [bp+MENU.wFirstVisibleItem]196 j bSHORT .ItemIsNotVisible195 cmp [bp+MENU.wFirstVisibleItem], cx 196 ja SHORT .ItemIsNotVisible 197 197 198 198 call MenuScrollbars_GetLastVisibleItemOnPageToAX … … 200 200 ja SHORT .ItemIsNotVisible 201 201 stc ; Item is visible 202 ret 203 ALIGN JUMP_ALIGN 202 ALIGN JUMP_ALIGN, ret 204 203 .ItemIsNotVisible: 205 clc206 204 ret 207 205 -
trunk/Assembly_Library/Src/Menu/MenuText.asm
r125 r133 155 155 call MenuLocation_GetTextCoordinatesToAXforItemInAX 156 156 mov dx, MenuCharOut_MenuTeletypeOutput 157 ; Fall to AdjustDisplayContextForDrawingTextsAtCoord inatesInAXwithAttributeTypeInSI157 ; Fall to AdjustDisplayContextForDrawingTextsAtCoordsInAXwithAttrTypeInSIandCharOutFunctionInDX 158 158 159 159 ;-------------------------------------------------------------------- -
trunk/Assembly_Library/Src/Menu/MenuTime.asm
r105 r133 97 97 xchg dx, ax 98 98 call TimerTicks_GetSecondsToAXfromTicksInDX 99 jmp SHORT .PopRegistersAndReturn99 SKIP2B f ; cmp ax, <next instruction> 100 100 .TimeoutHasOccurredSoMakeSureTicksAreNotBelowZero: 101 101 xor ax, ax 102 .PopRegistersAndReturn: 102 103 103 pop bx 104 104 pop cx
Note:
See TracChangeset
for help on using the changeset viewer.