mirror of
https://github.com/NationalSecurityAgency/ghidra.git
synced 2025-10-04 10:19:23 +02:00
fixed excessive context changed calls by non visible windows
This commit is contained in:
parent
6ae0c1ce23
commit
13caf91a21
3 changed files with 13 additions and 0 deletions
|
@ -405,6 +405,11 @@ class DetachedWindowNode extends WindowNode {
|
|||
}
|
||||
}
|
||||
|
||||
@Override
|
||||
boolean isVisible() {
|
||||
return window != null && window.isVisible();
|
||||
}
|
||||
|
||||
void updateDialog() {
|
||||
|
||||
if (window != null && childComp != null) {
|
||||
|
|
|
@ -97,6 +97,11 @@ public class WindowActionManager {
|
|||
}
|
||||
|
||||
synchronized void contextChanged(ComponentPlaceholder placeHolder) {
|
||||
|
||||
if (!node.isVisible()) {
|
||||
return;
|
||||
}
|
||||
|
||||
placeHolderForScheduledActionUpdate = placeHolder;
|
||||
|
||||
// Buffer the events, as they tend to come in 3s. That might not sound like alot, but
|
||||
|
|
|
@ -38,6 +38,8 @@ public abstract class WindowNode extends Node {
|
|||
|
||||
abstract Container getContentPane();
|
||||
|
||||
abstract boolean isVisible();
|
||||
|
||||
void setToolBar(JComponent toolBar) {
|
||||
Container rootPane = getContentPane();
|
||||
if (rootPane == null) {
|
||||
|
@ -98,6 +100,7 @@ public abstract class WindowNode extends Node {
|
|||
contextTypes = null;
|
||||
}
|
||||
|
||||
@Override
|
||||
void dispose() {
|
||||
toolBarPanel = null;
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue