mirror of
https://github.com/overcuriousity/autopsy-flatpak.git
synced 2025-07-13 00:16:16 +00:00
Set default DataResult viewer active when selection in directory tree is changed
This commit is contained in:
parent
0e844f00d2
commit
edb851e132
@ -567,6 +567,8 @@ public final class DirectoryTreeTopComponent extends TopComponent implements Dat
|
||||
logger.log(Level.WARNING, "Error resetting node", ex);
|
||||
}
|
||||
}
|
||||
final Node[] oldNodes = (Node[])oldValue;
|
||||
final Node[] newNodes = (Node[])newValue;
|
||||
// Some lock that prevents certain Node operations is set during the
|
||||
// ExplorerManager selection-change, so we must handle changes after the
|
||||
// selection-change event is processed.
|
||||
@ -610,7 +612,15 @@ public final class DirectoryTreeTopComponent extends TopComponent implements Dat
|
||||
}
|
||||
|
||||
// set the directory listing to be active
|
||||
//dataResult.requestActive();
|
||||
if(oldNodes != null && newNodes != null &&
|
||||
(oldNodes.length == newNodes.length)) {
|
||||
boolean sameNodes = true;
|
||||
for(int i = 0; i < oldNodes.length; i++) {
|
||||
sameNodes = sameNodes && oldNodes[i].getName().equals(newNodes[i].getName());
|
||||
}
|
||||
if(!sameNodes)
|
||||
dataResult.requestActive();
|
||||
}
|
||||
} finally {
|
||||
DirectoryTreeTopComponent.this.setCursor(null);
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user