don't pass google api key, use Ox.Map.GoogleApiKey
This commit is contained in:
parent
66a130e35f
commit
b11d6a81fe
2 changed files with 1 additions and 6 deletions
|
@ -7,7 +7,6 @@ Ox.Map <f> Basic map object
|
||||||
API](http://code.google.com/apis/maps/documentation/javascript/).
|
API](http://code.google.com/apis/maps/documentation/javascript/).
|
||||||
# ARGUMENTS ----------------------------------------------------------------
|
# ARGUMENTS ----------------------------------------------------------------
|
||||||
options <o|{}> options
|
options <o|{}> options
|
||||||
apiKey <s> Google API Key
|
|
||||||
clickable <b|false> If true, clicking on the map finds a place
|
clickable <b|false> If true, clicking on the map finds a place
|
||||||
editable <b|false> If true, places are editable
|
editable <b|false> If true, places are editable
|
||||||
find <s|""> Initial query
|
find <s|""> Initial query
|
||||||
|
@ -89,7 +88,6 @@ Ox.Map = function(options, self) {
|
||||||
var that = Ox.Element({}, self)
|
var that = Ox.Element({}, self)
|
||||||
.defaults({
|
.defaults({
|
||||||
// fixme: isClickable?
|
// fixme: isClickable?
|
||||||
apiKey: '',
|
|
||||||
clickable: false,
|
clickable: false,
|
||||||
editable: false,
|
editable: false,
|
||||||
find: '',
|
find: '',
|
||||||
|
@ -526,7 +524,7 @@ Ox.Map = function(options, self) {
|
||||||
$.getScript(
|
$.getScript(
|
||||||
document.location.protocol
|
document.location.protocol
|
||||||
+ '//maps.google.com/maps/api/js?callback=googleCallback&sensor=false'
|
+ '//maps.google.com/maps/api/js?callback=googleCallback&sensor=false'
|
||||||
+ (options.apiKey ? '&key=' + options.apiKey : '')
|
+ (Ox.Map.GoogleApiKey ? '&key=' + Ox.Map.GoogleApiKey : '')
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -3,7 +3,6 @@
|
||||||
/*@
|
/*@
|
||||||
Ox.MapEditor <f> Map Editor
|
Ox.MapEditor <f> Map Editor
|
||||||
options <o> Options object
|
options <o> Options object
|
||||||
apiKey <s> Google API Key
|
|
||||||
height <n|256> Height in px
|
height <n|256> Height in px
|
||||||
labels <b|false> If true, show labels
|
labels <b|false> If true, show labels
|
||||||
mode <s|'add'> Mode ('add' or 'define')
|
mode <s|'add'> Mode ('add' or 'define')
|
||||||
|
@ -24,7 +23,6 @@ Ox.MapEditor = function(options, self) {
|
||||||
var that = Ox.Element({}, self)
|
var that = Ox.Element({}, self)
|
||||||
.defaults({
|
.defaults({
|
||||||
addPlace: null,
|
addPlace: null,
|
||||||
apiKey: '',
|
|
||||||
collapsible: false,
|
collapsible: false,
|
||||||
editPlace: null,
|
editPlace: null,
|
||||||
getMatches: null,
|
getMatches: null,
|
||||||
|
@ -385,7 +383,6 @@ Ox.MapEditor = function(options, self) {
|
||||||
.appendTo(self.$listStatusbar);
|
.appendTo(self.$listStatusbar);
|
||||||
|
|
||||||
self.$map = Ox.Map({
|
self.$map = Ox.Map({
|
||||||
apiKey: self.options.apiKey,
|
|
||||||
clickable: true,
|
clickable: true,
|
||||||
editable: true,
|
editable: true,
|
||||||
findPlaceholder: Ox._('Find on Map'),
|
findPlaceholder: Ox._('Find on Map'),
|
||||||
|
|
Loading…
Reference in a new issue