mirror of
https://github.com/NationalSecurityAgency/ghidra.git
synced 2025-10-06 03:50:02 +02:00
GT-3179 - Help - addressed missing help for tool options; fixed bug that
caused help find dialog to be stuck behind Tool Options dialog; fixed bug that caused the Help Find Dialog keybinding to trigger an exception
This commit is contained in:
parent
ea953ce924
commit
66198876e5
28 changed files with 296 additions and 151 deletions
|
@ -26,8 +26,10 @@ import javax.swing.KeyStroke;
|
|||
import javax.swing.SwingUtilities;
|
||||
|
||||
import ghidra.util.HelpLocation;
|
||||
import ghidra.util.Msg;
|
||||
import ghidra.util.datastruct.WeakDataStructureFactory;
|
||||
import ghidra.util.datastruct.WeakSet;
|
||||
import utilities.util.reflection.ReflectionUtilities;
|
||||
|
||||
public abstract class AbstractOptions implements Options {
|
||||
public static final Set<Class<?>> SUPPORTED_CLASSES = buildSupportedClassSet();
|
||||
|
@ -136,6 +138,10 @@ public abstract class AbstractOptions implements Options {
|
|||
throw new IllegalStateException(
|
||||
"Can't register a custom option without a property editor");
|
||||
}
|
||||
if (description == null) {
|
||||
Msg.error(this, "Registered an option without a description: " + optionName,
|
||||
ReflectionUtilities.createJavaFilteredThrowable());
|
||||
}
|
||||
|
||||
Option currentOption = valueMap.get(optionName);
|
||||
if (currentOption == null) {
|
||||
|
|
|
@ -116,6 +116,9 @@ public class ToolOptions extends AbstractOptions {
|
|||
* Return an XML element for the option names and values.
|
||||
* Note: only those options which have been explicitly set
|
||||
* will be included.
|
||||
*
|
||||
* @param includeDefaultBindings true to include default key binding values in the xml
|
||||
* @return the xml root element
|
||||
*/
|
||||
public Element getXmlRoot(boolean includeDefaultBindings) {
|
||||
SaveState saveState = new SaveState(XML_ELEMENT_NAME);
|
||||
|
@ -268,7 +271,7 @@ public class ToolOptions extends AbstractOptions {
|
|||
|
||||
/**
|
||||
* Adds all the options name/value pairs to this Options.
|
||||
* @param newOptions
|
||||
* @param newOptions the new options into which the current options values will be placed
|
||||
*/
|
||||
public void copyOptions(Options newOptions) {
|
||||
List<String> optionNames = newOptions.getOptionNames();
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue