mirror of
https://github.com/overcuriousity/autopsy-flatpak.git
synced 2025-07-17 18:17:43 +00:00
Fixed NPE when adding local disk
This commit is contained in:
parent
2ee7108b10
commit
f11fe15926
@ -419,12 +419,14 @@ final class LocalDiskPanel extends JPanel {
|
|||||||
label.setForeground(list.getForeground());
|
label.setForeground(list.getForeground());
|
||||||
}
|
}
|
||||||
|
|
||||||
String localDiskString = value.toString();
|
if (value != null) {
|
||||||
label.setText(value.toString());
|
String localDiskString = value.toString();
|
||||||
if ((localDiskString.equals(LOADING)) || (localDiskString.equals(NO_DRIVES))) {
|
label.setText(value.toString());
|
||||||
label.setFont(label.getFont().deriveFont(Font.ITALIC));
|
if ((localDiskString.equals(LOADING)) || (localDiskString.equals(NO_DRIVES))) {
|
||||||
label.setBackground(Color.GRAY);
|
label.setFont(label.getFont().deriveFont(Font.ITALIC));
|
||||||
}
|
label.setBackground(Color.GRAY);
|
||||||
|
}
|
||||||
|
}
|
||||||
label.setOpaque(true);
|
label.setOpaque(true);
|
||||||
label.setBorder(new EmptyBorder(2, 2, 2, 2));
|
label.setBorder(new EmptyBorder(2, 2, 2, 2));
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user