mirror of
https://github.com/NationalSecurityAgency/ghidra.git
synced 2025-10-04 02:09:44 +02:00
Updated the help window to not preserve the previous location on a new
request for the same page
This commit is contained in:
parent
73d29e3488
commit
ef7c79f0c0
4 changed files with 23 additions and 14 deletions
|
@ -142,7 +142,7 @@ public class DockingHelpBroker extends GHelpBroker {
|
|||
|
||||
@Override
|
||||
public void actionPerformed(ActionEvent e) {
|
||||
reloadHelpPage(getCurrentURL());
|
||||
reloadHelpPage(getCurrentURL(), true);
|
||||
}
|
||||
};
|
||||
toolbar.add(new JButton(refreshAction));
|
||||
|
@ -150,8 +150,8 @@ public class DockingHelpBroker extends GHelpBroker {
|
|||
}
|
||||
|
||||
@Override // opened access
|
||||
protected void reloadHelpPage(URL url) {
|
||||
super.reloadHelpPage(url);
|
||||
protected void reloadHelpPage(URL url, boolean preserveLocation) {
|
||||
super.reloadHelpPage(url, preserveLocation);
|
||||
}
|
||||
|
||||
//=================================================================================================
|
||||
|
|
|
@ -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.
|
||||
|
@ -462,7 +462,7 @@ public class HelpManager implements HelpService {
|
|||
// an invokeLater() will work as long as the model loading is
|
||||
// relatively quick.
|
||||
//
|
||||
SystemUtilities.runSwingLater(() -> displayHelp(help, owner));
|
||||
Swing.runLater(() -> displayHelp(help, owner));
|
||||
return;
|
||||
}
|
||||
|
||||
|
@ -596,7 +596,10 @@ public class HelpManager implements HelpService {
|
|||
return;
|
||||
}
|
||||
|
||||
((DockingHelpBroker) mainHB).reloadHelpPage(validateUrl(helpURL));
|
||||
// Let the URL dictate where the page scrolls to. If we do not do this, then there is an
|
||||
// odd effect of having the page load and then jump to a previous location.
|
||||
boolean preserveLocation = false;
|
||||
((DockingHelpBroker) mainHB).reloadHelpPage(validateUrl(helpURL), preserveLocation);
|
||||
}
|
||||
|
||||
private URL getURLForID(ID ID) {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue