LMI.MapInit=(function(){var map,L={getMap:function(){return map;}};LMI.Init.addFunction(function(){var i,c,p,loc,M=LMI.Mapping,opts=LMI.Data.mapOptions,propList=['name','listing','listingId','streetAddress','city','state','zipCode','phoneNumbers'];if('centerPoint'in LMI.Data||'theaters'in LMI.Data){opts.enableOverview=false;opts.enableResize=false;map=new M.InteractiveMap('#mapImage',opts);map.addControls(M.Controls.getSmallControls());if('centerPoint'in LMI.Data&&LMI.Data.centerPoint.geoCoded){c=LMI.Data.centerPoint;map.addObject(new DSIcon(new M.Point(c.latitude,c.longitude),LMI.MapUtils.getIcon(-1,'red',true),21,26));}
if("movieSearchType"in LMI.Data&&LMI.Data.movieSearchType==="THEATER"&&"theaters"in LMI.Data&&"theaterIds"in LMI.Data){i=LMI.Data.theaterIds.length-1;LMI.Lang.forEach(LMI.Data.theaterIds.reverse(),function(key){loc=LMI.Data.theaters[key];if(loc.geoCoded){p=new M.MovieMarker(new M.Point(loc.latitude,loc.longitude),i);LMI.Lang.forEach(propList,function(prop){if(prop in loc){p.setProperty(prop,loc[prop]);}});map.addObject(p);}
i--;});}
map.bestFit();}});return L;})();