From 8bb250e94b9f98e05a1ea472d110d487ae31c02e Mon Sep 17 00:00:00 2001 From: Zbynek Konecny Date: Fri, 30 Jun 2023 10:34:58 +0200 Subject: [PATCH] Reset source after event handling --- .../src/main/java/org/gwtproject/event/dom/client/DomEvent.java | 2 ++ 1 file changed, 2 insertions(+) diff --git a/gwt-event-dom/src/main/java/org/gwtproject/event/dom/client/DomEvent.java b/gwt-event-dom/src/main/java/org/gwtproject/event/dom/client/DomEvent.java index 1bed384..79fa286 100644 --- a/gwt-event-dom/src/main/java/org/gwtproject/event/dom/client/DomEvent.java +++ b/gwt-event-dom/src/main/java/org/gwtproject/event/dom/client/DomEvent.java @@ -66,11 +66,13 @@ public static void fireNativeEvent( // loop. NativeEvent currentNative = type.flyweight.nativeEvent; Element currentRelativeElem = type.flyweight.relativeElem; + Object currentSource = type.flyweight.getSource(); type.flyweight.setNativeEvent(nativeEvent); type.flyweight.setRelativeElement(relativeElem); handlerSource.fireEvent(type.flyweight); type.flyweight.setNativeEvent(currentNative); type.flyweight.setRelativeElement(currentRelativeElem); + type.flyweight.setSource(currentSource); } } }