diff --git a/Core/src/org/sleuthkit/autopsy/casemodule/Case.java b/Core/src/org/sleuthkit/autopsy/casemodule/Case.java index af9b1f214e..fb040ff279 100644 --- a/Core/src/org/sleuthkit/autopsy/casemodule/Case.java +++ b/Core/src/org/sleuthkit/autopsy/casemodule/Case.java @@ -201,7 +201,7 @@ public class Case { * @param caseNumber the case number * @param examiner the examiner for this case */ - static void create(String caseDir, String caseName, String caseNumber, String examiner) throws CaseActionException { + public static void create(String caseDir, String caseName, String caseNumber, String examiner) throws CaseActionException { logger.log(Level.INFO, "Creating new case.\ncaseDir: {0}\ncaseName: {1}", new Object[]{caseDir, caseName}); String configFilePath = caseDir + File.separator + caseName + CASE_DOT_EXTENSION; @@ -220,7 +220,7 @@ public class Case { } Case newCase = new Case(caseName, caseNumber, examiner, configFilePath, xmlcm, db); - + changeCase(newCase); } @@ -254,7 +254,7 @@ public class Case { checkImagesExist(db); Case openedCase = new Case(caseName, caseNumber, examiner, configFilePath, xmlcm, db); - + changeCase(openedCase); } catch (Exception ex) { @@ -903,8 +903,6 @@ public class Case { } else { // close all top components CoreComponentControl.closeCoreWindows(); - // prompt user to add an image - Case.runAddImageAction(); } } else { // case is closed // close all top components first diff --git a/Core/src/org/sleuthkit/autopsy/casemodule/NewCaseWizardAction.java b/Core/src/org/sleuthkit/autopsy/casemodule/NewCaseWizardAction.java index 9468e39615..412400ba21 100644 --- a/Core/src/org/sleuthkit/autopsy/casemodule/NewCaseWizardAction.java +++ b/Core/src/org/sleuthkit/autopsy/casemodule/NewCaseWizardAction.java @@ -21,6 +21,7 @@ package org.sleuthkit.autopsy.casemodule; import java.awt.Component; import java.awt.Dialog; +import java.awt.event.ActionListener; import java.io.File; import java.text.MessageFormat; import java.util.logging.Level; @@ -87,7 +88,9 @@ public final class NewCaseWizardAction extends CallableSystemAction { // if the finish button is pressed (not cancelled) if (finished) { - // nothing to do, the Add Image dialog will pop up on its own because we've just opened a case with no images + // now start the 'Add Image' wizard + AddImageAction addImageAction = SystemAction.get(AddImageAction.class); + addImageAction.actionPerformed(null); } // if Cancel button is pressed diff --git a/Core/src/org/sleuthkit/autopsy/corecomponents/MediaViewVideoPanel.java b/Core/src/org/sleuthkit/autopsy/corecomponents/MediaViewVideoPanel.java index 0c48925985..da1ca268d5 100644 --- a/Core/src/org/sleuthkit/autopsy/corecomponents/MediaViewVideoPanel.java +++ b/Core/src/org/sleuthkit/autopsy/corecomponents/MediaViewVideoPanel.java @@ -72,7 +72,7 @@ public class MediaViewVideoPanel extends javax.swing.JPanel implements FrameCapt private static final Logger logger = Logger.getLogger(MediaViewVideoPanel.class.getName()); private boolean gstInited; private static final long MIN_FRAME_INTERVAL_MILLIS = 500; - private static final long FRAME_CAPTURE_TIMEOUT_MILLIS = 100; + private static final long FRAME_CAPTURE_TIMEOUT_MILLIS = 1000; private static final String MEDIA_PLAYER_ERROR_STRING = "The media player cannot process this file."; //playback private long durationMillis = 0; @@ -384,7 +384,7 @@ public class MediaViewVideoPanel extends javax.swing.JPanel implements FrameCapt try { lock.wait(FRAME_CAPTURE_TIMEOUT_MILLIS); } catch (InterruptedException e) { - logger.log(Level.INFO, "Timeout occurred while waiting for frame capture.", e); + logger.log(Level.INFO, "InterruptedException occurred while waiting for frame capture.", e); } } Image image = rgbListener.getImage(); @@ -419,17 +419,19 @@ public class MediaViewVideoPanel extends javax.swing.JPanel implements FrameCapt @Override public void rgbFrame(boolean bln, int w, int h, IntBuffer rgbPixels) { - bi = new BufferedImage(w, h, BufferedImage.TYPE_INT_ARGB); - bi.setRGB(0, 0, w, h, rgbPixels.array(), 0, w); - synchronized(waiter) { + synchronized (waiter) { + bi = new BufferedImage(w, h, BufferedImage.TYPE_INT_ARGB); + bi.setRGB(0, 0, w, h, rgbPixels.array(), 0, w); waiter.notify(); } } public Image getImage() { - Image image = bi; - bi = null; - return image; + synchronized (waiter) { + Image image = bi; + bi = null; + return image; + } } } diff --git a/Core/src/org/sleuthkit/autopsy/ingest/IngestManager.java b/Core/src/org/sleuthkit/autopsy/ingest/IngestManager.java index 3c2e5f3fe3..3ed4d1a94f 100644 --- a/Core/src/org/sleuthkit/autopsy/ingest/IngestManager.java +++ b/Core/src/org/sleuthkit/autopsy/ingest/IngestManager.java @@ -229,7 +229,7 @@ public class IngestManager { * @param modules modules to execute on every image * @param images images to execute modules on */ - void execute(final List modules, final List images) { + public void execute(final List modules, final List images) { logger.log(Level.INFO, "Will enqueue number of images: " + images.size() + " to " + modules.size() + " modules."); if (!isIngestRunning() && ui != null) { @@ -256,7 +256,7 @@ public class IngestManager { * @param modules modules to execute on the image * @param image image to execute modules on */ - void execute(final List modules, final Image image) { + public void execute(final List modules, final Image image) { List images = new ArrayList(); images.add(image); logger.log(Level.INFO, "Will enqueue image: " + image.getName());