1
2
3
4
5
6
7
8
9
10
11
12
13
14
15 from __pyjamas__ import JS
16
17
18 -def LatLng(lat, lng, nowrap=True):
19 if nowrap:
20 JS("return new $wnd['google']['maps']['LatLng'](@{{lat}}, @{{lng}}, @{{nowrap}})")
21 else:
22 JS("return new $wnd['google']['maps']['LatLng'](@{{lat}}, @{{lng}})")
23
24
26 if sw and ne:
27 JS("return new $wnd['google']['maps']['LatLngBounds'](@{{sw}}, @{{ne}})")
28 else:
29 JS("return new $wnd['google']['maps']['LatLngBounds']()")
30
31
33 JS("return new $wnd['google']['maps']['MVCArray'](@{{array}})")
34
35
37 JS("return new $wnd['google']['maps']['Point'](@{{x}}, @{{y}})")
38
39
40 -def Size(width, height, widthUnit, heightUnit):
41 if widthUnit and heightUnit:
42 JS("""
43 return new $wnd['google']['maps']['Size']
44 (@{{width}}, @{{height}}, @{{widthUnit}}, @{{heightUnit}})
45 """)
46 else:
47 JS("return new $wnd['google']['maps']['Size'](@{{width}}, @{{height}})")
48
49
51 JS("return new Array()")
52