Hi all,

I'm playing with one of the GStreetviewPanorama demo.

I can't get the yawchanged event to be fired. Moreover, I can't get
its value manually: it's still the same as initialized (0 in my case).

What am I doing wrong?

I use IE8 and Chrome 4.

Thanks for any help,

François

--------------------------------


 <script type="text/javascript">

        var myPano;

        function initialize() {
      myPano = new
GStreetviewPanorama(document.getElementById("pano"));
      fenwayPark = new GLatLng(42.345573,-71.098326);
      myPOV = {yaw:0,pitch:-20};
      myPano.setLocationAndPOV(fenwayPark, myPOV);
      GEvent.addListener(myPano, "error", handleNoFlash);
      GEvent.addListener(myPano, "yawchanged", onYawChanged);
    }

    function handleNoFlash(errorCode) {
      if (errorCode == 603) {
        alert("Error: Flash doesn't appear to be supported by your
browser");
        return;
      }
    }

        function onYawChanged(newYaw)
        {
                alert(newYaw);
        }

        function getInfos()
        {
                alert(myPano.getPOV().yaw);
        }

    </script>
  </head>
  <body onload="initialize()" onunload="GUnload()">
    <div name="pano" id="pano" style="width: 500px; height: 300px"></
div>
        <input type="button" value="infos" onClick="getInfos();"/>
  </body>

-- 
You received this message because you are subscribed to the Google Groups 
"Google Maps API" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to 
[email protected].
For more options, visit this group at 
http://groups.google.com/group/google-maps-api?hl=en.

Reply via email to