From f8dee76cd5679bd2ad25da5d7052bd093da3888e Mon Sep 17 00:00:00 2001 From: Rob Greene Date: Fri, 2 Mar 2018 17:26:46 -0600 Subject: [PATCH] This should allow a DOS 3.3 disk to "translate" TXT and BIN properly. Admittedly, this is a bit of a hack, but a number of sources do come from ProDOS, so it allows translation. --- .../applecommander/storage/os/dos33/DosFileEntry.java | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/src/main/java/com/webcodepro/applecommander/storage/os/dos33/DosFileEntry.java b/src/main/java/com/webcodepro/applecommander/storage/os/dos33/DosFileEntry.java index ed2013a..14ba7e0 100644 --- a/src/main/java/com/webcodepro/applecommander/storage/os/dos33/DosFileEntry.java +++ b/src/main/java/com/webcodepro/applecommander/storage/os/dos33/DosFileEntry.java @@ -152,14 +152,15 @@ public class DosFileEntry implements FileEntry { } /** - * Set the filetype. + * Set the filetype. This contains some ProDOS file type translation to support + * translation from an AppleSingle archive. */ public void setFiletype(String filetype) { byte[] data = readFileEntry(); int type = 0x04; // assume binary - if ("T".equals(filetype)) type = 0x00; //$NON-NLS-1$ + if ("T".equals(filetype) || "TXT".equals(filetype)) type = 0x00; //$NON-NLS-1$ if ("I".equals(filetype)) type = 0x01; //$NON-NLS-1$ - if ("A".equals(filetype)) type = 0x02; //$NON-NLS-1$ + if ("A".equals(filetype) || "BAS".equals(filetype)) type = 0x02; //$NON-NLS-1$ if ("B".equals(filetype)) type = 0x04; //$NON-NLS-1$ if ("S".equals(filetype)) type = 0x08; //$NON-NLS-1$ if ("R".equals(filetype)) type = 0x10; //$NON-NLS-1$