diff --git a/src/com/bytezone/diskbrowser/applefile/AbstractFile.java b/src/com/bytezone/diskbrowser/applefile/AbstractFile.java index 667d4c8..8a4033e 100755 --- a/src/com/bytezone/diskbrowser/applefile/AbstractFile.java +++ b/src/com/bytezone/diskbrowser/applefile/AbstractFile.java @@ -17,9 +17,9 @@ public abstract class AbstractFile implements DataSource protected String name; public byte[] buffer; - protected AssemblerProgram assembler; + AssemblerProgram assembler; protected BufferedImage image; - protected int loadAddress; + int loadAddress; ResourceFork resourceFork; // ---------------------------------------------------------------------------------// @@ -35,7 +35,16 @@ public abstract class AbstractFile implements DataSource public String getText () // Override this to get a tailored text representation // ---------------------------------------------------------------------------------// { - return "Name : " + name + "\n\nNo text description"; + StringBuilder text = new StringBuilder (); + + text.append ("Name : " + name + "\n\nNo text description"); + if (resourceFork != null) + { + text.append ("\n\n"); + text.append (resourceFork); + } + + return text.toString (); } // ---------------------------------------------------------------------------------// diff --git a/src/com/bytezone/diskbrowser/applefile/DefaultAppleFile.java b/src/com/bytezone/diskbrowser/applefile/DefaultAppleFile.java index 858ee3d..1f3e7d2 100755 --- a/src/com/bytezone/diskbrowser/applefile/DefaultAppleFile.java +++ b/src/com/bytezone/diskbrowser/applefile/DefaultAppleFile.java @@ -18,6 +18,7 @@ public class DefaultAppleFile extends AbstractFile // ---------------------------------------------------------------------------------// { super (name, buffer); + this.text = "Name : " + name + "\n\n" + text; } @@ -35,8 +36,10 @@ public class DefaultAppleFile extends AbstractFile { if (text != null) return text; + if (buffer == null) return "Invalid file : " + name; + return super.getText (); } } \ No newline at end of file diff --git a/src/com/bytezone/diskbrowser/applefile/OriginalHiResImage.java b/src/com/bytezone/diskbrowser/applefile/OriginalHiResImage.java index 844077a..5d4900c 100755 --- a/src/com/bytezone/diskbrowser/applefile/OriginalHiResImage.java +++ b/src/com/bytezone/diskbrowser/applefile/OriginalHiResImage.java @@ -70,6 +70,8 @@ public class OriginalHiResImage extends HiResImage for (int ptr = base; ptr < max; ptr++) { int value = buffer[ptr] & 0x7F; + if ((buffer[ptr] & 0x80) != 0) + System.out.printf ("bit shift pixel found in %s%n", name); for (int px = 0; px < 7; px++) { int val = (value >> px) & 0x01; diff --git a/src/com/bytezone/diskbrowser/prodos/FileEntry.java b/src/com/bytezone/diskbrowser/prodos/FileEntry.java index 4a39835..ee7e34b 100755 --- a/src/com/bytezone/diskbrowser/prodos/FileEntry.java +++ b/src/com/bytezone/diskbrowser/prodos/FileEntry.java @@ -459,6 +459,10 @@ class FileEntry extends CatalogEntry implements ProdosConstants file = new DeviceDriver (name, exactBuffer, auxType); break; + case FILE_TYPE_TIF: + file = new DefaultAppleFile (name, exactBuffer); + break; + case FILE_TYPE_ICN: file = new IconFile (name, exactBuffer); break; diff --git a/src/com/bytezone/diskbrowser/prodos/ProdosConstants.java b/src/com/bytezone/diskbrowser/prodos/ProdosConstants.java index 80367dc..f60bff2 100755 --- a/src/com/bytezone/diskbrowser/prodos/ProdosConstants.java +++ b/src/com/bytezone/diskbrowser/prodos/ProdosConstants.java @@ -21,6 +21,7 @@ public interface ProdosConstants static int FILE_TYPE_IIGS_SOURCE = 0xB0; static int FILE_TYPE_IIGS_OBJECT = 0xB1; static int FILE_TYPE_IIGS_APPLICATION = 0xB3; + static int FILE_TYPE_TIF = 0xB7; static int FILE_TYPE_IIGS_DEVICE_DRIVER = 0xBB; static int FILE_TYPE_LDF = 0xBC; static int FILE_TYPE_GS_BASIC = 0xAB;