fix docs
[roojs1] / Roo / bootstrap / LocationPicker.js
index 5c0b142..0de0d63 100644 (file)
@@ -180,7 +180,8 @@ Roo.extend(Roo.bootstrap.LocationPicker, Roo.bootstrap.Component,  {
     initial: function()
     {
         if(typeof(google) == 'undefined' || typeof(google.maps) == 'undefined'){
-            this.fireEvent('loadexception', this, this.gMapContext.location);
+            this.fireEvent('loadexception', this);
+            return;
         }
         
         if(!this.mapTypeId){
@@ -270,7 +271,7 @@ Roo.extend(Roo.bootstrap.LocationPicker, Roo.bootstrap.Component,  {
     
     getGmapContext: function() 
     {
-        return this.gMapContext
+        return (typeof(this.gMapContext) == 'undefined') ? false : this.gMapContext;
     },
     
     GMapContext: function()