Potlatch 1/Development overview/Yahoo

From OpenStreetMap Wiki
Jump to navigation Jump to search

How the Yahoo maps layer works

Potlatch is able to access Yahoo satellite imagery through the official Yahoo Maps API.

Access to this API is typically through a Yahoo-supplied Flash Component - a package of ActionScript classes. Unfortunately, components are not directly supported by Ming, the open-source SWF compiler used in Potlatch.

Consequently, a separate SWF (compiled with the commercial Macromedia Flash authoring environment), yahoo.swf, contains the Yahoo component and a very limited amount of code (about five lines!) to control this. Potlatch loads this SWF into memory as a 'nested movie clip', and sends it the new map position and scale by means of constantly-monitored global variables.

The .fla (Flash source file) is not in svn, but you can request it from Richard who will try to dig it out for you if you really want. :)