diff --git a/Core/src/org/sleuthkit/autopsy/communications/ThumbnailChildren.java b/Core/src/org/sleuthkit/autopsy/communications/AttachmentsChildren.java similarity index 80% rename from Core/src/org/sleuthkit/autopsy/communications/ThumbnailChildren.java rename to Core/src/org/sleuthkit/autopsy/communications/AttachmentsChildren.java index 30a95f35aa..d53e9c6475 100755 --- a/Core/src/org/sleuthkit/autopsy/communications/ThumbnailChildren.java +++ b/Core/src/org/sleuthkit/autopsy/communications/AttachmentsChildren.java @@ -27,7 +27,6 @@ import org.openide.nodes.Children; import org.openide.nodes.Node; import org.openide.nodes.Sheet; import org.openide.util.NbBundle; -import org.sleuthkit.autopsy.coreutils.ImageUtils; import org.sleuthkit.autopsy.coreutils.Logger; import org.sleuthkit.autopsy.datamodel.AbstractAbstractFileNode; import org.sleuthkit.autopsy.datamodel.FileNode; @@ -38,17 +37,12 @@ import org.sleuthkit.datamodel.TskCoreException; /** * Factory for creating thumbnail children nodes. - * - * Given the current way that DataResultViewerThumbnail works this class must - * extend Children.Keys not ChildNodeFactory. When a ChildNodeFactory is used - * the addNotify function in ThumbnailChildNode ends up wtih a list containing - * just the wait node and the thumbanils never appear. */ -final class ThumbnailChildren extends Children.Keys { +final class AttachmentsChildren extends Children.Keys { - private static final Logger logger = Logger.getLogger(ThumbnailChildren.class.getName()); + private static final Logger logger = Logger.getLogger(AttachmentsChildren.class.getName()); - private final Set thumbnails; + private final Set artifacts; /* * Creates the list of thumbnails from the given list of @@ -57,9 +51,24 @@ final class ThumbnailChildren extends Children.Keys { * The thumbnails will be initialls sorted by size, then name so that they * appear sorted by size by default. */ - ThumbnailChildren(Set artifacts) { + AttachmentsChildren(Set artifacts) { super(false); - thumbnails = new TreeSet<>((AbstractFile file1, AbstractFile file2) -> { + + this.artifacts = artifacts; + + + } + + @Override + protected Node[] createNodes(AbstractFile t) { + return new Node[]{new AttachementNode(t)}; + } + + @Override + protected void addNotify() { + super.addNotify(); + + Set thumbnails = new TreeSet<>((AbstractFile file1, AbstractFile file2) -> { int result = Long.compare(file1.getSize(), file2.getSize()); if (result == 0) { result = file1.getName().compareTo(file2.getName()); @@ -71,7 +80,7 @@ final class ThumbnailChildren extends Children.Keys { artifacts.forEach((bba) -> { try { for (Content childContent : bba.getChildren()) { - if (childContent instanceof AbstractFile && ImageUtils.thumbnailSupported((AbstractFile) childContent)) { + if (childContent instanceof AbstractFile) { thumbnails.add((AbstractFile) childContent); } } @@ -79,25 +88,16 @@ final class ThumbnailChildren extends Children.Keys { logger.log(Level.WARNING, "Unable to get children from artifact.", ex); //NON-NLS } }); - } - - @Override - protected Node[] createNodes(AbstractFile t) { - return new Node[]{new ThumbnailNode(t)}; - } - - @Override - protected void addNotify() { - super.addNotify(); + setKeys(thumbnails); } /** * A node for representing a thumbnail. */ - static class ThumbnailNode extends FileNode { + static class AttachementNode extends FileNode { - ThumbnailNode(AbstractFile file) { + AttachementNode(AbstractFile file) { super(file, false); } diff --git a/Core/src/org/sleuthkit/autopsy/communications/Bundle.properties b/Core/src/org/sleuthkit/autopsy/communications/Bundle.properties index 54c65bfc8e..8c67bf93f7 100644 --- a/Core/src/org/sleuthkit/autopsy/communications/Bundle.properties +++ b/Core/src/org/sleuthkit/autopsy/communications/Bundle.properties @@ -32,7 +32,7 @@ VisualizationPanel.zoomInButton.toolTipText=Zoom in VisualizationPanel.zoomInButton.text= VisualizationPanel.zoomOutButton.toolTipText=Zoom out VisualizationPanel.zoomOutButton.text= -VisualizationPanel.fastOrganicLayoutButton.text=Redraw +VisualizationPanel.fastOrganicLayoutButton.text= VisualizationPanel.backButton.text_1= VisualizationPanel.circleLayoutButton.text=Circle VisualizationPanel.organicLayoutButton.text=Organic diff --git a/Core/src/org/sleuthkit/autopsy/communications/Bundle.properties-MERGED b/Core/src/org/sleuthkit/autopsy/communications/Bundle.properties-MERGED index 8739aacaed..21a52f1b18 100755 --- a/Core/src/org/sleuthkit/autopsy/communications/Bundle.properties-MERGED +++ b/Core/src/org/sleuthkit/autopsy/communications/Bundle.properties-MERGED @@ -33,6 +33,7 @@ FiltersPanel.refreshButton.text=Refresh FiltersPanel.deviceRequiredLabel.text=Select at least one. FiltersPanel.accountTypeRequiredLabel.text=Select at least one. FiltersPanel.needsRefreshLabel.text=Displayed data is out of date. Press Refresh. +MediaViewer_Name=Media MessageNode_Node_Property_Attms=Attachments MessageNode_Node_Property_Date=Date MessageNode_Node_Property_From=From @@ -56,7 +57,6 @@ SummaryViewer_CentralRepository_Message= 0) { + if (nodes != null && nodes.length == 1) { nameLabel.setText(nodes[0].getDisplayName()); + propertySheet.setNodes(nodes); } else { nameLabel.setText(""); + propertySheet.setNodes(null); } - - propertySheet.setNodes(nodes); } @Override diff --git a/Core/src/org/sleuthkit/autopsy/communications/ContactNode.java b/Core/src/org/sleuthkit/autopsy/communications/ContactNode.java index 67f8239463..76624e6180 100755 --- a/Core/src/org/sleuthkit/autopsy/communications/ContactNode.java +++ b/Core/src/org/sleuthkit/autopsy/communications/ContactNode.java @@ -19,6 +19,7 @@ package org.sleuthkit.autopsy.communications; import java.util.HashMap; +import java.util.Map; import java.util.TimeZone; import java.util.logging.Level; import org.openide.nodes.Sheet; @@ -80,55 +81,35 @@ final class ContactNode extends BlackboardArtifactNode { } // Sorting the attributes by type so that the duplicates can be removed - // and they can be grouped by type for display. + // and they can be grouped by type for display. The attribute prefixes + // are used so that all attributed of that type are found, including + // ones that are not predefined as part of BlackboardAttributes try { - HashMap phoneNumList = new HashMap<>(); - HashMap emailList = new HashMap<>(); - HashMap nameList = new HashMap<>(); - HashMap otherList = new HashMap<>(); + HashMap phoneNumMap = new HashMap<>(); + HashMap emailMap = new HashMap<>(); + HashMap nameMap = new HashMap<>(); + HashMap otherMap = new HashMap<>(); for (BlackboardAttribute bba : artifact.getAttributes()) { - if (bba.getAttributeType().getTypeName().contains("TSK_PHONE")) { - phoneNumList.put(bba.getDisplayString(), bba); - } else if (bba.getAttributeType().getTypeName().contains("TSK_EMAIL")) { - emailList.put(bba.getDisplayString(), bba); - } else if (bba.getAttributeType().getTypeName().contains("TSK_NAME")) { - nameList.put(bba.getDisplayString(), bba); + if (bba.getAttributeType().getTypeName().startsWith("TSK_PHONE")) { + phoneNumMap.put(bba.getDisplayString(), bba); + } else if (bba.getAttributeType().getTypeName().startsWith("TSK_EMAIL")) { + emailMap.put(bba.getDisplayString(), bba); + } else if (bba.getAttributeType().getTypeName().startsWith("TSK_NAME")) { + nameMap.put(bba.getDisplayString(), bba); } else { - otherList.put(bba.getDisplayString(), bba); - } - } - String propertyID = BlackboardAttribute.ATTRIBUTE_TYPE.TSK_NAME.getLabel(); - int count = 0; - for (BlackboardAttribute bba : nameList.values()) { - if (count++ > 0) { - sheetSet.put(new NodeProperty<>(propertyID + "_" + count, bba.getAttributeType().getDisplayName(), "", bba.getDisplayString())); - } else { - sheetSet.put(new NodeProperty<>(propertyID, bba.getAttributeType().getDisplayName(), "", bba.getDisplayString())); + otherMap.put(bba.getDisplayString(), bba); } } + + addPropertiesToSheet(BlackboardAttribute.ATTRIBUTE_TYPE.TSK_NAME.getLabel(), + sheetSet, nameMap); + addPropertiesToSheet(BlackboardAttribute.ATTRIBUTE_TYPE.TSK_PHONE_NUMBER.getLabel(), + sheetSet, phoneNumMap); + addPropertiesToSheet(BlackboardAttribute.ATTRIBUTE_TYPE.TSK_EMAIL.getLabel(), + sheetSet, emailMap); - propertyID = BlackboardAttribute.ATTRIBUTE_TYPE.TSK_PHONE_NUMBER.getLabel(); - count = 0; - for (BlackboardAttribute bba : phoneNumList.values()) { - if (count++ > 0) { - sheetSet.put(new NodeProperty<>(propertyID + "_" + count, bba.getAttributeType().getDisplayName(), "", bba.getDisplayString())); - } else { - sheetSet.put(new NodeProperty<>(propertyID, bba.getAttributeType().getDisplayName(), "", bba.getDisplayString())); - } - } - - propertyID = BlackboardAttribute.ATTRIBUTE_TYPE.TSK_EMAIL.getLabel(); - count = 0; - for (BlackboardAttribute bba : emailList.values()) { - if (count++ > 0) { - sheetSet.put(new NodeProperty<>(propertyID + "_" + count, bba.getAttributeType().getDisplayName(), "", bba.getDisplayString())); - } else { - sheetSet.put(new NodeProperty<>(propertyID, bba.getAttributeType().getDisplayName(), "", bba.getDisplayString())); - } - } - - for (BlackboardAttribute bba1 : otherList.values()) { - sheetSet.put(new NodeProperty<>(bba1.getAttributeType().getTypeName(), bba1.getAttributeType().getDisplayName(), "", bba1.getDisplayString())); + for (BlackboardAttribute bba : otherMap.values()) { + sheetSet.put(new NodeProperty<>(bba.getAttributeType().getTypeName(), bba.getAttributeType().getDisplayName(), "", bba.getDisplayString())); } } catch (TskCoreException ex) { @@ -137,6 +118,17 @@ final class ContactNode extends BlackboardArtifactNode { return sheet; } + + private void addPropertiesToSheet(String propertyID, Sheet.Set sheetSet, Map attributeMap) { + int count = 0; + for (BlackboardAttribute bba : attributeMap.values()) { + if (count++ > 0) { + sheetSet.put(new NodeProperty<>(propertyID + "_" + count, bba.getAttributeType().getDisplayName(), "", bba.getDisplayString())); + } else { + sheetSet.put(new NodeProperty<>(propertyID, bba.getAttributeType().getDisplayName(), "", bba.getDisplayString())); + } + } + } private static String getAttributeDisplayString(final BlackboardArtifact artifact, final BlackboardAttribute.ATTRIBUTE_TYPE attributeType) { try { diff --git a/Core/src/org/sleuthkit/autopsy/communications/ContactsViewer.java b/Core/src/org/sleuthkit/autopsy/communications/ContactsViewer.java index b43aac70b3..2bb186aaaf 100755 --- a/Core/src/org/sleuthkit/autopsy/communications/ContactsViewer.java +++ b/Core/src/org/sleuthkit/autopsy/communications/ContactsViewer.java @@ -94,7 +94,6 @@ public final class ContactsViewer extends JPanel implements RelationshipsViewer, "TSK_PHONE_NUMBER", BlackboardAttribute.ATTRIBUTE_TYPE.TSK_PHONE_NUMBER.getDisplayName() ); outline.setRootVisible(false); - outline.setSelectionMode(ListSelectionModel.SINGLE_SELECTION); ((DefaultOutlineModel) outline.getOutlineModel()).setNodesColumnLabel(Bundle.ContactsViewer_columnHeader_Name()); tableEM.addPropertyChangeListener((PropertyChangeEvent evt) -> { diff --git a/Core/src/org/sleuthkit/autopsy/communications/ThumbnailViewer.form b/Core/src/org/sleuthkit/autopsy/communications/MediaViewer.form similarity index 94% rename from Core/src/org/sleuthkit/autopsy/communications/ThumbnailViewer.form rename to Core/src/org/sleuthkit/autopsy/communications/MediaViewer.form index a55bacb9bc..8f311d3dd4 100755 --- a/Core/src/org/sleuthkit/autopsy/communications/ThumbnailViewer.form +++ b/Core/src/org/sleuthkit/autopsy/communications/MediaViewer.form @@ -44,6 +44,9 @@ + + + diff --git a/Core/src/org/sleuthkit/autopsy/communications/ThumbnailViewer.java b/Core/src/org/sleuthkit/autopsy/communications/MediaViewer.java similarity index 92% rename from Core/src/org/sleuthkit/autopsy/communications/ThumbnailViewer.java rename to Core/src/org/sleuthkit/autopsy/communications/MediaViewer.java index a4dea6493f..aa7d5ce707 100755 --- a/Core/src/org/sleuthkit/autopsy/communications/ThumbnailViewer.java +++ b/Core/src/org/sleuthkit/autopsy/communications/MediaViewer.java @@ -46,11 +46,11 @@ import org.sleuthkit.datamodel.Content; import org.sleuthkit.datamodel.TskCoreException; /** - * + * A Panel that shows the media (thumbnails) for the selected account. */ -public class ThumbnailViewer extends JPanel implements RelationshipsViewer, ExplorerManager.Provider, Lookup.Provider { +final class MediaViewer extends JPanel implements RelationshipsViewer, ExplorerManager.Provider, Lookup.Provider { - private static final Logger logger = Logger.getLogger(ThumbnailChildren.class.getName()); + private static final Logger logger = Logger.getLogger(MediaViewer.class.getName()); private final ExplorerManager tableEM = new ExplorerManager(); private final PropertyChangeListener focusPropertyListener; @@ -58,12 +58,12 @@ public class ThumbnailViewer extends JPanel implements RelationshipsViewer, Expl private final ModifiableProxyLookup proxyLookup; @Messages({ - "ThumbnailViewer_Name=Media" + "MediaViewer_Name=Media" }) /** * Creates new form ThumbnailViewer */ - public ThumbnailViewer() { + public MediaViewer() { proxyLookup = new ModifiableProxyLookup(createLookup(tableEM, getActionMap())); // See org.sleuthkit.autopsy.timeline.TimeLineTopComponent for a detailed @@ -78,7 +78,7 @@ public class ThumbnailViewer extends JPanel implements RelationshipsViewer, Expl if (isDescendingFrom(newFocusOwner, contentViewer)) { //if the focus owner is within the MessageContentViewer (the attachments table) proxyLookup.setNewLookups(createLookup(((MessageDataContent) contentViewer).getExplorerManager(), getActionMap())); - } else if (isDescendingFrom(newFocusOwner, ThumbnailViewer.this)) { + } else if (isDescendingFrom(newFocusOwner, MediaViewer.this)) { //... or if it is within the Results table. proxyLookup.setNewLookups(createLookup(tableEM, getActionMap())); @@ -99,7 +99,7 @@ public class ThumbnailViewer extends JPanel implements RelationshipsViewer, Expl @Override public String getDisplayName() { - return Bundle.ThumbnailViewer_Name(); + return Bundle.MediaViewer_Name(); } @Override @@ -130,7 +130,7 @@ public class ThumbnailViewer extends JPanel implements RelationshipsViewer, Expl thumbnailViewer.resetComponent(); } - thumbnailViewer.setNode(new TableFilterNode(new DataResultFilterNode(new AbstractNode(new ThumbnailChildren(artifactList)), tableEM), true)); + thumbnailViewer.setNode(new TableFilterNode(new DataResultFilterNode(new AbstractNode(new AttachmentsChildren(artifactList)), tableEM), true, this.getClass().getName())); } @Override @@ -164,7 +164,7 @@ public class ThumbnailViewer extends JPanel implements RelationshipsViewer, Expl private void handleNodeSelectionChange() { final Node[] nodes = tableEM.getSelectedNodes(); - if (nodes != null && nodes.length > 0) { + if (nodes != null && nodes.length == 1) { AbstractContent thumbnail = nodes[0].getLookup().lookup(AbstractContent.class); if (thumbnail != null) { try { @@ -195,6 +195,7 @@ public class ThumbnailViewer extends JPanel implements RelationshipsViewer, Expl separator = new javax.swing.JSeparator(); thumbnailViewer.setMinimumSize(new java.awt.Dimension(350, 102)); + thumbnailViewer.setPreferredSize(new java.awt.Dimension(450, 400)); contentViewer.setPreferredSize(new java.awt.Dimension(450, 400)); diff --git a/Core/src/org/sleuthkit/autopsy/communications/MessagesViewer.java b/Core/src/org/sleuthkit/autopsy/communications/MessagesViewer.java index 3d8ce847c1..4eb3b1b61e 100755 --- a/Core/src/org/sleuthkit/autopsy/communications/MessagesViewer.java +++ b/Core/src/org/sleuthkit/autopsy/communications/MessagesViewer.java @@ -99,14 +99,13 @@ public final class MessagesViewer extends JPanel implements RelationshipsViewer, "Type", "Type" ); outline.setRootVisible(false); - outline.setSelectionMode(ListSelectionModel.SINGLE_SELECTION); ((DefaultOutlineModel) outline.getOutlineModel()).setNodesColumnLabel("Type"); tableEM.addPropertyChangeListener((PropertyChangeEvent evt) -> { if (evt.getPropertyName().equals(ExplorerManager.PROP_SELECTED_NODES)) { final Node[] nodes = tableEM.getSelectedNodes(); - if (nodes != null && nodes.length > 0) { + if (nodes != null && nodes.length == 1) { contentViewer.setNode(nodes[0]); } else { diff --git a/Core/src/org/sleuthkit/autopsy/communications/RelationshipBrowser.java b/Core/src/org/sleuthkit/autopsy/communications/RelationshipBrowser.java index aaeafa7c3a..9d66941fda 100755 --- a/Core/src/org/sleuthkit/autopsy/communications/RelationshipBrowser.java +++ b/Core/src/org/sleuthkit/autopsy/communications/RelationshipBrowser.java @@ -32,8 +32,8 @@ final class RelationshipBrowser extends JPanel implements Lookup.Provider { private final MessagesViewer messagesViewer; private final ContactsViewer contactsViewer; - private final ThumbnailViewer thumbnailsViewer; private final SummaryViewer summaryViewer; + private final MediaViewer mediaViewer; private final ModifiableProxyLookup proxyLookup; @@ -43,8 +43,8 @@ final class RelationshipBrowser extends JPanel implements Lookup.Provider { public RelationshipBrowser() { messagesViewer = new MessagesViewer(); contactsViewer = new ContactsViewer(); - thumbnailsViewer = new ThumbnailViewer(); summaryViewer = new SummaryViewer(); + mediaViewer = new MediaViewer(); proxyLookup = new ModifiableProxyLookup(messagesViewer.getLookup()); @@ -53,7 +53,7 @@ final class RelationshipBrowser extends JPanel implements Lookup.Provider { tabPane.add(summaryViewer.getDisplayName(), summaryViewer); tabPane.add(messagesViewer.getDisplayName(), messagesViewer); tabPane.add(contactsViewer.getDisplayName(), contactsViewer); - tabPane.add(thumbnailsViewer.getDisplayName(), thumbnailsViewer); + tabPane.add(mediaViewer.getDisplayName(), mediaViewer); } diff --git a/Core/src/org/sleuthkit/autopsy/communications/VisualizationPanel.java b/Core/src/org/sleuthkit/autopsy/communications/VisualizationPanel.java index e87d6464c1..8f202d289b 100644 --- a/Core/src/org/sleuthkit/autopsy/communications/VisualizationPanel.java +++ b/Core/src/org/sleuthkit/autopsy/communications/VisualizationPanel.java @@ -371,219 +371,223 @@ final public class VisualizationPanel extends JPanel { // //GEN-BEGIN:initComponents private void initComponents() { - splitPane = new JSplitPane(); - borderLayoutPanel = new JPanel(); - placeHolderPanel = new JPanel(); - jTextArea1 = new JTextArea(); - toolbar = new JPanel(); - fastOrganicLayoutButton = new JButton(); - zoomOutButton = new JButton(); - zoomInButton = new JButton(); - zoomActualButton = new JButton(); - fitZoomButton = new JButton(); - jLabel2 = new JLabel(); - zoomLabel = new JLabel(); - clearVizButton = new JButton(); - jSeparator2 = new JToolBar.Separator(); - backButton = new JButton(); - forwardButton = new JButton(); - snapshotButton = new JButton(); - jSeparator3 = new JToolBar.Separator(); - jSeparator4 = new JToolBar.Separator(); - notificationsJFXPanel = new JFXPanel(); + splitPane = new javax.swing.JSplitPane(); + borderLayoutPanel = new javax.swing.JPanel(); + placeHolderPanel = new javax.swing.JPanel(); + jTextArea1 = new javax.swing.JTextArea(); + toolbar = new javax.swing.JPanel(); + fastOrganicLayoutButton = new javax.swing.JButton(); + zoomOutButton = new javax.swing.JButton(); + zoomInButton = new javax.swing.JButton(); + zoomActualButton = new javax.swing.JButton(); + fitZoomButton = new javax.swing.JButton(); + jLabel2 = new javax.swing.JLabel(); + zoomLabel = new javax.swing.JLabel(); + clearVizButton = new javax.swing.JButton(); + jSeparator2 = new javax.swing.JToolBar.Separator(); + backButton = new javax.swing.JButton(); + forwardButton = new javax.swing.JButton(); + snapshotButton = new javax.swing.JButton(); + jSeparator3 = new javax.swing.JToolBar.Separator(); + jSeparator4 = new javax.swing.JToolBar.Separator(); + notificationsJFXPanel = new javafx.embed.swing.JFXPanel(); - setLayout(new BorderLayout()); + setLayout(new java.awt.BorderLayout()); splitPane.setDividerLocation(800); splitPane.setResizeWeight(0.5); - borderLayoutPanel.setLayout(new BorderLayout()); + borderLayoutPanel.setLayout(new java.awt.BorderLayout()); - jTextArea1.setBackground(new Color(240, 240, 240)); + jTextArea1.setBackground(new java.awt.Color(240, 240, 240)); jTextArea1.setColumns(20); jTextArea1.setLineWrap(true); jTextArea1.setRows(5); - jTextArea1.setText(NbBundle.getMessage(VisualizationPanel.class, "VisualizationPanel.jTextArea1.text")); // NOI18N + jTextArea1.setText(org.openide.util.NbBundle.getMessage(VisualizationPanel.class, "VisualizationPanel.jTextArea1.text")); // NOI18N - GroupLayout placeHolderPanelLayout = new GroupLayout(placeHolderPanel); + org.jdesktop.layout.GroupLayout placeHolderPanelLayout = new org.jdesktop.layout.GroupLayout(placeHolderPanel); placeHolderPanel.setLayout(placeHolderPanelLayout); - placeHolderPanelLayout.setHorizontalGroup(placeHolderPanelLayout.createParallelGroup(GroupLayout.LEADING) + placeHolderPanelLayout.setHorizontalGroup( + placeHolderPanelLayout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING) .add(placeHolderPanelLayout.createSequentialGroup() .addContainerGap(250, Short.MAX_VALUE) - .add(jTextArea1, GroupLayout.PREFERRED_SIZE, 424, GroupLayout.PREFERRED_SIZE) + .add(jTextArea1, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE, 424, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE) .addContainerGap(423, Short.MAX_VALUE)) ); - placeHolderPanelLayout.setVerticalGroup(placeHolderPanelLayout.createParallelGroup(GroupLayout.LEADING) + placeHolderPanelLayout.setVerticalGroup( + placeHolderPanelLayout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING) .add(placeHolderPanelLayout.createSequentialGroup() - .addContainerGap(GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE) - .add(jTextArea1, GroupLayout.PREFERRED_SIZE, 47, GroupLayout.PREFERRED_SIZE) - .addContainerGap(GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)) + .addContainerGap(org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE) + .add(jTextArea1, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE, 47, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE) + .addContainerGap(org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)) ); - borderLayoutPanel.add(placeHolderPanel, BorderLayout.CENTER); + borderLayoutPanel.add(placeHolderPanel, java.awt.BorderLayout.CENTER); - fastOrganicLayoutButton.setIcon(new ImageIcon(getClass().getResource("/org/sleuthkit/autopsy/communications/images/arrow-circle-double-135.png"))); // NOI18N - fastOrganicLayoutButton.setText(NbBundle.getMessage(VisualizationPanel.class, "VisualizationPanel.fastOrganicLayoutButton.text")); // NOI18N - fastOrganicLayoutButton.setToolTipText(NbBundle.getMessage(VisualizationPanel.class, "VisualizationPanel.fastOrganicLayoutButton.toolTipText")); // NOI18N + fastOrganicLayoutButton.setIcon(new javax.swing.ImageIcon(getClass().getResource("/org/sleuthkit/autopsy/communications/images/arrow-circle-double-135.png"))); // NOI18N + fastOrganicLayoutButton.setText(org.openide.util.NbBundle.getMessage(VisualizationPanel.class, "VisualizationPanel.fastOrganicLayoutButton.text")); // NOI18N + fastOrganicLayoutButton.setToolTipText(org.openide.util.NbBundle.getMessage(VisualizationPanel.class, "VisualizationPanel.fastOrganicLayoutButton.toolTipText")); // NOI18N fastOrganicLayoutButton.setFocusable(false); - fastOrganicLayoutButton.setVerticalTextPosition(SwingConstants.BOTTOM); + fastOrganicLayoutButton.setVerticalTextPosition(javax.swing.SwingConstants.BOTTOM); - zoomOutButton.setIcon(new ImageIcon(getClass().getResource("/org/sleuthkit/autopsy/communications/images/magnifier-zoom-out-red.png"))); // NOI18N - zoomOutButton.setText(NbBundle.getMessage(VisualizationPanel.class, "VisualizationPanel.zoomOutButton.text")); // NOI18N - zoomOutButton.setToolTipText(NbBundle.getMessage(VisualizationPanel.class, "VisualizationPanel.zoomOutButton.toolTipText")); // NOI18N + zoomOutButton.setIcon(new javax.swing.ImageIcon(getClass().getResource("/org/sleuthkit/autopsy/communications/images/magnifier-zoom-out-red.png"))); // NOI18N + zoomOutButton.setText(org.openide.util.NbBundle.getMessage(VisualizationPanel.class, "VisualizationPanel.zoomOutButton.text")); // NOI18N + zoomOutButton.setToolTipText(org.openide.util.NbBundle.getMessage(VisualizationPanel.class, "VisualizationPanel.zoomOutButton.toolTipText")); // NOI18N zoomOutButton.setFocusable(false); - zoomOutButton.setHorizontalTextPosition(SwingConstants.CENTER); - zoomOutButton.setVerticalTextPosition(SwingConstants.BOTTOM); - zoomOutButton.addActionListener(new ActionListener() { - public void actionPerformed(ActionEvent evt) { + zoomOutButton.setHorizontalTextPosition(javax.swing.SwingConstants.CENTER); + zoomOutButton.setVerticalTextPosition(javax.swing.SwingConstants.BOTTOM); + zoomOutButton.addActionListener(new java.awt.event.ActionListener() { + public void actionPerformed(java.awt.event.ActionEvent evt) { zoomOutButtonActionPerformed(evt); } }); - zoomInButton.setIcon(new ImageIcon(getClass().getResource("/org/sleuthkit/autopsy/communications/images/magnifier-zoom-in-green.png"))); // NOI18N - zoomInButton.setText(NbBundle.getMessage(VisualizationPanel.class, "VisualizationPanel.zoomInButton.text")); // NOI18N - zoomInButton.setToolTipText(NbBundle.getMessage(VisualizationPanel.class, "VisualizationPanel.zoomInButton.toolTipText")); // NOI18N + zoomInButton.setIcon(new javax.swing.ImageIcon(getClass().getResource("/org/sleuthkit/autopsy/communications/images/magnifier-zoom-in-green.png"))); // NOI18N + zoomInButton.setText(org.openide.util.NbBundle.getMessage(VisualizationPanel.class, "VisualizationPanel.zoomInButton.text")); // NOI18N + zoomInButton.setToolTipText(org.openide.util.NbBundle.getMessage(VisualizationPanel.class, "VisualizationPanel.zoomInButton.toolTipText")); // NOI18N zoomInButton.setFocusable(false); - zoomInButton.setHorizontalTextPosition(SwingConstants.CENTER); - zoomInButton.setVerticalTextPosition(SwingConstants.BOTTOM); - zoomInButton.addActionListener(new ActionListener() { - public void actionPerformed(ActionEvent evt) { + zoomInButton.setHorizontalTextPosition(javax.swing.SwingConstants.CENTER); + zoomInButton.setVerticalTextPosition(javax.swing.SwingConstants.BOTTOM); + zoomInButton.addActionListener(new java.awt.event.ActionListener() { + public void actionPerformed(java.awt.event.ActionEvent evt) { zoomInButtonActionPerformed(evt); } }); - zoomActualButton.setIcon(new ImageIcon(getClass().getResource("/org/sleuthkit/autopsy/communications/images/magnifier-zoom-actual.png"))); // NOI18N - zoomActualButton.setText(NbBundle.getMessage(VisualizationPanel.class, "VisualizationPanel.zoomActualButton.text")); // NOI18N - zoomActualButton.setToolTipText(NbBundle.getMessage(VisualizationPanel.class, "VisualizationPanel.zoomActualButton.toolTipText")); // NOI18N + zoomActualButton.setIcon(new javax.swing.ImageIcon(getClass().getResource("/org/sleuthkit/autopsy/communications/images/magnifier-zoom-actual.png"))); // NOI18N + zoomActualButton.setText(org.openide.util.NbBundle.getMessage(VisualizationPanel.class, "VisualizationPanel.zoomActualButton.text")); // NOI18N + zoomActualButton.setToolTipText(org.openide.util.NbBundle.getMessage(VisualizationPanel.class, "VisualizationPanel.zoomActualButton.toolTipText")); // NOI18N zoomActualButton.setFocusable(false); - zoomActualButton.setHorizontalTextPosition(SwingConstants.CENTER); - zoomActualButton.setVerticalTextPosition(SwingConstants.BOTTOM); - zoomActualButton.addActionListener(new ActionListener() { - public void actionPerformed(ActionEvent evt) { + zoomActualButton.setHorizontalTextPosition(javax.swing.SwingConstants.CENTER); + zoomActualButton.setVerticalTextPosition(javax.swing.SwingConstants.BOTTOM); + zoomActualButton.addActionListener(new java.awt.event.ActionListener() { + public void actionPerformed(java.awt.event.ActionEvent evt) { zoomActualButtonActionPerformed(evt); } }); - fitZoomButton.setIcon(new ImageIcon(getClass().getResource("/org/sleuthkit/autopsy/communications/images/magnifier-zoom-fit.png"))); // NOI18N - fitZoomButton.setText(NbBundle.getMessage(VisualizationPanel.class, "VisualizationPanel.fitZoomButton.text")); // NOI18N - fitZoomButton.setToolTipText(NbBundle.getMessage(VisualizationPanel.class, "VisualizationPanel.fitZoomButton.toolTipText")); // NOI18N + fitZoomButton.setIcon(new javax.swing.ImageIcon(getClass().getResource("/org/sleuthkit/autopsy/communications/images/magnifier-zoom-fit.png"))); // NOI18N + fitZoomButton.setText(org.openide.util.NbBundle.getMessage(VisualizationPanel.class, "VisualizationPanel.fitZoomButton.text")); // NOI18N + fitZoomButton.setToolTipText(org.openide.util.NbBundle.getMessage(VisualizationPanel.class, "VisualizationPanel.fitZoomButton.toolTipText")); // NOI18N fitZoomButton.setFocusable(false); - fitZoomButton.setHorizontalTextPosition(SwingConstants.CENTER); - fitZoomButton.setVerticalTextPosition(SwingConstants.BOTTOM); - fitZoomButton.addActionListener(new ActionListener() { - public void actionPerformed(ActionEvent evt) { + fitZoomButton.setHorizontalTextPosition(javax.swing.SwingConstants.CENTER); + fitZoomButton.setVerticalTextPosition(javax.swing.SwingConstants.BOTTOM); + fitZoomButton.addActionListener(new java.awt.event.ActionListener() { + public void actionPerformed(java.awt.event.ActionEvent evt) { fitZoomButtonActionPerformed(evt); } }); - jLabel2.setText(NbBundle.getMessage(VisualizationPanel.class, "VisualizationPanel.jLabel2.text")); // NOI18N + jLabel2.setText(org.openide.util.NbBundle.getMessage(VisualizationPanel.class, "VisualizationPanel.jLabel2.text")); // NOI18N - zoomLabel.setText(NbBundle.getMessage(VisualizationPanel.class, "VisualizationPanel.zoomLabel.text")); // NOI18N + zoomLabel.setText(org.openide.util.NbBundle.getMessage(VisualizationPanel.class, "VisualizationPanel.zoomLabel.text")); // NOI18N - clearVizButton.setIcon(new ImageIcon(getClass().getResource("/org/sleuthkit/autopsy/communications/images/broom.png"))); // NOI18N - clearVizButton.setText(NbBundle.getMessage(VisualizationPanel.class, "VisualizationPanel.clearVizButton.text_1")); // NOI18N - clearVizButton.setToolTipText(NbBundle.getMessage(VisualizationPanel.class, "VisualizationPanel.clearVizButton.toolTipText")); // NOI18N - clearVizButton.setActionCommand(NbBundle.getMessage(VisualizationPanel.class, "VisualizationPanel.clearVizButton.actionCommand")); // NOI18N - clearVizButton.addActionListener(new ActionListener() { - public void actionPerformed(ActionEvent evt) { + clearVizButton.setIcon(new javax.swing.ImageIcon(getClass().getResource("/org/sleuthkit/autopsy/communications/images/broom.png"))); // NOI18N + clearVizButton.setText(org.openide.util.NbBundle.getMessage(VisualizationPanel.class, "VisualizationPanel.clearVizButton.text_1")); // NOI18N + clearVizButton.setToolTipText(org.openide.util.NbBundle.getMessage(VisualizationPanel.class, "VisualizationPanel.clearVizButton.toolTipText")); // NOI18N + clearVizButton.setActionCommand(org.openide.util.NbBundle.getMessage(VisualizationPanel.class, "VisualizationPanel.clearVizButton.actionCommand")); // NOI18N + clearVizButton.addActionListener(new java.awt.event.ActionListener() { + public void actionPerformed(java.awt.event.ActionEvent evt) { clearVizButtonActionPerformed(evt); } }); - jSeparator2.setOrientation(SwingConstants.VERTICAL); + jSeparator2.setOrientation(javax.swing.SwingConstants.VERTICAL); - backButton.setIcon(new ImageIcon(getClass().getResource("/org/sleuthkit/autopsy/images/resultset_previous.png"))); // NOI18N - backButton.setText(NbBundle.getMessage(VisualizationPanel.class, "VisualizationPanel.backButton.text_1")); // NOI18N - backButton.setToolTipText(NbBundle.getMessage(VisualizationPanel.class, "VisualizationPanel.backButton.toolTipText")); // NOI18N - backButton.addActionListener(new ActionListener() { - public void actionPerformed(ActionEvent evt) { + backButton.setIcon(new javax.swing.ImageIcon(getClass().getResource("/org/sleuthkit/autopsy/images/resultset_previous.png"))); // NOI18N + backButton.setText(org.openide.util.NbBundle.getMessage(VisualizationPanel.class, "VisualizationPanel.backButton.text_1")); // NOI18N + backButton.setToolTipText(org.openide.util.NbBundle.getMessage(VisualizationPanel.class, "VisualizationPanel.backButton.toolTipText")); // NOI18N + backButton.addActionListener(new java.awt.event.ActionListener() { + public void actionPerformed(java.awt.event.ActionEvent evt) { backButtonActionPerformed(evt); } }); - forwardButton.setIcon(new ImageIcon(getClass().getResource("/org/sleuthkit/autopsy/images/resultset_next.png"))); // NOI18N - forwardButton.setText(NbBundle.getMessage(VisualizationPanel.class, "VisualizationPanel.forwardButton.text")); // NOI18N - forwardButton.setToolTipText(NbBundle.getMessage(VisualizationPanel.class, "VisualizationPanel.forwardButton.toolTipText")); // NOI18N - forwardButton.setHorizontalTextPosition(SwingConstants.LEADING); - forwardButton.addActionListener(new ActionListener() { - public void actionPerformed(ActionEvent evt) { + forwardButton.setIcon(new javax.swing.ImageIcon(getClass().getResource("/org/sleuthkit/autopsy/images/resultset_next.png"))); // NOI18N + forwardButton.setText(org.openide.util.NbBundle.getMessage(VisualizationPanel.class, "VisualizationPanel.forwardButton.text")); // NOI18N + forwardButton.setToolTipText(org.openide.util.NbBundle.getMessage(VisualizationPanel.class, "VisualizationPanel.forwardButton.toolTipText")); // NOI18N + forwardButton.setHorizontalTextPosition(javax.swing.SwingConstants.LEADING); + forwardButton.addActionListener(new java.awt.event.ActionListener() { + public void actionPerformed(java.awt.event.ActionEvent evt) { forwardButtonActionPerformed(evt); } }); - snapshotButton.setIcon(new ImageIcon(getClass().getResource("/org/sleuthkit/autopsy/report/images/image.png"))); // NOI18N - snapshotButton.setText(NbBundle.getMessage(VisualizationPanel.class, "VisualizationPanel.snapshotButton.text_1")); // NOI18N - snapshotButton.addActionListener(new ActionListener() { - public void actionPerformed(ActionEvent evt) { + snapshotButton.setIcon(new javax.swing.ImageIcon(getClass().getResource("/org/sleuthkit/autopsy/report/images/image.png"))); // NOI18N + snapshotButton.setText(org.openide.util.NbBundle.getMessage(VisualizationPanel.class, "VisualizationPanel.snapshotButton.text_1")); // NOI18N + snapshotButton.addActionListener(new java.awt.event.ActionListener() { + public void actionPerformed(java.awt.event.ActionEvent evt) { snapshotButtonActionPerformed(evt); } }); - jSeparator3.setOrientation(SwingConstants.VERTICAL); + jSeparator3.setOrientation(javax.swing.SwingConstants.VERTICAL); - jSeparator4.setOrientation(SwingConstants.VERTICAL); + jSeparator4.setOrientation(javax.swing.SwingConstants.VERTICAL); - GroupLayout toolbarLayout = new GroupLayout(toolbar); + org.jdesktop.layout.GroupLayout toolbarLayout = new org.jdesktop.layout.GroupLayout(toolbar); toolbar.setLayout(toolbarLayout); - toolbarLayout.setHorizontalGroup(toolbarLayout.createParallelGroup(GroupLayout.LEADING) + toolbarLayout.setHorizontalGroup( + toolbarLayout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING) .add(toolbarLayout.createSequentialGroup() .addContainerGap() .add(backButton) - .addPreferredGap(LayoutStyle.RELATED) + .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED) .add(forwardButton) - .addPreferredGap(LayoutStyle.RELATED) - .add(jSeparator4, GroupLayout.PREFERRED_SIZE, 10, GroupLayout.PREFERRED_SIZE) - .addPreferredGap(LayoutStyle.RELATED) + .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED) + .add(jSeparator4, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE, 10, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE) + .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED) .add(fastOrganicLayoutButton) - .addPreferredGap(LayoutStyle.RELATED) + .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED) .add(clearVizButton) - .addPreferredGap(LayoutStyle.RELATED) - .add(jSeparator2, GroupLayout.PREFERRED_SIZE, 10, GroupLayout.PREFERRED_SIZE) - .addPreferredGap(LayoutStyle.RELATED) + .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED) + .add(jSeparator2, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE, 10, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE) + .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED) .add(jLabel2) - .addPreferredGap(LayoutStyle.RELATED) + .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED) .add(zoomLabel) - .addPreferredGap(LayoutStyle.RELATED) - .add(zoomOutButton, GroupLayout.PREFERRED_SIZE, 32, GroupLayout.PREFERRED_SIZE) - .addPreferredGap(LayoutStyle.RELATED) - .add(zoomInButton, GroupLayout.PREFERRED_SIZE, 32, GroupLayout.PREFERRED_SIZE) - .addPreferredGap(LayoutStyle.RELATED) - .add(zoomActualButton, GroupLayout.PREFERRED_SIZE, 33, GroupLayout.PREFERRED_SIZE) - .addPreferredGap(LayoutStyle.RELATED) - .add(fitZoomButton, GroupLayout.PREFERRED_SIZE, 32, GroupLayout.PREFERRED_SIZE) - .addPreferredGap(LayoutStyle.RELATED) - .add(jSeparator3, GroupLayout.PREFERRED_SIZE, 10, GroupLayout.PREFERRED_SIZE) - .addPreferredGap(LayoutStyle.RELATED) + .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED) + .add(zoomOutButton, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE, 32, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE) + .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED) + .add(zoomInButton, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE, 32, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE) + .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED) + .add(zoomActualButton, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE, 33, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE) + .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED) + .add(fitZoomButton, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE, 32, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE) + .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED) + .add(jSeparator3, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE, 10, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE) + .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED) .add(snapshotButton) - .addContainerGap(GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)) + .addContainerGap(org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)) ); - toolbarLayout.setVerticalGroup(toolbarLayout.createParallelGroup(GroupLayout.LEADING) + toolbarLayout.setVerticalGroup( + toolbarLayout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING) .add(toolbarLayout.createSequentialGroup() .add(3, 3, 3) - .add(toolbarLayout.createParallelGroup(GroupLayout.CENTER) + .add(toolbarLayout.createParallelGroup(org.jdesktop.layout.GroupLayout.CENTER) .add(fastOrganicLayoutButton) .add(zoomOutButton) - .add(zoomInButton, GroupLayout.DEFAULT_SIZE, GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE) - .add(zoomActualButton, GroupLayout.DEFAULT_SIZE, GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE) - .add(fitZoomButton, GroupLayout.DEFAULT_SIZE, GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE) + .add(zoomInButton, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE) + .add(zoomActualButton, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE) + .add(fitZoomButton, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE) .add(jLabel2) .add(zoomLabel) .add(clearVizButton) - .add(jSeparator2, GroupLayout.DEFAULT_SIZE, GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE) + .add(jSeparator2, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE) .add(backButton) .add(forwardButton) .add(snapshotButton) - .add(jSeparator3, GroupLayout.DEFAULT_SIZE, GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE) - .add(jSeparator4, GroupLayout.DEFAULT_SIZE, GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)) + .add(jSeparator3, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE) + .add(jSeparator4, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)) .add(3, 3, 3)) ); - borderLayoutPanel.add(toolbar, BorderLayout.PAGE_START); - borderLayoutPanel.add(notificationsJFXPanel, BorderLayout.PAGE_END); + borderLayoutPanel.add(toolbar, java.awt.BorderLayout.PAGE_START); + borderLayoutPanel.add(notificationsJFXPanel, java.awt.BorderLayout.PAGE_END); splitPane.setLeftComponent(borderLayoutPanel); - add(splitPane, BorderLayout.CENTER); + add(splitPane, java.awt.BorderLayout.CENTER); }// //GEN-END:initComponents private void fitZoomButtonActionPerformed(ActionEvent evt) {//GEN-FIRST:event_fitZoomButtonActionPerformed @@ -874,26 +878,26 @@ final public class VisualizationPanel extends JPanel { } // Variables declaration - do not modify//GEN-BEGIN:variables - private JButton backButton; - private JPanel borderLayoutPanel; - private JButton clearVizButton; - private JButton fastOrganicLayoutButton; - private JButton fitZoomButton; - private JButton forwardButton; - private JLabel jLabel2; - private JToolBar.Separator jSeparator2; - private JToolBar.Separator jSeparator3; - private JToolBar.Separator jSeparator4; - private JTextArea jTextArea1; - private JFXPanel notificationsJFXPanel; - private JPanel placeHolderPanel; - private JButton snapshotButton; - private JSplitPane splitPane; - private JPanel toolbar; - private JButton zoomActualButton; - private JButton zoomInButton; - private JLabel zoomLabel; - private JButton zoomOutButton; + private javax.swing.JButton backButton; + private javax.swing.JPanel borderLayoutPanel; + private javax.swing.JButton clearVizButton; + private javax.swing.JButton fastOrganicLayoutButton; + private javax.swing.JButton fitZoomButton; + private javax.swing.JButton forwardButton; + private javax.swing.JLabel jLabel2; + private javax.swing.JToolBar.Separator jSeparator2; + private javax.swing.JToolBar.Separator jSeparator3; + private javax.swing.JToolBar.Separator jSeparator4; + private javax.swing.JTextArea jTextArea1; + private javafx.embed.swing.JFXPanel notificationsJFXPanel; + private javax.swing.JPanel placeHolderPanel; + private javax.swing.JButton snapshotButton; + private javax.swing.JSplitPane splitPane; + private javax.swing.JPanel toolbar; + private javax.swing.JButton zoomActualButton; + private javax.swing.JButton zoomInButton; + private javax.swing.JLabel zoomLabel; + private javax.swing.JButton zoomOutButton; // End of variables declaration//GEN-END:variables /** diff --git a/Core/src/org/sleuthkit/autopsy/contentviewers/MessageContentViewer.java b/Core/src/org/sleuthkit/autopsy/contentviewers/MessageContentViewer.java index 00c87b3417..48f7e4e82e 100644 --- a/Core/src/org/sleuthkit/autopsy/contentviewers/MessageContentViewer.java +++ b/Core/src/org/sleuthkit/autopsy/contentviewers/MessageContentViewer.java @@ -467,6 +467,7 @@ public class MessageContentViewer extends javax.swing.JPanel implements DataCont htmlPanel.reset(); textbodyTextArea.setText(""); msgbodyTabbedPane.setEnabled(false); + drp.setNode(null); } @Override @@ -561,7 +562,7 @@ public class MessageContentViewer extends javax.swing.JPanel implements DataCont msgbodyTabbedPane.setEnabledAt(ATTM_TAB_INDEX, numberOfAttachments > 0); msgbodyTabbedPane.setTitleAt(ATTM_TAB_INDEX, "Attachments (" + numberOfAttachments + ")"); drp.setNode(new TableFilterNode(new DataResultFilterNode(new AbstractNode( - new AttachmentsChildren(attachments)), null), true)); + new AttachmentsChildren(attachments))), true)); } private static String wrapInHtmlBody(String htmlText) { diff --git a/Core/src/org/sleuthkit/autopsy/directorytree/DataResultFilterNode.java b/Core/src/org/sleuthkit/autopsy/directorytree/DataResultFilterNode.java index c375c7f02b..d98e58fe70 100644 --- a/Core/src/org/sleuthkit/autopsy/directorytree/DataResultFilterNode.java +++ b/Core/src/org/sleuthkit/autopsy/directorytree/DataResultFilterNode.java @@ -126,7 +126,20 @@ public class DataResultFilterNode extends FilterNode { static private final DisplayableItemNodeVisitor> getActionsDIV = new GetPopupActionsDisplayableItemNodeVisitor(); private final DisplayableItemNodeVisitor getPreferredActionsDIV = new GetPreferredActionsDisplayableItemNodeVisitor(); + // Assumptions are made in GetPreferredActionsDisplayableItemNodeVisitor that + // sourceEm is the directory tree explorer manager. private final ExplorerManager sourceEm; + + /** + * Constructs a node used to wrap another node before passing it to the + * result viewers. The wrapper node defines the actions associated with the + * wrapped node and may filter out some of its children. + * + * @param node The node to wrap. + */ + public DataResultFilterNode(Node node) { + this(node, null); + } /** * Constructs a node used to wrap another node before passing it to the @@ -635,6 +648,9 @@ public class DataResultFilterNode extends FilterNode { // is a DirectoryTreeFilterNode that wraps the dataModelNode. We need // to set that wrapped node as the selection and root context of the // directory tree explorer manager (sourceEm) + if(sourceEm == null) { + return null; + } final Node currentSelectionInDirectoryTree = sourceEm.getSelectedNodes()[0]; return new AbstractAction() { @@ -675,6 +691,9 @@ public class DataResultFilterNode extends FilterNode { * @return */ private AbstractAction openParent(AbstractNode node) { + if(sourceEm == null) { + return null; + } // @@@ Why do we ignore node? Node[] selectedFilterNodes = sourceEm.getSelectedNodes(); Node selectedFilterNode = selectedFilterNodes[0];