19 package org.sleuthkit.autopsy.directorytree;
21 import java.awt.event.ActionListener;
26 @SuppressWarnings(
"PMD.SingularField")
27 class ImageDetailsPanel extends javax.swing.JPanel {
41 @SuppressWarnings(
"unchecked")
43 private
void initComponents() {
45 imageInfoLabel =
new javax.swing.JLabel();
46 imgNameLabel =
new javax.swing.JLabel();
47 imgTypeLabel =
new javax.swing.JLabel();
48 imgSectorSizeLabel =
new javax.swing.JLabel();
49 imgNameValue =
new javax.swing.JLabel();
50 imgTypeValue =
new javax.swing.JLabel();
51 imgSectorSizeValue =
new javax.swing.JLabel();
52 OKButton =
new javax.swing.JButton();
53 imgTotalSizeLabel =
new javax.swing.JLabel();
54 imgTotalSizeValue =
new javax.swing.JLabel();
55 imgHashLabel =
new javax.swing.JLabel();
56 imgHashValue =
new javax.swing.JLabel();
58 imageInfoLabel.setFont(imageInfoLabel.getFont().deriveFont(imageInfoLabel.getFont().getStyle() | java.awt.Font.BOLD, imageInfoLabel.getFont().getSize()+7));
59 imageInfoLabel.setText(
org.openide.util.NbBundle.getMessage(ImageDetailsPanel.class,
"ImageDetailsPanel.imageInfoLabel.text"));
61 imgNameLabel.setText(
org.openide.util.NbBundle.getMessage(ImageDetailsPanel.class,
"ImageDetailsPanel.imgNameLabel.text"));
63 imgTypeLabel.setText(
org.openide.util.NbBundle.getMessage(ImageDetailsPanel.class,
"ImageDetailsPanel.imgTypeLabel.text"));
65 imgSectorSizeLabel.setText(
org.openide.util.NbBundle.getMessage(ImageDetailsPanel.class,
"ImageDetailsPanel.imgSectorSizeLabel.text"));
67 imgNameValue.setText(
org.openide.util.NbBundle.getMessage(ImageDetailsPanel.class,
"ImageDetailsPanel.imgNameValue.text"));
69 imgTypeValue.setText(
org.openide.util.NbBundle.getMessage(ImageDetailsPanel.class,
"ImageDetailsPanel.imgTypeValue.text"));
71 imgSectorSizeValue.setText(
org.openide.util.NbBundle.getMessage(ImageDetailsPanel.class,
"ImageDetailsPanel.imgSectorSizeValue.text"));
73 OKButton.setText(
org.openide.util.NbBundle.getMessage(ImageDetailsPanel.class,
"ImageDetailsPanel.OKButton.text"));
75 imgTotalSizeLabel.setText(
org.openide.util.NbBundle.getMessage(ImageDetailsPanel.class,
"ImageDetailsPanel.imgTotalSizeLabel.text"));
77 imgTotalSizeValue.setText(
org.openide.util.NbBundle.getMessage(ImageDetailsPanel.class,
"ImageDetailsPanel.imgTotalSizeValue.text"));
79 imgHashLabel.setText(
org.openide.util.NbBundle.getMessage(ImageDetailsPanel.class,
"ImageDetailsPanel.imgHashLabel.text"));
81 imgHashValue.setText(
org.openide.util.NbBundle.getMessage(ImageDetailsPanel.class,
"ImageDetailsPanel.imgHashValue.text"));
83 javax.swing.GroupLayout layout =
new javax.swing.GroupLayout(
this);
84 this.setLayout(layout);
85 layout.setHorizontalGroup(
86 layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
87 .addGroup(layout.createSequentialGroup()
88 .addGap(0, 68, Short.MAX_VALUE)
89 .addComponent(imageInfoLabel)
90 .addContainerGap(78, Short.MAX_VALUE))
91 .addGroup(javax.swing.GroupLayout.Alignment.TRAILING, layout.createSequentialGroup()
92 .addContainerGap(javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)
93 .addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
94 .addGroup(layout.createSequentialGroup()
95 .addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
96 .addComponent(imgNameLabel)
97 .addComponent(imgTypeLabel)
98 .addComponent(imgSectorSizeLabel)
99 .addComponent(imgTotalSizeLabel)
100 .addComponent(imgHashLabel))
102 .addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
103 .addComponent(imgNameValue)
104 .addComponent(imgTypeValue)
105 .addComponent(imgSectorSizeValue)
106 .addComponent(imgTotalSizeValue)
107 .addComponent(imgHashValue)))
108 .addComponent(OKButton))
109 .addContainerGap(javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE))
111 layout.setVerticalGroup(
112 layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
113 .addGroup(layout.createSequentialGroup()
115 .addComponent(imageInfoLabel)
117 .addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.TRAILING)
118 .addGroup(layout.createSequentialGroup()
119 .addComponent(imgNameValue)
120 .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.UNRELATED)
121 .addComponent(imgTypeValue)
122 .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.UNRELATED)
123 .addComponent(imgSectorSizeValue)
124 .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.UNRELATED)
125 .addComponent(imgTotalSizeValue)
126 .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.UNRELATED)
127 .addComponent(imgHashValue))
128 .addGroup(layout.createSequentialGroup()
129 .addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.TRAILING)
130 .addGroup(layout.createSequentialGroup()
131 .addComponent(imgNameLabel)
132 .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.UNRELATED)
133 .addComponent(imgTypeLabel)
135 .addComponent(imgSectorSizeLabel))
136 .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.UNRELATED)
137 .addComponent(imgTotalSizeLabel)
138 .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.UNRELATED)
139 .addComponent(imgHashLabel)))
140 .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED, 64, Short.MAX_VALUE)
141 .addComponent(OKButton)
147 private javax.swing.JButton OKButton;
148 private javax.swing.JLabel imageInfoLabel;
149 private javax.swing.JLabel imgHashLabel;
150 private javax.swing.JLabel imgHashValue;
151 private javax.swing.JLabel imgNameLabel;
152 private javax.swing.JLabel imgNameValue;
153 private javax.swing.JLabel imgSectorSizeLabel;
154 private javax.swing.JLabel imgSectorSizeValue;
155 private javax.swing.JLabel imgTotalSizeLabel;
156 private javax.swing.JLabel imgTotalSizeValue;
157 private javax.swing.JLabel imgTypeLabel;
158 private javax.swing.JLabel imgTypeValue;
166 public void setImgNameValue(String arg) {
167 imgNameValue.setText(arg);
175 public void setImgTypeValue(String arg) {
176 imgTypeValue.setText(arg);
184 public void setImgSectorSizeValue(String arg) {
185 imgSectorSizeValue.setText(arg);
193 public void setImgTotalSizeValue(String arg) {
194 imgTotalSizeValue.setText(arg);
202 public void setImgHashValue(String arg) {
203 imgHashValue.setText(arg);
206 public void setVisibleHashInfo(
boolean visible) {
207 imgHashLabel.setVisible(visible);
208 imgHashValue.setVisible(visible);
216 public void setOKButtonActionListener(ActionListener e) {
217 OKButton.addActionListener(e);