Ghidra is a software reverse engineering (SRE) framework
Minor help tweaks
dragonmacher1442ed87b9bc
diff --git a/Ghidra/Framework/Docking/src/main/java/docking/action/AbstractHelpAction.java b/Ghidra/Framework/Docking/src/main/java/docking/action/AbstractHelpAction.javaindex 9d617a83d2..6a6fa79a6e 100644--- a/Ghidra/Framework/Docking/src/main/java/docking/action/AbstractHelpAction.java+++ b/Ghidra/Framework/Docking/src/main/java/docking/action/AbstractHelpAction.java@@ -4,9 +4,9 @@* 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.@@ -22,6 +22,7 @@ import javax.swing.KeyStroke;import docking.*;import ghidra.util.HelpLocation;import ghidra.util.SystemUtilities;+import help.HelpDescriptor;import help.HelpService;/**@@ -56,6 +57,7 @@ public abstract class AbstractHelpAction extends DockingAction {@Overridepublic void actionPerformed(ActionContext context) {+DockingActionIf mouseOverAction = DockingWindowManager.getMouseOverAction();if (mouseOverAction != null) {showHelp(mouseOverAction);@@ -126,7 +128,12 @@ public abstract class AbstractHelpAction extends DockingAction {return startingHelpObject;}- // Second, with no help registered for the starting component, start looking for a suitable+ // Second, see if we are showing help info and this object knows how to do that+ if (isInfo() && startingHelpObject instanceof HelpDescriptor) {+ return startingHelpObject;+ }++ // Finally, with no help registered for the starting component, start looking for a suitable// help proxy.//// For Components, we can walk their containment hierarchy to find a potential help objectdiff --git a/Ghidra/Framework/Docking/src/main/java/docking/help/HelpManager.java b/Ghidra/Framework/Docking/src/main/java/docking/help/HelpManager.javaindex 2241ae2b8b..d4ffc93dc3 100644--- a/Ghidra/Framework/Docking/src/main/java/docking/help/HelpManager.java+++ b/Ghidra/Framework/Docking/src/main/java/docking/help/HelpManager.java@@ -18,8 +18,7 @@ package docking.help;import java.awt.*;import java.io.IOException;import java.io.InputStream;-import java.net.MalformedURLException;-import java.net.URL;+import java.net.*;import java.util.*;import java.util.List;import java.util.Map;@@ -358,9 +357,9 @@ public class HelpManager implements HelpService {// To do this, try making a URL out of the help string and doing a reverse lookupURL URL = null;try {- URL = new URL(helpIDString);+ URL = URI.create(helpIDString).toURL();}- catch (MalformedURLException e) {+ catch (IllegalArgumentException | MalformedURLException e) {// nothing we can do, fall through the method to the previous exception}