Thanks Jester! It's obvious of course as has been said that Flash Player is used for presentation of Flex -- still the SWC as you say and I agree, is a big mistake as it can cause "shock" :-/
Besides this mistake though, seems Yahoo is starting to get it's act together in working with developers; i'm sure to compete with Google. I really see huge things for Web Services and Flex in the next 1-3 years....with the smooth performance of Flash 8 Video, I just have to believe it's possible to do one-up on DirectX and create a unifying OSX WINXP 3D model that is xml tag based in description of object, environments, etc. If this issue is somewhere in there, the sky's the limit (as long as the corp.anality stays out; but w/ the nice change in reasonable deployment model for Flex2 I see good things only). --- JesterXL <[EMAIL PROTECTED]> wrote: > For those who want to see a quick example, you can > download the SWC > (stupidly called Shockave control on the site, > that's where the confusion > came in), and use this code. Keep in mind the > sliders are NOT BACKWARDS! > Since I'm not a map geek, this was my first lesson > in latitude & longitude > as applied to map movements. > > --JesterXL > > <?xml version="1.0" encoding="utf-8"?> > <mx:Application > xmlns:mx="http://www.macromedia.com/2003/mxml" > xmlns:yahoo="com.yahoo.maps.api.flex.*" > initialize="onMapInit()"> > > <mx:Script> > <![CDATA[ > > // import mx.managers.PopUpManager; > import mx.utils.Delegate; > > import com.yahoo.maps.LatLon; > import com.yahoo.maps.Marker; > import com.yahoo.maps.markers.CustomSWFMarker; > import com.yahoo.maps.markers.WaypointMarker; > import com.yahoo.maps.api.flex.YahooMap; > > public var latitude:Number = 37.771829; > public var longitude:Number = -122.401681; > > //private var debugWindow:DebugWindow; > > function onMapInit():Void > { > //debugWindow = > DebugWindow(PopUpManager.createPopUp(this, > DebugWindow, > false)); > //debugWindow.move(400, 400); > } > > function onYahooMapInit() > { > //d("start map lat: " + map_ym.latitude); > //d("start map long: " + map_ym.longitude); > //dProps(WaypointMarker); > lat_slider.value = latitude; > //d("long_slider.value: " + long_slider.value); > //d("longitude: " + longitude); > long_slider.value = longitude; > //d("long_slider.value: " + long_slider.value); > zoom_slider.value = map_ym.getZoomLevel(); > > var a:LatLon = new LatLon(latitude, longitude); > map_ym.setCenterByLatLon(a, 0, false); > > //var a:LatLon = new LatLon(latitude, longitude); > //var m = > map_ym.addMarkerByLatLon(CustomSWFMarker, > map_ym.getCenter(), > {url: "bluebox.swf"}); > //m.addEventListener(YahooMap.MARKER_INITIALIZE, > Delegate.create(this, > onMarker)); > //m.addEventListener("toolAdded", this); > //var rs = m.callCustomMethod("getMoo"); > //d("rs: " + rs); > //var m = map_ym.addMarkerByLatLon(WaypointMarker, > map_ym.getCenter()); > //d("m.isVisible: " + m.isVisible()); > //m.show(); > } > > function onMarker(o) > { > d("onMarker"); > } > > > function d(o) > { > //debugWindow.d(o); > } > > public function dProps(o) > { > for(var p in o) > { > d(p + ": " + o[p]); > } > } > > function updateCords():Void > { > //d("before lat: " + latitude); > //d("before long: " + longitude); > //d("before map lat: " + map_ym.latitude); > //d("before map long: " + map_ym.longitude); > latitude = lat_slider.value; > longitude = long_slider.value; > //d("after lat: " + latitude); > //d("after long: " + longitude); > > > var a:LatLon = new LatLon(latitude, longitude); > map_ym.setCenterByLatLon(a, 3000, false); > /* > d("a.lat: " + a.lat); > d("a.lon: " + a.lon); > d("after map lat: " + map_ym.latitude); > d("after map long: " + map_ym.longitude); > */ > } > > private function updateZoom() > { > map_ym.setZoomLevel(zoom_slider.value); > } > > > ]]> > </mx:Script> > > <mx:Canvas > width="100%" height="100%"> > > <yahoo:YahooMap > id="map_ym" > x="0" > y="0" > latitude="{latitude}" > longitude="{longitude}" > width="100%" > height="100%" > zoomLevel="5" > initialize="onYahooMapInit()" /> > > <mx:HSlider > id="lat_slider" > x="5" > y="206" > width="200" > liveDragging="false" > minimum="-200" maximum="200" > showToolTip="true" > thumbCount="1" > thumbReleased="updateCords()"/> > > <mx:VSlider > id="long_slider" > x="200" > y="6" > height="200" > liveDragging="false" > minimum="-200" maximum="200" > showToolTip="true" > thumbCount="1" > thumbReleased="updateCords()"/> > > <mx:HSlider > id="zoom_slider" > x="4" > y="0" > width="180" > liveDragging="false" > minimum="1" > maximum="17" > showToolTip="true" > thumbCount="1" > thumbReleased="updateZoom()" snapInterval="1" > tickInterval="1" > height="22" /> > > > </mx:Canvas> > > </mx:Application> > > __________________________________ Yahoo! Mail - PC Magazine Editors' Choice 2005 http://mail.yahoo.com ------------------------ Yahoo! Groups Sponsor --------------------~--> Fair play? Video games influencing politics. Click and talk back! http://us.click.yahoo.com/T8sf5C/tzNLAA/TtwFAA/nhFolB/TM --------------------------------------------------------------------~-> -- Flexcoders Mailing List FAQ: http://groups.yahoo.com/group/flexcoders/files/flexcodersFAQ.txt Search Archives: http://www.mail-archive.com/flexcoders%40yahoogroups.com Yahoo! Groups Links <*> To visit your group on the web, go to: http://groups.yahoo.com/group/flexcoders/ <*> To unsubscribe from this group, send an email to: [EMAIL PROTECTED] <*> Your use of Yahoo! Groups is subject to: http://docs.yahoo.com/info/terms/