Changeset 52 in xtideuniversalbios for trunk/Assembly_Library/Src/Menu/Dialog/DialogFile.asm


Ignore:
Timestamp:
Oct 12, 2010, 6:51:07 PM (14 years ago)
Author:
aitotat
google:author:
aitotat
Message:

Changes to Assembly Library:
Completely rewritten line splitting (slower but no need to modify string).
Some changes to string processing functions.
Saved few bytes from CGA detection.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/Assembly_Library/Src/Menu/Dialog/DialogFile.asm

    r51 r52  
    22; Project name  :   Assembly Library
    33; Created date  :   6.9.2010
    4 ; Last update   :   10.10.2010
     4; Last update   :   12.10.2010
    55; Author        :   Tomi Tilli
    66; Description   :   Displays file dialog.
     
    4949.ItemSelectedFromCX:
    5050    call    LoadItemStringBufferToESDI
    51     call    LineSplitter_GetOffsetToSIforLineCXfromStringInESDI
    52     push    es
    53     pop     ds
     51    call    Memory_CopyESDItoDSSI
     52    call    ItemLineSplitter_GetLineToDSSIandLengthToCXfromStringInDSSIwithIndexInCX
    5453    jmp     ParseSelectionFromItemLineInDSSI
    5554
     
    115114    call    SortDirectoryContentsStringFromESDIwithCountInCX
    116115    call    Memory_CopySSBPtoDSSI
    117     call    Dialog_EventInitializeMenuinitFromDSSI
     116    xor     ax, ax
     117    call    Dialog_EventInitializeMenuinitFromDSSIwithHighlightedItemInAX
    118118    call    GetInfoLinesToCXandDialogFlagsToAX
    119119    mov     [bp+MENUINIT.bInfoLines], cl
    120120    CALL_DISPLAY_LIBRARY GetColumnsToALandRowsToAH
    121121    mov     [bp+MENUINIT.bHeight], ah               ; Always max height
    122     xor     ax, ax
    123     mov     [bp+MENU.wHighlightedItem], ax
    124     mov     [bp+MENU.wFirstVisibleItem], ax
     122    mov     WORD [bp+MENU.wFirstVisibleItem], 0
    125123    ret
    126124
     
    256254    mov     bx, di
    257255    CALL_DISPLAY_LIBRARY PushDisplayContext
    258     CALL_DISPLAY_LIBRARY PrepareOffScreenBufferInESBXtoESDI
     256    mov     cx, -1
     257    CALL_DISPLAY_LIBRARY PrepareOffScreenBufferInESBXwithLengthInCX
    259258
    260259    call    .FormatFileOrDirectoryToBufferFromDTAinDSSI
     
    299298;--------------------------------------------------------------------
    300299.FormatFile:
     300    ; Convert file name to lower case
     301    xchg    si, ax
     302    mov     dx, StringProcess_ConvertToLowerCase
     303    call    StringProcess_DSSIwithFunctionInDX
     304    xchg    ax, si
     305
    301306    ; Push parameters for file name
    302     xchg    si, ax
    303     call    String_ConvertDSSItoLowerCase
    304     xchg    ax, si
    305307    push    ax              ; Push directory name offset
    306308    push    ds              ; Push directory name segment
Note: See TracChangeset for help on using the changeset viewer.