ACC SHELL
/*! Google Maps jQuery plugin - v1.0.6 - 2013-06-23
* http://jeromesmadja.github.io/initmapjs/
* 2013 Jerome Smadja; Licensed MIT */
!function(a){"use strict";function b(){var b,c=this;c.marker_collection=[],c.init=function(d){var e=this[0],f={options:{center:new g(0,0).get(),zoom:2,mapTypeId:(new i).get("hybrid")}};void 0!==d&&d.controls&&a.extend(f.options,new p(d.controls));var h=a.extend(!0,f,d);return b=c.initMap(e,f.options),h.geolocation&&(c.marker_collection.geolocation_marker={deferred:a.Deferred()},new n(b,h.geolocation,c.marker_collection.geolocation_marker,h.center).init()),h.center&&q.center(b,h.center),h.type&&b.setMapTypeId((new i).get(h.type)),h.markers&&c.markers.add(h.markers),c},c.initMap=function(a,b){return new o.Map(a,b)},c.getMap=function(){return b},c.markers={get:function(a,b){c.markers.exists(a)&&c.marker_collection[a].deferred.done(function(){b.call(this,c.marker_collection[a].marker)})},remove:function(a){c.markers.exists(a)&&c.marker_collection[a].deferred.done(function(){var b=c.marker_collection[a].marker;b.setMap(null),delete c.marker_collection[a]})},all:function(b){var d=q.getKeys(c.marker_collection),e={},f=[];a.map(d,function(a){f.push(c.marker_collection[a].deferred)}),a.when.apply(c,f).done(function(){a.map(d,function(a){void 0!==c.marker_collection[a]&&(e[a]=c.marker_collection[a].marker)}),b.call(c,e)})},add:function(g){a.map(g,function(g,i){c.marker_collection[i]={deferred:a.Deferred()};var j=new d(b,i,g,new e(b,new h),new f).place(c.marker_collection[i].deferred);j.done(function(a){c.marker_collection[i]={deferred:j,marker:a}})})},exists:function(b){return void 0===c.marker_collection[b]?a.error('Marker id "'+b+'" does not exist'):!0}}}function c(a){this.gGeocoder=o.Geocoder,this.position=a}function d(a,b,c,d,e){this.id=b,"undefined"!=typeof c&&(this.map=a,this.options=void 0!==c.options?c.options:{},this.position=c.position,this.title=c.title,this.info_window=c.info_window,this.animation=c.animation),this.GMarker=o.Marker,this.Infowindow=d,this.Animation=e,void 0!==this.animation&&(this.options.animation=this.animate())}function e(a,b){this.GInfoWindow=o.InfoWindow,this.gEvent=b,this.map=a}function f(){this.GAnimation=o.Animation}function g(a,b,c){this.GLatLng=o.LatLng,this.lat=a,this.lng=b,this.nowrap=c}function h(){return o.event}function i(){this.map_type_id=o.MapTypeId}function j(b,c,d,e){var f={};return void 0!==b.position&&(f=d.get(b.position)),void 0!==b.type&&("object"==typeof b.type&&(a.map(b.type,function(a,d){b.type[d]=c.get(b.type[d])}),f.mapTypeIds=b.type),"string"==typeof b.type&&(f.mapTypeIds=[c.get(b.type)])),void 0!==b.style&&(f.style=e.get(b.style)),f}function k(){this.control_position=o.ControlPosition}function l(){this.control_style=o.MapTypeControlStyle}function m(){this.zoom_control_style=o.ZoomControlStyle}function n(a,b,c,i){this.map=a;var j=this;j.init=function(){if(j.has()){var a={};"object"==typeof b.options&&(a=b.options),navigator.geolocation.getCurrentPosition(j.set,j.error,a)}else"function"==typeof b.unsupported&&b.unsupported.call(j.map)},j.has=function(){return"undefined"!=typeof navigator.geolocation},j.set=function(a){var i=new g(a.coords.latitude,a.coords.longitude).get();if(b.center&&q.setCenter(j.map,i),b.marker){var k={};"object"==typeof b.marker&&(k=b.marker),c.marker=new d(j.map,"geolocation_marker",k,new e(j.map,new h),new f).createMarker(i),c.deferred.resolve(c.marker)}j.success(a)},j.error=function(a){q.center(j.map,i),"function"==typeof b.error&&b.error.call(j.map,a)},j.success=function(a){"function"==typeof b.success&&b.success.call(j.map,a)}}var o=google.maps;a.fn.initMap=function(){this.length||a.error('There is no element "'+this.selector+'"');var c=arguments,d=[];return this.each(function(){d.push((new b).init.apply(a(this),c))}),1===d.length&&(d[0].length=1,d=d[0]),d},c.prototype.getGeocode=function(){var b=a.Deferred();return(new this.gGeocoder).geocode({address:this.position},function(a,c){"OK"===c?b.resolve(a):b.reject(c)}),b.promise()},d.prototype={animate:function(){return this.Animation.start(this.animation)},infowindow:function(b,c){var d=this.Infowindow.add(b),e="click";"string"==typeof b.showOn&&(e=b.showOn),this.Infowindow.attachMarker(c,e,d),"string"==typeof b.hideOn&&("click"===b.hideOn&&a.error('"click" event can not be used for closing infowindow'),this.Infowindow.close(c,b.hideOn,d))},place:function(b){if("object"==typeof this.position){var d=new g(this.position[0],this.position[1]).get(),e=new this.GMarker(a.extend(this.options,{map:this.map,position:d}));b.resolve(e),this.setOptions(e)}if("string"==typeof this.position){var f=this;new c(f.position).getGeocode().done(function(c){var d=c[0].geometry.location,e=new f.GMarker(a.extend(f.options,{map:f.map,position:d}));b.resolve(e),f.setOptions(e)}).fail(function(a){b.reject(a)})}return b},createMarker:function(b){var c=new this.GMarker(a.extend(this.options,{map:this.map,position:b}));return this.setOptions(c),c},setOptions:function(a){void 0!==this.info_window&&this.infowindow(this.info_window,a)}},e.prototype={add:function(a){if(void 0!==a){var b=new this.GInfoWindow(a);return"function"==typeof a.closeclick&&this.attachEvent(b,"closeclick",a),"function"==typeof a.content_changed&&this.attachEvent(b,"content_changed",a),"function"==typeof a.domready&&this.attachEvent(b,"domready",a),"function"==typeof a.position_changed&&this.attachEvent(b,"position_changed",a),"function"==typeof a.zindex_changed&&this.attachEvent(b,"zindex_changed",a),b}},attachEvent:function(a,b,c){var d=this.map;return this.gEvent.addListener(a,b,function(){c[b].call(a,d)}),a},attachMarker:function(a,b,c){var d=this.map;return this.gEvent.addListener(a,b,function(){c.open(d,a)}),a},close:function(a,b,c){this.gEvent.addListener(a,b,function(){c.close()})}},f.prototype={start:function(a){return"bounce"===a?this.GAnimation.BOUNCE:"drop"===a?this.GAnimation.DROP:!1},stop:function(a){a.setAnimation(null)}},g.prototype.get=function(){return new this.GLatLng(this.lat,this.lng,this.nowrap)},i.prototype.get=function(a){return"hybrid"===a?this.map_type_id.HYBRID:"satellite"===a?this.map_type_id.SATELLITE:"roadmap"===a?this.map_type_id.ROADMAP:this.map_type_id.TERRAIN};var p=function(a){var b={};return a.map_type&&("boolean"==typeof a.map_type&&(b.mapTypeControl=a.map_type),"object"==typeof a.map_type&&(b.mapTypeControlOptions=new j(a.map_type,new i,new k,new l))),void 0!==a.overview&&("boolean"==typeof a.overview&&(b.overviewMapControl=a.overview),"object"==typeof a.overview&&(b.overviewMapControl=!0,b.overviewMapControlOptions={opened:a.overview.opened})),void 0!==a.pan&&("boolean"==typeof a.pan&&(b.panControl=a.pan),"object"==typeof a.pan&&(b.panControlOptions=(new k).get(a.pan.position))),void 0!==a.rotate&&("boolean"==typeof a.rotate&&(b.rotateControl=a.rotate),"object"==typeof a.rotate&&(b.rotateControlOptions=(new k).get(a.rotate.position))),void 0!==a.scale&&("boolean"==typeof a.scale&&(b.scaleControl=a.scale),"object"==typeof a.scale&&(b.scaleControlOptions=(new k).get(a.scale.position))),void 0!==a.street_view&&("boolean"==typeof a.street_view&&(b.streetViewControl=a.street_view),"object"==typeof a.street_view&&(b.streetViewControlOptions=(new k).get(a.street_view.position))),void 0!==a.zoom&&("boolean"==typeof a.zoom&&(b.zoomControl=a.zoom),"object"==typeof a.zoom&&(b.zoomControlOptions=(new k).get(a.zoom.position),void 0!==a.zoom.style&&(b.zoomControlOptions.style=(new m).get(a.zoom.style)))),b};k.prototype.get=function(a){return"bottom_center"===a?{position:this.control_position.BOTTOM_CENTER}:"bottom_left"===a?{position:this.control_position.BOTTOM_LEFT}:"bottom_right"===a?{position:this.control_position.BOTTOM_RIGHT}:"left_bottom"===a?{position:this.control_position.LEFT_BOTTOM}:"left_center"===a?{position:this.control_position.LEFT_CENTER}:"left_top"===a?{position:this.control_position.LEFT_TOP}:"right_bottom"===a?{position:this.control_position.RIGHT_BOTTOM}:"right_center"===a?{position:this.control_position.RIGHT_CENTER}:"right_top"===a?{position:this.control_position.RIGHT_TOP}:"top_center"===a?{position:this.control_position.TOP_CENTER}:"top_right"===a?{position:this.control_position.TOP_RIGHT}:{position:this.control_position.TOP_LEFT}},l.prototype.get=function(a){return"dropdown_menu"===a?this.control_style.DROPDOWN_MENU:"horizontal_bar"===a?this.control_style.HORIZONTAL_BAR:this.control_style.DEFAULT},m.prototype.get=function(a){return"large"===a?this.zoom_control_style.LARGE:"small"===a?this.zoom_control_style.SMALL:this.zoom_control_style.DEFAULT};var q={center:function(a,b,d){"string"==typeof b&&new c(b).getGeocode().done(function(b){q.setCenter(a,b[0].geometry.location,d)}),"object"==typeof b&&q.setCenter(a,new g(b[0],b[1]).get(),d)},setCenter:function(a,b,c){void 0!==c&&c===!0?a.setCenter(b):a.panTo(b)},getKeys:function(a){var b=[];for(var c in a)b.push(c);return b}}}(jQuery);
ACC SHELL 2018