change source level to 1.8; use more generic method to look up branded resources in AboutWindowPanel

This commit is contained in:
jmillman
2014-08-26 16:09:14 -04:00
parent ea4307367f
commit e059d5dfa1
5 changed files with 27 additions and 24 deletions
+1 -1
View File
@@ -8,7 +8,7 @@ file.reference.sqlite-jdbc-3.7.15-M1.jar=release/modules/ext/sqlite-jdbc-3.7.15-
file.reference.tika-core-1.2.jar=release/modules/ext/tika-core-1.2.jar
file.reference.Tsk_DataModel.jar=release/modules/ext/Tsk_DataModel.jar
file.reference.xmpcore.jar=release/modules/ext/xmpcore.jar
javac.source=1.7
javac.source=1.8
javac.compilerargs=-Xlint -Xlint:-serial
license.file=../LICENSE-2.0.txt
nbm.homepage=http://www.sleuthkit.org/
-9
View File
@@ -24,15 +24,6 @@
<implementation-version/>
</run-dependency>
</dependency>
<dependency>
<code-name-base>org.netbeans.core.startup</code-name-base>
<build-prerequisite/>
<compile-dependency/>
<run-dependency>
<release-version>1</release-version>
<implementation-version/>
</run-dependency>
</dependency>
<dependency>
<code-name-base>org.netbeans.modules.javahelp</code-name-base>
<build-prerequisite/>
@@ -25,6 +25,8 @@ import java.net.MalformedURLException;
import java.net.URL;
import java.text.MessageFormat;
import java.util.Locale;
import java.util.logging.Level;
import java.util.logging.Logger;
import javax.swing.Icon;
import javax.swing.ImageIcon;
import javax.swing.JPanel;
@@ -42,19 +44,27 @@ import org.sleuthkit.datamodel.SleuthkitJNI;
/**
* Custom "About" window panel.
*/
public class AboutWindowPanel extends JPanel implements HyperlinkListener {
public final class AboutWindowPanel extends JPanel implements HyperlinkListener {
private static final Logger Logger = org.sleuthkit.autopsy.coreutils.Logger.getLogger(AboutWindowPanel.class.getName());
private URL url = null;
private Icon about;
private boolean verboseLogging;
public AboutWindowPanel() {
about = new ImageIcon(org.netbeans.core.startup.Splash.loadContent(true));
try {
about = new ImageIcon(new URL("nbdocs:/org/netbeans/core/startup/splash.gif"));
} catch (MalformedURLException ex) {
Logger.log(Level.INFO, "failed to load aout window image", ex);
}
initComponents();
logoLabel.setCursor(Cursor.getPredefinedCursor(Cursor.HAND_CURSOR));
description.setText(org.openide.util.NbBundle.getMessage(AboutWindowPanel.class,
"LBL_Description", new Object[]{getProductVersionValue(), getJavaValue(), getVMValue(),
getOperatingSystemValue(), getEncodingValue(), getSystemLocaleValue(), getUserDirValue(), getSleuthKitVersionValue(), Version.getNetbeansBuild(), Version.getBuildType().toString()}));
"LBL_Description", new Object[]{getProductVersionValue(), getJavaValue(), getVMValue(),
getOperatingSystemValue(), getEncodingValue(), getSystemLocaleValue(), getUserDirValue(), getSleuthKitVersionValue(), Version.getNetbeansBuild(), Version.getBuildType().toString()}));
description.addHyperlinkListener(this);
copyright.addHyperlinkListener(this);
copyright.setBackground(getBackground());
@@ -64,6 +74,7 @@ public class AboutWindowPanel extends JPanel implements HyperlinkListener {
}
// <editor-fold defaultstate="collapsed" desc="Generated Code">//GEN-BEGIN:initComponents
private void initComponents() {
@@ -256,11 +267,11 @@ private void logoLabelMouseClicked(java.awt.event.MouseEvent evt) {//GEN-FIRST:e
return System.getProperty("file.encoding", //NON-NLS
NbBundle.getMessage(AboutWindowPanel.class, "ProductInformationPanel.propertyUnknown.text"));
}
public void setCopyright(String text) {
copyright.setText(text);
}
@Override
public void hyperlinkUpdate(HyperlinkEvent event) {
if (HyperlinkEvent.EventType.ENTERED == event.getEventType()) {
@@ -269,19 +280,20 @@ private void logoLabelMouseClicked(java.awt.event.MouseEvent evt) {//GEN-FIRST:e
url = null;
}
}
/**
* Activate verbose logging for Sleuth Kit
*/
public void startVerboseLogging() {
verboseLogging = true;
String logPath = PlatformUtil.getUserDirectory() + File.separator + "sleuthkit.txt"; //NON-NLS
SleuthkitJNI.startVerboseLogging(logPath);
}
/**
* Checks if verbose logging has been enabled.
*
* @return true if verbose logging has been enabled.
*/
public boolean verboseLoggingIsSet() {
@@ -1,5 +1,5 @@
#Updated by build script
#Mon, 28 Apr 2014 01:45:18 -0400
#Tue, 26 Aug 2014 12:28:29 -0400
LBL_splash_window_title=Starting Autopsy
SPLASH_HEIGHT=288
SPLASH_WIDTH=538
@@ -8,4 +8,4 @@ SplashRunningTextBounds=5,266,530,17
SplashRunningTextColor=0x0
SplashRunningTextFontSize=18
currentVersion=Autopsy 3.1.0_Beta
currentVersion=Autopsy 3.1.0
@@ -1,5 +1,5 @@
#Updated by build script
#Mon, 28 Apr 2014 01:45:18 -0400
#Tue, 26 Aug 2014 12:28:29 -0400
CTL_MainWindow_Title=Autopsy 3.1.0_Beta
CTL_MainWindow_Title_No_Project=Autopsy 3.1.0_Beta
CTL_MainWindow_Title=Autopsy 3.1.0
CTL_MainWindow_Title_No_Project=Autopsy 3.1.0