mirror of
https://github.com/overcuriousity/autopsy-flatpak.git
synced 2025-07-08 06:09:32 +00:00
66 lines
2.0 KiB
Java
66 lines
2.0 KiB
Java
/*
|
|
* Autopsy Forensic Browser
|
|
*
|
|
* Copyright 2011 Basis Technology Corp.
|
|
* Contact: carrier <at> sleuthkit <dot> org
|
|
*
|
|
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
* you may not use this file except in compliance with the License.
|
|
* You may obtain a copy of the License at
|
|
*
|
|
* http://www.apache.org/licenses/LICENSE-2.0
|
|
*
|
|
* Unless required by applicable law or agreed to in writing, software
|
|
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
* See the License for the specific language governing permissions and
|
|
* limitations under the License.
|
|
*/
|
|
package org.sleuthkit.autopsy.hashdatabase;
|
|
|
|
import java.awt.event.ActionEvent;
|
|
import java.awt.event.ActionListener;
|
|
import org.openide.util.HelpCtx;
|
|
import org.openide.util.actions.CallableSystemAction;
|
|
import org.sleuthkit.autopsy.corecomponents.AdvancedConfigurationDialog;
|
|
import org.sleuthkit.autopsy.coreutils.Log;
|
|
|
|
/**
|
|
* The HashDbMgmtAction opens the HashDbMgmtPanel in a dialog, and saves the
|
|
* settings of the panel if the Apply button is clicked.
|
|
* @author pmartel
|
|
*/
|
|
class HashDbMgmtAction extends CallableSystemAction {
|
|
|
|
static final String ACTION_NAME = "Hash Database Configuration";
|
|
|
|
@Override
|
|
public void performAction() {
|
|
final HashDbManagementPanel panel = HashDbManagementPanel.getDefault();
|
|
final AdvancedConfigurationDialog dialog = new AdvancedConfigurationDialog();
|
|
dialog.addApplyButtonListener(new ActionListener() {
|
|
|
|
@Override
|
|
public void actionPerformed(ActionEvent e) {
|
|
dialog.close();
|
|
}
|
|
});
|
|
dialog.display(panel);
|
|
}
|
|
|
|
@Override
|
|
public String getName() {
|
|
return ACTION_NAME;
|
|
}
|
|
|
|
@Override
|
|
public HelpCtx getHelpCtx() {
|
|
return HelpCtx.DEFAULT_HELP;
|
|
}
|
|
|
|
@Override
|
|
protected boolean asynchronous() {
|
|
return false;
|
|
}
|
|
}
|