Fixed import - need to save the file before setting the address.

This is a specific requirement of how DOS stores addresses.
This commit is contained in:
Robert Greene 2004-06-22 03:08:14 +00:00
parent 8d45503f9a
commit 753a8ecbf6

View File

@ -1108,9 +1108,6 @@ public class DiskExplorerTab {
FileEntry fileEntry = directory.createFile();
fileEntry.setFilename(spec.getTargetFilename());
fileEntry.setFiletype(spec.getFiletype());
if (fileEntry.needsAddress()) {
fileEntry.setAddress(spec.getAddress());
}
try {
fileEntry.setFileData(buffer.toByteArray());
} catch (ProdosDiskSizeDoesNotMatchException ex) {
@ -1130,6 +1127,9 @@ public class DiskExplorerTab {
fileEntry.setFileData(buffer.toByteArray());
}
}
if (fileEntry.needsAddress()) {
fileEntry.setAddress(spec.getAddress());
}
}
} catch (Exception ex) {
MessageBox box = new MessageBox(shell,