Closed mvysny closed 8 months ago
Yup, modifying Geolocation
a bit resolves the issue:
private static Geolocation checkPosition(UI ui, UpdateListener listener, ErrorListener errorListener, GeolocationOptions options, boolean get) {
Geolocation geolocation = new Geolocation();
final Component modal = ui.getInternals().getActiveModalComponent();
geolocation.ui = modal == null ? ui : modal;
Then replace all ui.getElement() with geolocation.ui.getElement()
Fixed (or workaround, probably a not perfect solutions still...) in https://github.com/viritin/flow-viritin/commit/7cff9b226a42b8393b9fd7316a53e0cd8495ed45
Version cut, but oss sonatype seems to be pending...
Consider the following example:
Viritin fires the
geoupdate
CustomEvent on the UI but unfortunately the event is ignored by Flow because there's a modal Dialog open. Perhaps the fix would be to fire events on the modal Dialog itself if there is a modal element open.