dlsc-software-consulting-gmbh / GMapsFX

Java API for using Google Maps within a JavaFX application.
http://rterp.github.io/GMapsFX/
Apache License 2.0
319 stars 119 forks source link

Some MapStateEvents never fire #122

Open chris-hatton opened 7 years ago

chris-hatton commented 7 years ago

At least the idle and zoom_changed Events never fire in my JavaFX Application. bounds_changed does fire, but because idle doesn't, the dependentgetBoundsProperty() also never updates.

center_changed and getCenterProperty() do work, however, and I'm registering these in the same places in my application.

The map interacts as normal but possibly GMapsFX's integration with JavaScript has broken for the latest version of the GMaps API? I notice that the version used by GMapsFX is 3.exp; does 'exp' make it always use the latest revision and isn't this fragile?

Any pointers appreciated. I will continue my own investigation and post back any findings.

chris-hatton commented 7 years ago

After seeing this clue: https://stackoverflow.com/questions/44055598/listener-on-map-idle-event-is-not-working-on-google-maps-api-v3-28-18

I tried forking GMapsFX and changing all occurrences of '3.exp' to '3.27' for the API version. However the behaviour is the same; the idle event doesn't fire.

Could this be environmental? I'm on macOS with latest Oracle Java 8 JRE.

GeoffCapper commented 7 years ago

Hi Chris,

I've just grabbed a clean copy and put some System.outs into the idle event, and a listener on the bounds property with similar outputs within MainApp.java, and it all seems to work okay on my windows machine. MainApp has listeners on zoom and centre that update the labels in the toolbar and these all function okay. What is your experience when running MainApp from within the library, rather than using the library via your own code?