Skip to content

Commit f64c12d

Browse files
committed
missing parent proxy set up for listeners
1 parent 3c1d52d commit f64c12d

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

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

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -4730,9 +4730,9 @@ public synchronized void addMouseListener(MouseListener l) {
47304730

47314731
// // if this is a lightweight component, enable mouse events
47324732
// // in the native container.
4733-
// if (peer instanceof LightweightPeer) {
4734-
// parent.proxyEnableEvents(AWTEvent.MOUSE_EVENT_MASK);
4735-
// }
4733+
if (peer instanceof LightweightPeer && parent != null) {
4734+
parent.proxyEnableEvents(AWTEvent.MOUSE_EVENT_MASK);
4735+
}
47364736
}
47374737

47384738
/**

0 commit comments

Comments
 (0)