Skip to content

Commit 8886fb9

Browse files
hansonrhansonr
authored andcommitted
proper Component.isDisplayable()
1 parent 3625a35 commit 8886fb9

File tree

1 file changed

+5
-0
lines changed

1 file changed

+5
-0
lines changed

sources/net.sf.j2s.java.core/src/java/awt/JSComponent.java

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -251,6 +251,11 @@ public ComponentUI getUI() {
251251
return ui;
252252
}
253253

254+
@Override
255+
public boolean isDisplayable() {
256+
return getTopInvokableAncestor(this, false) != null;
257+
}
258+
254259
@Override
255260
protected void updatePeerVisibility(boolean isVisible) {
256261
// check for visibility set prior to creation of ui.

0 commit comments

Comments
 (0)