mirror of
https://github.com/overcuriousity/autopsy-flatpak.git
synced 2025-07-12 16:06:15 +00:00
cleanup, comments
This commit is contained in:
parent
8c13846938
commit
4bc7a5dd30
@ -23,10 +23,10 @@
|
|||||||
<Layout>
|
<Layout>
|
||||||
<DimensionLayout dim="0">
|
<DimensionLayout dim="0">
|
||||||
<Group type="103" groupAlignment="0" attributes="0">
|
<Group type="103" groupAlignment="0" attributes="0">
|
||||||
<Group type="102" attributes="0">
|
<Group type="102" alignment="0" attributes="0">
|
||||||
<EmptySpace max="-2" attributes="0"/>
|
<EmptySpace max="-2" attributes="0"/>
|
||||||
<Group type="103" groupAlignment="0" attributes="0">
|
<Group type="103" groupAlignment="0" attributes="0">
|
||||||
<Group type="102" alignment="0" attributes="0">
|
<Group type="102" attributes="0">
|
||||||
<Group type="103" groupAlignment="0" attributes="0">
|
<Group type="103" groupAlignment="0" attributes="0">
|
||||||
<Group type="102" attributes="0">
|
<Group type="102" attributes="0">
|
||||||
<EmptySpace min="21" pref="21" max="-2" attributes="0"/>
|
<EmptySpace min="21" pref="21" max="-2" attributes="0"/>
|
||||||
@ -35,7 +35,7 @@
|
|||||||
<Group type="103" groupAlignment="0" max="-2" attributes="0">
|
<Group type="103" groupAlignment="0" max="-2" attributes="0">
|
||||||
<Component id="enabledByDefaultBox" min="-2" max="-2" attributes="0"/>
|
<Component id="enabledByDefaultBox" min="-2" max="-2" attributes="0"/>
|
||||||
<Component id="enabledForCaseBox" alignment="0" min="-2" max="-2" attributes="0"/>
|
<Component id="enabledForCaseBox" alignment="0" min="-2" max="-2" attributes="0"/>
|
||||||
<Component id="descriptionLabel" alignment="0" min="-2" max="-2" attributes="0"/>
|
<Component id="descriptionLabel" alignment="1" max="32767" attributes="0"/>
|
||||||
<Group type="102" alignment="0" attributes="0">
|
<Group type="102" alignment="0" attributes="0">
|
||||||
<EmptySpace min="21" pref="21" max="-2" attributes="0"/>
|
<EmptySpace min="21" pref="21" max="-2" attributes="0"/>
|
||||||
<Component id="infoIconLabel" min="-2" max="-2" attributes="0"/>
|
<Component id="infoIconLabel" min="-2" max="-2" attributes="0"/>
|
||||||
@ -45,10 +45,11 @@
|
|||||||
</Group>
|
</Group>
|
||||||
<Component id="groupCategorizationWarningBox" alignment="0" min="-2" max="-2" attributes="0"/>
|
<Component id="groupCategorizationWarningBox" alignment="0" min="-2" max="-2" attributes="0"/>
|
||||||
</Group>
|
</Group>
|
||||||
<EmptySpace pref="46" max="32767" attributes="0"/>
|
<EmptySpace min="0" pref="36" max="32767" attributes="0"/>
|
||||||
</Group>
|
</Group>
|
||||||
<Component id="jSeparator1" alignment="1" max="32767" attributes="0"/>
|
<Component id="jSeparator1" max="32767" attributes="0"/>
|
||||||
</Group>
|
</Group>
|
||||||
|
<EmptySpace max="-2" attributes="0"/>
|
||||||
</Group>
|
</Group>
|
||||||
</Group>
|
</Group>
|
||||||
</DimensionLayout>
|
</DimensionLayout>
|
||||||
@ -70,9 +71,9 @@
|
|||||||
</Group>
|
</Group>
|
||||||
<EmptySpace type="separate" max="-2" attributes="0"/>
|
<EmptySpace type="separate" max="-2" attributes="0"/>
|
||||||
<Component id="jSeparator1" min="-2" pref="10" max="-2" attributes="0"/>
|
<Component id="jSeparator1" min="-2" pref="10" max="-2" attributes="0"/>
|
||||||
<EmptySpace max="32767" attributes="0"/>
|
<EmptySpace type="unrelated" max="-2" attributes="0"/>
|
||||||
<Component id="groupCategorizationWarningBox" min="-2" max="-2" attributes="0"/>
|
<Component id="groupCategorizationWarningBox" min="-2" max="-2" attributes="0"/>
|
||||||
<EmptySpace max="-2" attributes="0"/>
|
<EmptySpace max="32767" attributes="0"/>
|
||||||
</Group>
|
</Group>
|
||||||
</Group>
|
</Group>
|
||||||
</DimensionLayout>
|
</DimensionLayout>
|
||||||
|
@ -1,7 +1,7 @@
|
|||||||
/*
|
/*
|
||||||
* Autopsy Forensic Browser
|
* Autopsy Forensic Browser
|
||||||
*
|
*
|
||||||
* Copyright 2013-15 Basis Technology Corp.
|
* Copyright 2013-16 Basis Technology Corp.
|
||||||
* Contact: carrier <at> sleuthkit <dot> org
|
* Contact: carrier <at> sleuthkit <dot> org
|
||||||
*
|
*
|
||||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||||
@ -23,11 +23,12 @@ import org.openide.util.NbBundle;
|
|||||||
import org.sleuthkit.autopsy.casemodule.Case;
|
import org.sleuthkit.autopsy.casemodule.Case;
|
||||||
import org.sleuthkit.autopsy.ingest.IngestManager;
|
import org.sleuthkit.autopsy.ingest.IngestManager;
|
||||||
|
|
||||||
/** The Image/Video Gallery panel in the NetBeans provided Options Dialogs
|
/**
|
||||||
|
* The Image/Video Gallery panel in the NetBeans provided Options Dialogs
|
||||||
* accessed via Tools -> Options
|
* accessed via Tools -> Options
|
||||||
*
|
*
|
||||||
* Uses {@link ImageGalleryPreferences} and {@link PerCaseProperties} to
|
* Uses {@link ImageGalleryPreferences} and {@link PerCaseProperties} to persist
|
||||||
* persist settings
|
* settings
|
||||||
*/
|
*/
|
||||||
final class ImageGalleryOptionsPanel extends javax.swing.JPanel {
|
final class ImageGalleryOptionsPanel extends javax.swing.JPanel {
|
||||||
|
|
||||||
@ -49,10 +50,10 @@ final class ImageGalleryOptionsPanel extends javax.swing.JPanel {
|
|||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
/** This method is called from within the constructor to
|
/**
|
||||||
* initialize the form.
|
* This method is called from within the constructor to initialize the form.
|
||||||
* WARNING: Do NOT modify this code. The content of this method is
|
* WARNING: Do NOT modify this code. The content of this method is always
|
||||||
* always regenerated by the Form Editor.
|
* regenerated by the Form Editor.
|
||||||
*/
|
*/
|
||||||
// <editor-fold defaultstate="collapsed" desc="Generated Code">//GEN-BEGIN:initComponents
|
// <editor-fold defaultstate="collapsed" desc="Generated Code">//GEN-BEGIN:initComponents
|
||||||
private void initComponents() {
|
private void initComponents() {
|
||||||
@ -127,15 +128,16 @@ final class ImageGalleryOptionsPanel extends javax.swing.JPanel {
|
|||||||
.addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING, false)
|
.addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING, false)
|
||||||
.addComponent(enabledByDefaultBox)
|
.addComponent(enabledByDefaultBox)
|
||||||
.addComponent(enabledForCaseBox)
|
.addComponent(enabledForCaseBox)
|
||||||
.addComponent(descriptionLabel, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
|
.addComponent(descriptionLabel, javax.swing.GroupLayout.Alignment.TRAILING)
|
||||||
.addGroup(layout.createSequentialGroup()
|
.addGroup(layout.createSequentialGroup()
|
||||||
.addGap(21, 21, 21)
|
.addGap(21, 21, 21)
|
||||||
.addComponent(infoIconLabel)
|
.addComponent(infoIconLabel)
|
||||||
.addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
|
.addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
|
||||||
.addComponent(furtherDescriptionArea, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)))
|
.addComponent(furtherDescriptionArea, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)))
|
||||||
.addComponent(groupCategorizationWarningBox))
|
.addComponent(groupCategorizationWarningBox))
|
||||||
.addContainerGap(46, Short.MAX_VALUE))
|
.addGap(0, 36, Short.MAX_VALUE))
|
||||||
.addComponent(jSeparator1, javax.swing.GroupLayout.Alignment.TRAILING)))
|
.addComponent(jSeparator1))
|
||||||
|
.addContainerGap())
|
||||||
);
|
);
|
||||||
layout.setVerticalGroup(
|
layout.setVerticalGroup(
|
||||||
layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
|
layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
|
||||||
@ -154,9 +156,9 @@ final class ImageGalleryOptionsPanel extends javax.swing.JPanel {
|
|||||||
.addComponent(furtherDescriptionArea, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE))
|
.addComponent(furtherDescriptionArea, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE))
|
||||||
.addGap(18, 18, 18)
|
.addGap(18, 18, 18)
|
||||||
.addComponent(jSeparator1, javax.swing.GroupLayout.PREFERRED_SIZE, 10, javax.swing.GroupLayout.PREFERRED_SIZE)
|
.addComponent(jSeparator1, javax.swing.GroupLayout.PREFERRED_SIZE, 10, javax.swing.GroupLayout.PREFERRED_SIZE)
|
||||||
.addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)
|
.addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.UNRELATED)
|
||||||
.addComponent(groupCategorizationWarningBox)
|
.addComponent(groupCategorizationWarningBox)
|
||||||
.addContainerGap())
|
.addContainerGap(javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE))
|
||||||
);
|
);
|
||||||
}// </editor-fold>//GEN-END:initComponents
|
}// </editor-fold>//GEN-END:initComponents
|
||||||
|
|
||||||
@ -172,7 +174,6 @@ final class ImageGalleryOptionsPanel extends javax.swing.JPanel {
|
|||||||
// TODO add your handling code here:
|
// TODO add your handling code here:
|
||||||
}//GEN-LAST:event_groupCategorizationWarningBoxActionPerformed
|
}//GEN-LAST:event_groupCategorizationWarningBoxActionPerformed
|
||||||
|
|
||||||
/** {@inheritDoc} */
|
|
||||||
void load() {
|
void load() {
|
||||||
enabledByDefaultBox.setSelected(ImageGalleryPreferences.isEnabledByDefault());
|
enabledByDefaultBox.setSelected(ImageGalleryPreferences.isEnabledByDefault());
|
||||||
if (Case.isCaseOpen() && IngestManager.getInstance().isIngestRunning() == false) {
|
if (Case.isCaseOpen() && IngestManager.getInstance().isIngestRunning() == false) {
|
||||||
@ -185,7 +186,6 @@ final class ImageGalleryOptionsPanel extends javax.swing.JPanel {
|
|||||||
groupCategorizationWarningBox.setSelected(ImageGalleryPreferences.isGroupCategorizationWarningDisabled());
|
groupCategorizationWarningBox.setSelected(ImageGalleryPreferences.isGroupCategorizationWarningDisabled());
|
||||||
}
|
}
|
||||||
|
|
||||||
/** {@inheritDoc } */
|
|
||||||
void store() {
|
void store() {
|
||||||
ImageGalleryPreferences.setEnabledByDefault(enabledByDefaultBox.isSelected());
|
ImageGalleryPreferences.setEnabledByDefault(enabledByDefaultBox.isSelected());
|
||||||
ImageGalleryController.getDefault().setListeningEnabled(enabledForCaseBox.isSelected());
|
ImageGalleryController.getDefault().setListeningEnabled(enabledForCaseBox.isSelected());
|
||||||
@ -195,9 +195,9 @@ final class ImageGalleryOptionsPanel extends javax.swing.JPanel {
|
|||||||
ImageGalleryPreferences.setGroupCategorizationWarningDisabled(groupCategorizationWarningBox.isSelected());
|
ImageGalleryPreferences.setGroupCategorizationWarningDisabled(groupCategorizationWarningBox.isSelected());
|
||||||
}
|
}
|
||||||
|
|
||||||
/** {@inheritDoc }
|
/**
|
||||||
*
|
* @return true, since there is no way for this form to be invalid
|
||||||
* @return true, since there is no way for this form to be invalid */
|
*/
|
||||||
boolean valid() {
|
boolean valid() {
|
||||||
// TODO check whether form is consistent and complete
|
// TODO check whether form is consistent and complete
|
||||||
return true;
|
return true;
|
||||||
|
@ -54,6 +54,12 @@ public class ImageGalleryPreferences {
|
|||||||
preferences.putBoolean(ENABLED_BY_DEFAULT, b);
|
preferences.putBoolean(ENABLED_BY_DEFAULT, b);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Return whether the warning about overwriting categories when acting on an
|
||||||
|
* entire group is disabled.
|
||||||
|
*
|
||||||
|
* @return true if the warning is disabled.
|
||||||
|
*/
|
||||||
public static boolean isGroupCategorizationWarningDisabled() {
|
public static boolean isGroupCategorizationWarningDisabled() {
|
||||||
final boolean aBoolean = preferences.getBoolean(GROUP_CATEGORIZATION_WARNING_DISABLED, false);
|
final boolean aBoolean = preferences.getBoolean(GROUP_CATEGORIZATION_WARNING_DISABLED, false);
|
||||||
return aBoolean;
|
return aBoolean;
|
||||||
|
@ -53,7 +53,7 @@ public class CategorizeGroupAction extends CategorizeAction {
|
|||||||
ObservableList<Long> fileIDs = controller.viewState().get().getGroup().getFileIDs();
|
ObservableList<Long> fileIDs = controller.viewState().get().getGroup().getFileIDs();
|
||||||
|
|
||||||
if (ImageGalleryPreferences.isGroupCategorizationWarningDisabled()) {
|
if (ImageGalleryPreferences.isGroupCategorizationWarningDisabled()) {
|
||||||
//if they have preveiously disabled the wrning, just go ahead and apply categories.
|
//if they have preveiously disabled the warning, just go ahead and apply categories.
|
||||||
addCatToFiles(ImmutableSet.copyOf(fileIDs));
|
addCatToFiles(ImmutableSet.copyOf(fileIDs));
|
||||||
} else {
|
} else {
|
||||||
final Map<Category, Long> catCountMap = new HashMap<>();
|
final Map<Category, Long> catCountMap = new HashMap<>();
|
||||||
|
Loading…
x
Reference in New Issue
Block a user