com/libs/google_js_api
Differences between version EMPTY and #8885
0a1,18
> This library contains extern classes that allow static type checking and compilation for various Google javascript API's. Currently, it contains the base google loader class, which is documented [[http://code.google.com/apis/ajax/documentation/|here]].
>
> ====== Namespaces and google.loader() ======
> Many of Google's javascript types and methods are given "nice" namespaces. However, in many cases, they differ from how Haxe treats class and instance naming. The first issue is with the base loader functionality, given by google.load(). "google" in this case behaves like a variable containing a few static methods, one of which is a load method. Later on, the "google" namespace is introduced, with sub packages like google.maps, and google.search. This confuses completion for packages in Haxe.
>
> Using some initialization magic, the "google" instance variable gets assigned to "Google", which fits with the standard Haxe method of naming classes and handling static methods.
>
> ====== Google Earth ======
> Google earth does not currently have a well behaved namespace, so unfortunately most classes exist in the base package. Once again, the google.earth instance and functions are mapped to the Earth class as "google.Earth". The main instance creation function becomes:
>
> <code haxe>
> google.Earth.createInstance('map3d', initCallback, failureCallback);
> </code>
>
> This is managed with more initialization magic, and will happen automatically
>
>
>
| Ver | Date | Lg | User | Action |
|---|---|---|---|---|
| #8892 | 2010-07-15 07:29:50 | en | jjdonald | View | Diff |
| #8891 | 2010-07-15 03:25:58 | en | jjdonald | View | Diff |
| #8890 | 2010-07-15 03:25:02 | en | jjdonald | View | Diff |
| #8889 | 2010-07-15 01:34:18 | en | jjdonald | Changed title from google-js-api : The Google Javascript API Extern to google-js-api |
| #8888 | 2010-07-15 01:31:30 | en | jjdonald | View | Diff |
| #8887 | 2010-07-15 01:30:50 | en | jjdonald | View | Diff |
| #8886 | 2010-07-15 01:30:33 | en | jjdonald | View | Diff |
| #8885 | 2010-07-15 01:12:45 | en | jjdonald | View | Diff |
| #8884 | 2010-07-15 01:12:45 | en | jjdonald | Set title to google-js-api : The Google Javascript API Extern |
Previous | Next