diff --git a/Core/src/org/sleuthkit/autopsy/corecomponents/Bundle.properties b/Core/src/org/sleuthkit/autopsy/corecomponents/Bundle.properties index a595cbc1e56449ed78f673b8749e3ae70bf986a6..be35962d762d48cf6ed1c9a97bd1a1454c691d3d 100644 --- a/Core/src/org/sleuthkit/autopsy/corecomponents/Bundle.properties +++ b/Core/src/org/sleuthkit/autopsy/corecomponents/Bundle.properties @@ -27,6 +27,8 @@ Format_OperatingSystem_Value={0} version {1} running on {2} LBL_Copyright=<div style\="font-size\: 12pt; font-family\: Verdana, 'Verdana CE', Arial, 'Arial CE', 'Lucida Grande CE', lucida, 'Helvetica CE', sans-serif; ">Autopsy™ is a digital forensics platform based on The Sleuth Kit™ and other tools. <br><ul><li>General Information: <a style\="color\: \#1E2A60;" href\="http\://www.sleuthkit.org">http\://www.sleuthkit.org</a>.</li><li>Training: <a style\="color\: \#1E2A60;" href\="http://www.basistech.com/autopsy-training">http://www.basistech.com/autopsy-training</a></li><li>Commercial Support: <a style\="color\: \#1E2A60;" href\="http://www.basistech.com/digital-forensics/autopsy/support/">http://www.basistech.com/digital-forensics/autopsy/support/</a></li></ul>Copyright © 2003-2014. </div> URL_ON_IMG=http://www.sleuthkit.org/ +URL_ON_HELP=http://sleuthkit.org/autopsy/docs/user-docs/3.1/ + LBL_Close=Close DataContentViewerString.copyMenuItem.text=Copy DataContentViewerHex.copyMenuItem.text=Copy diff --git a/Core/src/org/sleuthkit/autopsy/corecomponents/OnlineHelpAction.java b/Core/src/org/sleuthkit/autopsy/corecomponents/OnlineHelpAction.java new file mode 100755 index 0000000000000000000000000000000000000000..b9cfcf4c65bfe16d485cb0087e68cf4154ad34c0 --- /dev/null +++ b/Core/src/org/sleuthkit/autopsy/corecomponents/OnlineHelpAction.java @@ -0,0 +1,72 @@ +/* + * Autopsy Forensic Browser + * + * Copyright 2011-2014 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.corecomponents; + +import java.awt.event.ActionEvent; +import java.awt.event.ActionListener; +import java.net.MalformedURLException; +import java.net.URL; +import org.netbeans.core.actions.HTMLViewAction; +import org.openide.awt.ActionID; +import org.openide.awt.ActionReference; +import org.openide.awt.ActionReferences; +import org.openide.awt.ActionRegistration; +import org.openide.awt.HtmlBrowser; +import org.openide.util.NbBundle; +import org.openide.util.NbBundle.Messages; + +import java.util.logging.Level; +import java.util.logging.Logger; +@ActionID( + category = "Help", + id = "org.sleuthkit.autopsy.corecomponents.OnlineHelpAction" +) +@ActionRegistration( + displayName = "#CTL_OnlineHelpAction" +) +@ActionReferences({ + @ActionReference(path = "Menu/Help", position = 0), + @ActionReference(path = "Shortcuts", name = "F1") +}) +@Messages("CTL_OnlineHelpAction=Online Documentation") +public final class OnlineHelpAction implements ActionListener { + + private URL url; + private static final Logger Logger = org.sleuthkit.autopsy.coreutils.Logger.getLogger(AboutWindowPanel.class.getName()); + + @Override + public void actionPerformed(ActionEvent e) { + // TODO implement action body + try { + url = new URL(NbBundle.getMessage(OnlineHelpAction.class, "URL_ON_HELP")); // NOI18N + showUrl(); + } catch (MalformedURLException ex) { + Logger.log(Level.SEVERE, "Unable to load Online DOcumentation", ex); + } + url = null; + } + + private void showUrl() { + if (url != null) { + org.openide.awt.StatusDisplayer.getDefault().setStatusText(NbBundle.getMessage(HTMLViewAction.class, "CTL_OpeningBrowser")); //NON-NLS + HtmlBrowser.URLDisplayer.getDefault().showURL(url); + } + } + +}