public static native JavaScriptObject getMap()/*-{
ar latlng = new google.maps.LatLng(50.940872, 6.937888);
var myOptions = {
zoom: 15,
center: latlng,
mapTypeId: google.maps.MapTypeId.ROADMAP
};
var map = new google.maps.Map(div, myOptions);
}-*/;
But I always get the error that "google" isn't known. I new that I ave
to include the script-tag. I tried to put it in the xml-File or the
html-File of my GWT2.0 project, but it doesn't work, Does anyone know
who to setup my project to use the Google Maps API V3 with JSNI???
I hope someone could help me...
Thank's a lot
Regards, Joe
--
You received this message because you are subscribed to the Google Groups "Google Web Toolkit" group.
To post to this group, send email to google-we...@googlegroups.com.
To unsubscribe from this group, send email to google-web-tool...@googlegroups.com.
For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en.
I tried <script type="text/javascript" src="http://maps.google.com/
maps/api/js?sensor=false"></script>
but that doesn't work?!
Concerning the library for Google Maps v3 it isn'z clear to me, how I
can add all the classes to my existing eclipse-project??
Thanl's and Regards
Joe
On 9 Mrz., 16:59, Eric Ayers <zun...@google.com> wrote:
> Some folks have started a library for Google Maps v3. You can browse some
> sample cod here:
>
> http://code.google.com/p/gwt-google-maps-v3/source/browse/#hg/src/com...
>
> From what you describe, it looks like your app is not loading the maps API
> before calling this code.
>
> http://code.google.com/apis/maps/documentation/v3/introduction.html
>
> You probably need to add or fix the <script> tag in your host page that
> loads the Maps API from Google's servers.
> <http://code.google.com/p/gwt-google-maps-v3/source/browse/#hg/src/com...>
>
> On Tue, Mar 9, 2010 at 10:41 AM, Joe <johannes.speckm...@googlemail.com>wrote:
>
>
>
> > Hello everybody!
> > I try to usethe Google Maps API V3 with the GWT, but it doesn't work.
> > In a class I have the following method:
>
> > public static native JavaScriptObject getMap()/*-{
>
> > ar latlng = new google.maps.LatLng(50.940872, 6.937888);
> > var myOptions = {
> > zoom: 15,
> > center: latlng,
> > mapTypeId: google.maps.MapTypeId.ROADMAP
> > };
> > var map = new google.maps.Map(div, myOptions);
> > }-*/;
>
> > But I always get the error that "google" isn't known. I new that I ave
> > to include the script-tag. I tried to put it in the xml-File or the
> > html-File of my GWT2.0 project, but it doesn't work, Does anyone know
> > who to setup my project to use the Google Maps API V3 with JSNI???
> > I hope someone could help me...
> > Thank's a lot
> > Regards, Joe
>
> > --
> > You received this message because you are subscribed to the Google Groups
> > "Google Web Toolkit" group.
> > To post to this group, send email to google-we...@googlegroups.com.
> > To unsubscribe from this group, send email to
> > google-web-tool...@googlegroups.com<google-web-toolkit%2Bunsu...@googlegroups.com>
new $wnd.google.maps.LatLng(...)
not:
new google.maps.LatLng(...)
There's also a basic-but-functional GWT wrapper for maps v3 at
http://code.google.com/p/gwt-maps3/. It might get abandoned if that
other project matures, however.
Jeff
> To unsubscribe from this group, send email to google-web-tool...@googlegroups.com.