home *** CD-ROM | disk | FTP | other *** search
/ Fish 'n' More 2 / fishmore-publicdomainlibraryvol.ii1991xetec.iso / dirs / reqaztec_419.lzh / ReqAztec / TheReq.asm < prev    next >
Assembly Source File  |  1990-12-18  |  770b  |  37 lines

  1. ; TheReq()    NOT CALLABLE FROM C
  2. ; TheReq(title, text, controls, positivetext, negativetext);
  3. ;         a0     a1      a2          a3            a5
  4.  
  5. TR_SIZEOF    equ        46
  6.  
  7.         xref    _ReqBase
  8.  
  9.         public    TheRequest
  10. TheRequest
  11.         move.l    _ReqBase,a6        ;Load a6 from the data segment _before_ tromping on a4.
  12.  
  13.         sub.w    #TR_SIZEOF,sp    ;get some temporary storage.
  14.  
  15.         move.l    sp,a4
  16.         moveq    #TR_SIZEOF/2-1,d2    ;because the stack is almost never clear.
  17. 1$        clr.w    (a4)+
  18.         dbf        d2,1$
  19.  
  20.         move.l    a1,(sp)                ;TR_Text
  21.         move.l    a2,4(sp)            ;TR_Controls
  22.         move.l    a3,16(sp)            ;TR_PositiveText
  23.         move.l    a5,20(sp)            ;TR_NegativeText
  24.         move.l    a0,24(sp)            ;TR_Title
  25.  
  26.         move.w    #$FFFF,28(sp)        ;TR_KeyMask
  27.  
  28.         move.l    sp,a0
  29.         jsr        -174(a6)            ;TextRequest
  30.  
  31.         add.w    #TR_SIZEOF,sp
  32.  
  33.         movem.l    (sp)+,a2-a6/d2
  34.         rts
  35.  
  36.         end
  37.