Re: GWT+Gmaps Unable to load Google Map [no error]

2009-06-09 Thread Eric Ayers

Hello G,

I looked over your files and didn't see anything obvious.
Unfortunately, the maps documents haven't been updated for GWT 1.6 or
the Google Plugin.  Here are some suggestions:

1) Did you try using hosted mode and setting a break point in  your
EntryPoint class?

2) You also could try running in web mode under firebug and see that
the maps API URL (http://maps.google.com/maps) is being successfully
loaded.

On Tue, Jun 9, 2009 at 8:21 PM, Ggaur...@gmail.com wrote:

 I am fairly new to GWT + Google Maps toolkit.

 I am using eclipse pulgin on windows and was able to successfully
 compile and deploy ExampleWebApp on Google AppEngine  Tomcat.

 I am now struggling to get the SimpleMaps example working. I have
 1.6.4 plugin  gwt-maps-1.0.4. I am not getting any compile time or
 runtime error but the map itself is not showing (I ran ethereal and
 looks like there is no request made). I checked my proxy settings in
 the hosted browser and I can access google page without any problem.
 (I went through most of the questions on the forums but it didnt seem
 to help in my case).
 I didnt run applicationcreator  packageCreator because:
 #1 I just couldn't find those scripts. (Can you please point me to it,
 it was not there in the \gwt-windows-1.6.4 dir)
 # 2 I read that GWT 1.6 onwards, I dont have to run those to create
 GWT eclipse project.

 I am enclosing the files I used; hope someone can point me something
 obvious. I did include the gwt_maps.jar as external jars and as I
 mentioned I do not get any error whatsoever. I even tried deploying to
 google and tomcat and firefox browser, the map just doesn't come up.
 All I see is blank...

 SimpleMaps.gwt.xml (shows under com.google.gwt.maps.GoogleMaps in
 eclipse)
 ===

 ?xml version=1.0 encoding=UTF-8?
 !DOCTYPE module PUBLIC -//Google Inc.//DTD Google Web Toolkit 1.6.4//
 EN http://google-web-toolkit.googlecode.com/svn/tags/1.6.4/distro-
 source/core/src/gwt-module.dtd
 module rename-to='simplemaps'

  !-- Load the Google Maps GWT bindings from the gwt-google-apis
 project --
  !-- Added by projectCreator if you use the -addModule argument --
 inherits name=com.google.gwt.maps.GoogleMaps /
 inherits name=com.google.gwt.user.User /
  !--
    If you want to deploy this application outside of localhost,
    you must obtain a Google Maps API key at:
    http://www.google.com/apis/maps/signup.html
    Replace the src attribute below with a URL that contains your key.
  --
 !-- script src=http://maps.google.com/maps?
 gwt=1amp;file=apiamp;v=2amp;key=http://maps.google.com/maps?
 file=apiamp;v=2amp;sensor=trueamp;key=ABQIVGwKqoUDHju3NY7XZfVXYxRg-2eqO4pXlrSv1PRvWeooUrxUGxSRAPkLn_MJwxBWIVlKup4OMI1z2w
  /
 --
  entry-point class='com.google.gwt.maps.GoogleMaps.client.SimpleMaps'/


  !-- You can usually run under localhost without a
 key                           --
  !-- Set the 'sensor' parameter to true if your app makes use of an
 onboard
      positioning sensor, such as a GPS reciever.
   --
 script src=http://maps.google.com/maps?
 gwt=1amp;file=apiamp;v=2.148 /
 /module



 SimpleMaps.java
 =

 package com.google.gwt.maps.GoogleMaps.client;

 import com.google.gwt.core.client.EntryPoint;
 import com.google.gwt.maps.client.InfoWindowContent;
 import com.google.gwt.maps.client.MapWidget;
 import com.google.gwt.maps.client.control.LargeMapControl;
 import com.google.gwt.maps.client.geom.LatLng;
 import com.google.gwt.maps.client.overlay.Marker;
 import com.google.gwt.user.client.ui.RootPanel;

 public class SimpleMaps implements EntryPoint {
  private MapWidget map;

  // GWT module entry point method.
  public void onModuleLoad() {
    LatLng cawkerCity = LatLng.newInstance(39.509,-98.434);
    // Open a map centered on Cawker City, KS USA

    map = new MapWidget(cawkerCity, 2);
    map.setSize(500px, 300px);

    // Add some controls for the zoom level
    map.addControl(new LargeMapControl());

    // Add a marker
    map.addOverlay(new Marker(cawkerCity));

    // Add an info window to highlight a point of interest
    map.getInfoWindow().open(map.getCenter(),
        new InfoWindowContent(World's Largest Ball of Sisal Twine));

    // Add the map to the HTML host page
    RootPanel.get(mapsTutorial).add(map);
  }
 }



 Web.xml
 ===

 ?xml version=1.0 encoding=UTF-8?
 !DOCTYPE web-app
    PUBLIC -//Sun Microsystems, Inc.//DTD Web Application 2.3//EN
    http://java.sun.com/dtd/web-app_2_3.dtd;

 web-app

  !-- Default page to serve --
  welcome-file-list
    welcome-fileSimpleMaps.html/welcome-file
  /welcome-file-list

  !-- Servlets --
  servlet
    servlet-namegreetServlet/servlet-name
    servlet-
 classcom.google.gwt.maps.GoogleMaps.server.GreetingServiceImpl/
 servlet-class
  /servlet

  servlet-mapping
    servlet-namegreetServlet/servlet-name
    url-pattern/simplemaps/greet/url-pattern
  /servlet-mapping

 /web-app




 SimpleMaps.html
 =
 !DOCTYPE HTML 

Re: GWT+Gmaps Unable to load Google Map [no error]

2009-06-09 Thread G

I tried changing the following line in SimpleMap.java and to my
surprise, and it compiled.

RootPanel.get(mapsSSSTutorial).add(map);

I am using the GWT Compile Project button on eclipse toolbar. Output
of compilation:
Compiling module com.google.gwt.maps.GoogleMaps.SimpleMaps
   Compiling 5 permutations
  Permutation compile succeeded
   Linking into war
  Link succeeded
   Compilation succeeded -- 10.968s


When I looked at the firebug, I dont see the any maps API URL embedded
in the HTML.
Putting breakpoint in the Entryoint class doesn't work either. Looks
like that class doesn't even get called. Which makes me think, I may
be missing something real obvious.

Any thoughts?


--~--~-~--~~~---~--~~
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-Web-Toolkit@googlegroups.com
To unsubscribe from this group, send email to 
google-web-toolkit+unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/Google-Web-Toolkit?hl=en
-~--~~~~--~~--~--~---



Re: GWT+Gmaps Unable to load Google Map [no error]

2009-06-09 Thread G

I tried changing the following line in SimpleMap.java and to my
surprise, and it compiled.

RootPanel.get(mapsSSSTutorial).add(map);

I am using the GWT Compile Project button on eclipse toolbar. Output
of compilation:
Compiling module com.google.gwt.maps.GoogleMaps.SimpleMaps
   Compiling 5 permutations
  Permutation compile succeeded
   Linking into war
  Link succeeded
   Compilation succeeded -- 10.968s


When I looked at the firebug, I dont see the any maps API URL embedded
in the HTML.
Putting breakpoint in the Entryoint class doesn't work either. Looks
like that class doesn't even get called. Which makes me think, I may
be missing something real obvious.

Any thoughts?


--~--~-~--~~~---~--~~
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-Web-Toolkit@googlegroups.com
To unsubscribe from this group, send email to 
google-web-toolkit+unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/Google-Web-Toolkit?hl=en
-~--~~~~--~~--~--~---



Re: GWT+Gmaps Unable to load Google Map [no error]

2009-06-09 Thread Eric Ayers

The change you made compiles because the lookup of the argument to
RootPanel.get() is done at runtime.

If you are new to GWT, have you run through the general GWT tutorial?
It shows how to use the Java Debugger with Hosted mode.

On Tue, Jun 9, 2009 at 10:34 PM, Ggaur...@gmail.com wrote:

 I tried changing the following line in SimpleMap.java and to my
 surprise, and it compiled.

    RootPanel.get(mapsSSSTutorial).add(map);

 I am using the GWT Compile Project button on eclipse toolbar. Output
 of compilation:
 Compiling module com.google.gwt.maps.GoogleMaps.SimpleMaps
   Compiling 5 permutations
      Permutation compile succeeded
   Linking into war
      Link succeeded
   Compilation succeeded -- 10.968s


 When I looked at the firebug, I dont see the any maps API URL embedded
 in the HTML.
 Putting breakpoint in the Entryoint class doesn't work either. Looks
 like that class doesn't even get called. Which makes me think, I may
 be missing something real obvious.

 Any thoughts?


 




-- 
Eric Z. Ayers - GWT Team - Atlanta, GA USA
http://code.google.com/webtoolkit/

--~--~-~--~~~---~--~~
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-Web-Toolkit@googlegroups.com
To unsubscribe from this group, send email to 
google-web-toolkit+unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/Google-Web-Toolkit?hl=en
-~--~~~~--~~--~--~---



Re: GWT+Gmaps Unable to load Google Map [no error]

2009-06-09 Thread G

Eric,
I will go through the GWT debugging tutorial. thanks

But what I dont understand is I dont get any errors at all.

What would be nice is to have an example of Googlemaps + GWT (version
1.6.4)...hope that can be published shortly...

I want to write a fairly complex system using this and I am stuck at
the very basic...


On Jun 9, 10:19 pm, Eric Ayers zun...@google.com wrote:
 The change you made compiles because the lookup of the argument to
 RootPanel.get() is done at runtime.

 If you are new to GWT, have you run through the general GWT tutorial?
 It shows how to use the Java Debugger with Hosted mode.



 On Tue, Jun 9, 2009 at 10:34 PM, Ggaur...@gmail.com wrote:

  I tried changing the following line in SimpleMap.java and to my
  surprise, and it compiled.

     RootPanel.get(mapsSSSTutorial).add(map);

  I am using the GWT Compile Project button on eclipse toolbar. Output
  of compilation:
  Compiling module com.google.gwt.maps.GoogleMaps.SimpleMaps
    Compiling 5 permutations
       Permutation compile succeeded
    Linking into war
       Link succeeded
    Compilation succeeded -- 10.968s

  When I looked at the firebug, I dont see the any maps API URL embedded
  in the HTML.
  Putting breakpoint in the Entryoint class doesn't work either. Looks
  like that class doesn't even get called. Which makes me think, I may
  be missing something real obvious.

  Any thoughts?

 --
 Eric Z. Ayers - GWT Team - Atlanta, GA USAhttp://code.google.com/webtoolkit/
--~--~-~--~~~---~--~~
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-Web-Toolkit@googlegroups.com
To unsubscribe from this group, send email to 
google-web-toolkit+unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/Google-Web-Toolkit?hl=en
-~--~~~~--~~--~--~---