From 352ff7df4e1869743f238de34c975129a97c3d33 Mon Sep 17 00:00:00 2001 From: "Christian A. Weber" Date: Mon, 24 May 1993 15:46:47 +0000 Subject: =?UTF-8?q?FORMs=20k=C3=B6nnen=20jetzt=20verschachtelt=20werden=20?= =?UTF-8?q?bei=20Push/PopChunk()?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- Source/IFFLib.S | 44 +++++++++++++++++++++----------------------- 1 file changed, 21 insertions(+), 23 deletions(-) (limited to 'Source/IFFLib.S') diff --git a/Source/IFFLib.S b/Source/IFFLib.S index 9361edb..9d0348f 100644 --- a/Source/IFFLib.S +++ b/Source/IFFLib.S @@ -1,11 +1,10 @@ ** -** $Id: IFFLib.S,v 22.1 92/06/02 16:49:02 chris Exp $ -** $Revision: 22.1 $ +** $Id: IFFLib.S,v 22.2 92/06/03 23:46:04 chris Exp $ +** $Revision: 22.2 $ ** ** $Filename: IFFLib.S $ ** $Author: chris $ -** $Release: 19.1 $ -** $Date: 92/06/02 16:49:02 $ +** $Date: 92/06/03 23:46:04 $ ** ** Disk-resident library for simple IFF file I/O. Does not handle ** nested PROPs and CATs. Contains special ILBM support routines. @@ -55,8 +54,11 @@ SECTION text,CODE * PP_VERSION +* DELEXP ; Wenn definiert wird Delayed Expunge unterstützt + INCLUDE "IFFLib.i" + INCLUDE "IFF_rev.i" XREF FindOurNode ; Error-Node finden @@ -86,21 +88,12 @@ IFD PP_VERSION VERSION: EQU 101 ; D0 bei OpenLibrary REVISION: EQU 4 ; jedesmal um 1 erhöhen - ELSE -VERSION: EQU 22 ; D0 bei OpenLibrary -REVISION: EQU 2 ; jedesmal um 1 erhöhen ENDC ***************************************************************************** ** Diese Routine wird aufgerufen wenn man iff.library als Programm startet -FirstByte: - bra.b 1$ - dc.b "CHW!" -1$: - *** wird aufgerufen, wenn mann die Library vom CLI aus startet - - lea DOSName(PC),a1 ; dos.library öffnen +FirstByte: lea DOSName(PC),a1 ; dos.library öffnen movea.l 4.W,a6 JSRLIB OldOpenLibrary movea.l d0,a6 ; DosBase @@ -108,16 +101,12 @@ FirstByte: move.l d0,d1 ; file: stdout lea MyLibInfo(PC),a0 ; Adresse des ID-Strings move.l a0,d2 - IFD PP_VERSION - moveq.l #67,d3 ; Länge des ID-Strings - ELSE - moveq.l #42,d3 ; Länge des ID-Strings - ENDC + moveq.l #MyLibInfoEnd-MyLibInfo,d3 ; Länge des ID-Strings JSRLIB Write movea.l a6,a1 movea.l 4.W,a6 JSRLIB CloseLibrary ; For Chris - moveq.l #5,d0 ; return-code: WARN + moveq.l #10,d0 ; return-code: ERROR rts ***************************************************************************** @@ -137,9 +126,14 @@ MyROMTag: DC.W RTC_MATCHWORD IFD PP_VERSION MyLibName: DC.B "iffpp.library",0 MyLibInfo: DC.B "IFFPP 101.4 (03.06.92) Copyright © 1990-1992 by Christian A. Weber",10,13,0 +MyLibInfoEnd: ELSE MyLibName: DC.B "iff.library",0 -MyLibInfo: DC.B "IFF 22.2 (03.06.92) by Christian A. Weber",10,13,0 +MyLibInfo: VERS + DC.B " (" + DATE + DC.B ") (-: by Christian A. Weber :-)",13,10,0 +MyLibInfoEnd: ENDC DOSName: DC.B "dos.library",0 @@ -294,12 +288,13 @@ CloseFunc: movem.l a2/a5-a6,-(SP) moveq.l #0,d0 ; return-code subq.w #1,LIB_OPENCNT(a6) + IFD DELEXP bne.b 2$ ; jemand hat sie noch offen - btst.b #LIBB_DELEXP,LIB_FLAGS(a6) ; haben wir delayed Expunge? beq.b 2$ ; neenee ---> bsr.b ExpungeFunc ; sonst Expunge 2$: + ENDC rts ; Library ist jetzt zu ***************************************************************************** @@ -311,7 +306,9 @@ ExpungeFunc: movem.l d2/a5-a6,-(SP) tst.w LIB_OPENCNT(a5) ; sind wir noch offen? beq.b 1$ ; nein + IFD DELEXP bset.b #LIBB_DELEXP,LIB_FLAGS(a5) + ENDC moveq.l #0,d0 ; return-code bra.b 99$ 1$: @@ -326,9 +323,10 @@ ExpungeFunc: movem.l d2/a5-a6,-(SP) moveq.l #0,d0 movea.l a5,a1 ; LibPtr move.w LIB_NEGSIZE(a5),d0 ; Grösse der Sprungtabelle - sub.w d0,a1 ; A1 := Anfang der Sprungtab. + suba.w d0,a1 ; A1 := Anfang der Sprungtab. add.w LIB_POSSIZE(a5),d0 ; D0 := Lib-Grösse gesamt JSRLIB FreeMem ; freigeben + move.l d2,d0 ; return-code: Segmentliste 99$: movem.l (SP)+,d2/a5-a6 -- cgit v1.2.3