开发者

how to get in gwt the current position?

开发者 https://www.devze.com 2022-12-27 15:07 出处:网络
we have this example: http://co开发者_如何学运维de.google.com/apis/maps/documentation/v3/basics.html#DetectingUserLocation

we have this example: http://co开发者_如何学运维de.google.com/apis/maps/documentation/v3/basics.html#DetectingUserLocation

which shows how to get the user's position in JSP code. How to use it using GWT?

thanks


Since GWT runs JavaScript in the browser, you'll have to look into using the brand-new HTML5 Geolocation features to make this work.

In fact, the gwt-mobile-webkit project includes Geolocation features in GWT (targeted at mobile webkit browsers like the one on Android and the iPhone).

If that doesn't fit your needs exactly, you can always have GWT call the necessary native JS code using JSNI.

0

精彩评论

暂无评论...
验证码 换一张
取 消