mirror of
https://github.com/dmolony/DiskBrowser.git
synced 2025-01-02 06:31:03 +00:00
dual dos disks use back button correctly
This commit is contained in:
parent
5c95dfe168
commit
457f1f753c
@ -121,7 +121,13 @@ class AppleDiskTab extends AbstractTab
|
||||
void redoEvent (RedoEvent event)
|
||||
{
|
||||
AppleFileSource afs = ((FileSelectedEvent) event.value).appleFileSource;
|
||||
selectNode (((FileSelectedEvent) event.value).appleFileSource.getUniqueName ());
|
||||
FileSelectedEvent fileSelectedEvent = (FileSelectedEvent) event.value;
|
||||
if (fileSelectedEvent.volumeNo >= 0)
|
||||
{
|
||||
DualDosDisk ddd = (DualDosDisk) afs.getFormattedDisk ().getParent ();
|
||||
ddd.setCurrentDiskNo (fileSelectedEvent.volumeNo);
|
||||
}
|
||||
selectNode (fileSelectedEvent.appleFileSource.getUniqueName ());
|
||||
}
|
||||
|
||||
private DefaultMutableTreeNode findNode (String nodeName)
|
||||
|
@ -116,7 +116,7 @@ class CatalogPanel extends JTabbedPane
|
||||
|
||||
// called after a double-click in the fileTab
|
||||
// ---------------------------------------------------------------------------------//
|
||||
public void addDiskPanel (FormattedDisk disk, String lastFileUsed, boolean activate)
|
||||
public void addDiskPanel (FormattedDisk disk, boolean activate)
|
||||
// ---------------------------------------------------------------------------------//
|
||||
{
|
||||
int tabNo = 1;
|
||||
@ -433,7 +433,7 @@ class CatalogPanel extends JTabbedPane
|
||||
// lister.catalogLister.setNode (selectedNode);
|
||||
}
|
||||
else if (e.getClickCount () == 2)
|
||||
addDiskPanel (node.getFormattedDisk (), null, true);
|
||||
addDiskPanel (node.getFormattedDisk (), true);
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -10,6 +10,7 @@ public class FileSelectedEvent extends EventObject
|
||||
{
|
||||
public final AppleFileSource appleFileSource;
|
||||
boolean redo;
|
||||
int volumeNo = -1;
|
||||
|
||||
public FileSelectedEvent (Object source, AppleFileSource appleFileSource)
|
||||
{
|
||||
@ -21,7 +22,10 @@ public class FileSelectedEvent extends EventObject
|
||||
FormattedDisk fd = appleFileSource.getFormattedDisk ();
|
||||
DualDosDisk ddd = (DualDosDisk) fd.getParent ();
|
||||
if (ddd != null)
|
||||
{
|
||||
ddd.setCurrentDisk (fd);
|
||||
volumeNo = ddd.getCurrentDiskNo ();
|
||||
}
|
||||
}
|
||||
|
||||
@Override
|
||||
|
@ -22,6 +22,14 @@ public class Utility
|
||||
.equals (AffineTransform.getScaleInstance (2.0, 2.0));
|
||||
}
|
||||
|
||||
// ---------------------------------------------------------------------------------//
|
||||
public static void printStackTrace ()
|
||||
// ---------------------------------------------------------------------------------//
|
||||
{
|
||||
for (StackTraceElement ste : java.lang.Thread.currentThread ().getStackTrace ())
|
||||
System.out.println (ste);
|
||||
}
|
||||
|
||||
// ---------------------------------------------------------------------------------//
|
||||
static int getLong (byte[] buffer, int ptr)
|
||||
// ---------------------------------------------------------------------------------//
|
||||
|
Loading…
Reference in New Issue
Block a user