mirror of
https://github.com/overcuriousity/autopsy-flatpak.git
synced 2025-07-06 21:00:22 +00:00
Fix DataContent bug
This commit is contained in:
parent
987465cc6b
commit
ad841ccffc
@ -225,12 +225,20 @@ public final class DataContentTopComponent extends TopComponent implements DataC
|
|||||||
// change the cursor to "waiting cursor" for this operation
|
// change the cursor to "waiting cursor" for this operation
|
||||||
this.setCursor(Cursor.getPredefinedCursor(Cursor.WAIT_CURSOR));
|
this.setCursor(Cursor.getPredefinedCursor(Cursor.WAIT_CURSOR));
|
||||||
try {
|
try {
|
||||||
|
|
||||||
|
|
||||||
|
String defaultName = NbBundle.getMessage(DataContentTopComponent.class, "CTL_DataContentTopComponent");
|
||||||
// set the file path
|
// set the file path
|
||||||
if (selectedNode == null) {
|
if (selectedNode == null) {
|
||||||
setName(NbBundle.getMessage(DataContentTopComponent.class, "CTL_DataContentTopComponent"));
|
setName(defaultName);
|
||||||
} else {
|
} else {
|
||||||
String path = DataConversion.getformattedPath(ContentUtils.getDisplayPath(selectedNode.getLookup().lookup(Content.class)), 0);
|
Content content = selectedNode.getLookup().lookup(Content.class);
|
||||||
setName(path);
|
if (content != null) {
|
||||||
|
String path = DataConversion.getformattedPath(ContentUtils.getDisplayPath(selectedNode.getLookup().lookup(Content.class)), 0);
|
||||||
|
setName(path);
|
||||||
|
} else {
|
||||||
|
setName(defaultName);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
currentNode = selectedNode;
|
currentNode = selectedNode;
|
||||||
|
Loading…
x
Reference in New Issue
Block a user