// The Feed Maps code is available under an Apache License, Version 2.0 http://www.apache.org/licenses/LICENSE-2.0
// Original Code Source: http://www.mapchannels.com/FeedMaps.aspx

    MCFM.prototype.iF = function () {this.co = 0;if (navigator.userAgent.indexOf("Firefox") != -1) {this.co = 1;} else if (navigator.userAgent.indexOf("MSIE") != -1) {this.co = 2;} else if (navigator.userAgent.indexOf("Safari") != -1) {this.co = 3;} else if (navigator.userAgent.indexOf("Opera") != -1) {this.co = 4;}};
    var FM_GEOXML = 0;
    var FM_KML = 1;
    var FM_GEORSS = 2;
    var FM_SPREADSHEET = 3;
    var FM_TXT = 4;
    var FM_POINT = 1;
    var FM_POLYLINE = 2;
    var FM_POLYGON = 3;

    function FMDescriptionFilterManager() {
        this.D = false;
        this.bs = false;
        this.iY = true;
        this.iS = false;
        this.bG = [];
        this.am = [];
        this.fQ = [];
        this.dJ = [];
        this.aX = true;
    }

    MCFM.prototype.initDescriptionFilters = function (aI, fd, hF) {if (hF != false) {fd.sort(mcfm.iG);}var A = this.aL;A.D = aI;A.bs = true;A.iC = aI;A.bG = fd;for (var i = 0; i < A.bG.length; i++) {A.dJ[i] = A.bG[i].toLowerCase();A.fQ[i] = this.cX(A.bG[i]);A.am[i] = false;}A.aX = true;};
    MCFM.prototype.iJ = function () {var A = this.aL;A.aX = true;for (var i = 0; i < this.I.length; i++) {var g = this.I[i];for (var j = 0; j < g.G.length; j++) {var o = g.G[j];for (var k = 0; k < A.dJ.length; k++) {var jd = o.dx.indexOf(A.dJ[k]);o.fP[k] = (jd != -1) ? true : false;}}}};
    MCFM.prototype.fu = function () {var A = this.aL;for (var i = 0; i < A.am.length; i++) {A.am[i] = false;this.e("d" + i).checked = false;}A.aX = true;if (this.e("dfAny")) {this.e("dfAny").checked = true;}};
    MCFM.prototype.dfClickAny = function () {this.fu();this.K();};
    MCFM.prototype.dfCheckAny = function (a) {var A = this.aL;for (var i = 0; i < A.am.length; i++) {A.am[i] = false;this.e("d" + i).checked = false;}A.aX = a.checked;this.K();};
    MCFM.prototype.dfClickNone = function () {var A = this.aL;for (var i = 0; i < A.am.length; i++) {A.am[i] = false;this.e("d" + i).checked = false;}A.aX = false;this.e("dfAny").checked = false;this.K();this.al();};
    MCFM.prototype.dfCheck = function (a) {var A = this.aL;var i = parseInt(a.id.substr(1));A.am[i] = a.checked;A.aX = false;this.e("dfAny").checked = false;this.K();this.al();};
    MCFM.prototype.dfClick = function (ix) {var A = this.aL;A.am[ix] = true;for (var i = 0; i < A.am.length; i++) {A.am[i] = i == ix;this.e("d" + i).checked = i == ix;}A.aX = false;this.e("dfAny").checked = false;this.K();this.al();};
    MCFM.prototype.directionsToHere = function () {this.fR = "to";this.e("directionsTitle").innerHTML = " - <b>" + this.txt_ToHere + "</b> - <a href='javascript:mcfm.directionsFromHere()'>" + this.txt_FromHere + "</a>";this.e("directionsSubtitle").innerHTML = this.txt_StartAddress;this.e("directions1").style.display = "none";this.e("directions2").style.display = "block";};
    MCFM.prototype.directionsFromHere = function () {this.fR = "from";this.e("directionsTitle").innerHTML = " - <a href='javascript:mcfm.directionsToHere()'>" + this.txt_ToHere + "</a> - <b>" + this.txt_FromHere + "</b>";this.e("directionsSubtitle").innerHTML = this.txt_EndAddress;this.e("directions1").style.display = "none";this.e("directions2").style.display = "block";};
    MCFM.prototype.directionsBack = function () {this.e("directions1").style.display = "block";this.e("directions2").style.display = "none";};
    MCFM.prototype.directionsFind = function () {this.hU();};
    MCFM.prototype.directionsKey = function (dj) {var el = dj.keyCode;if (el == 13) {this.directionsFind();return false;}return true;};
    MCFM.prototype.closeDirections = function () {if (this.aO) {this.aO.clear();this.aO = null;}this.e("fmDirections").innerHTML = "";this.e("fmIndex").style.display = "inline";this.cP();};
    MCFM.prototype.hU = function (jg) {if (this.aO) {this.closeDirections();}if (!this.sidebarShow) {this.sidebarClick();}this.e("fmFooterTitle").innerHTML = this.txt_FindingDirections;var ef = this.e("directionsLocation").value;if (ef.length > 0) {var at = this.map.getInfoWindow();var T = at.getPoint();if (this.fR == "to") {var fH = "from: " + ef + " to:" + this.ds.D + "@" + T.lat() + "," + T.lng();} else {var fH = "from: " + this.ds.D + "@" + T.lat() + "," + T.lng() + " to: " + ef;}var gQ = this.e("fmDirections");this.aO = new GDirections(this.map, gQ);GEvent.addListener(mcfm.aO, "load", FMDirectionsLoaded);GEvent.addListener(mcfm.aO, "error", FMDirectionsError);var jk = this.aO.load(fH);} else {alert(this.txt_PleaseEnterLocation);}};

    function FMDirectionsLoaded() {
        mcfm.e("fmFooterTitle").innerHTML = "<a href='javascript:mcfm.closeDirections()'>" + mcfm.txt_ClearDirections + "</a>";
        mcfm.e("fmIndex").style.display = "none";
    }


    function FMDirectionsError() {
        mcfm.cP();
        var aV = "";
        var gs = mcfm.aO.getStatus().code;
        switch (gs) {
          case G_GEO_UNKNOWN_ADDRESS:
            aV = mcfm.txt_G_GEO_UNKNOWN_ADDRESS;
            break;
          case G_GEO_SERVER_ERROR:
            aV = mcfm.txt_G_GEO_SERVER_ERROR;
            break;
          case G_GEO_MISSING_QUERY:
            aV = mcfm.txt_G_GEO_MISSING_QUERY;
            break;
          case G_GEO_BAD_KEY:
            aV = mcfm.txt_G_GEO_BAD_KEY;
            break;
          case G_GEO_BAD_REQUEST:
            aV = mcfm.txt_G_GEO_BAD_REQUEST;
            break;
          default:
            aV = mcfm.txt_G_GEO_DEFAULTERROR;
            break;
        }
        aV += " " + this.txt_ErrorCode + ": " + gs;
        alert(aV);
    }

    MCFM.prototype.K = function () {this.dw = this.sidebarWidth - this.scrollbarWidth;var A = this.aL;var fG = 0;for (var i = 0; i < A.am.length; i++) {if (A.am[i]) {fG++;}}var de = 0;if (A.aX) {de = 1;} else if (fG == 0) {de = -1;}var aH = this.aY;var eS = 0;for (var i = 0; i < aH.af.length; i++) {var V = aH.af[i];if (V.by) {eS++;}}var iZ = eS == aH.af.length;var C = this.map.getBounds();this.aC = [];var aK = [];for (var i = 0; i < this.I.length; i++) {var g = this.I[i];if (g.O == FM_GEOXML) {if (g.v) {if (g.H) {g.v.show();} else {g.v.hide();}}} else {for (var j = 0; j < g.G.length; j++) {var o = g.G[j];var aq = g.H;if (aq && this.aZ.length > 0) {var ix = o.aU.indexOf(this.aZ);if (ix < 0) {aq = false;}}if (de == -1) {aq = false;} else if (de == 0) {var eA = true;for (var k = 0; k < A.bG.length && eA; k++) {if (A.am[k]) {if (!o.fP[k]) {eA = false;}}}if (!eA) {aq = false;}}if (aH.bs && !iZ) {var eT = false;var V = aH.fM[o.aj.iconUrl];if (V) {eT = V.by;}if (!eT) {aq = false;}}if (this.visFilter) {var bj;if (o.F) {bj = C.intersects(o.F);} else {bj = C.contains(o.M);}if (!bj) {aq = false;}}if (aq) {aK.push(o);}if (o.v) {if (!aq) {o.v.hide();}}}}}aK.sort(mcfm.cQ);if (this.pagingEnabled) {this.bV = (aK.length > this.pageSize) ? true : false;}if (this.bV) {this.bq = parseInt((aK.length + this.pageSize - 1) / this.pageSize);if (this.bq < 1) {this.bq = 1;}if (this.aE > this.bq) {this.aE = this.bq;}var gv = (this.aE - 1) * this.pageSize;var cO = this.aE * this.pageSize;if (cO > aK.length) {cO = aK.length;}for (var i = 0; i < aK.length; i++) {var o = aK[i];if (i >= gv && i < cO) {o.bf();this.aC.push(o);} else {if (o.v) {o.v.hide();}}}if (this.pageDetail) {this.e("pageTitle").innerHTML = (gv + 1) + " to " + cO;}var fT = this.e("pageSelect");fT.options.length = 0;for (i = 0; i < this.bq; i++) {var ak = (i + 1) == this.aE;var aR = new Option((i + 1), i, ak, ak);fT.options[i] = aR;}} else {this.aC = aK;for (var i = 0; i < this.aC.length; i++) {var o = this.aC[i];o.bf();}this.aE = 1;}for (var i = 0; i < this.aC.length; i++) {var o = this.aC[i];o.bw = i;}var f = "";for (var i = 0; i < this.aC.length; i++) {var o = this.aC[i];f += o.bZ();}var fe = 0;if (this.P && this.P.H) {var eb = this.P.G;eb.sort(this.P.eY ? mcfm.iD : mcfm.cQ);for (var i = 0; i < eb.length; i++) {var o = eb[i];var aq = true;if (this.aZ.length > 0) {var ix = o.aU.indexOf(this.aZ);if (ix < 0) {aq = false;}}if (this.visFilter) {var bj;if (o.F) {bj = C.intersects(o.F);} else {bj = C.contains(o.M);}if (!bj) {aq = false;}}if (aq) {o.bw = i;f += o.bZ();fe++;}if (aq) {o.bf();} else {if (o.v) {o.v.hide();}}}}var ee = 0;if (this.av && this.av.H) {var er = this.av.bb;er.sort(mcfm.cQ);for (var i = 0; i < er.length; i++) {var J = er[i];var ep = true;if (this.aZ.length > 0) {var ix = J.aU.indexOf(this.aZ);if (ix < 0) {ep = false;}}if (ep) {J.bw = i;f += J.bZ();ee++;}if (J.v) {if (ep) {J.v.show();} else {J.v.hide();}}}}this.ia();this.e("fmIndex").innerHTML = f;var aM = aK.length;var bU = "";if (aM > 0) {bU = aM + " " + (aM == 1 ? this.txt_Location : this.txt_Locations);} else {if (this.av && this.av.H && ee) {aM = ee;bU = aM + " " + (aM == 1 ? this.txt_Photo : this.txt_Photos);} else if (this.P && this.P.H) {aM = fe;bU = aM + " " + (aM == 1 ? this.txt_Hotel : this.txt_Hotels);}}if (bU == "") {bU = "0 " + this.txt_Locations;}var titleHtml = "<div style='float:left'>&nbsp;" + bU + "</div>";if (this.sidebarViewAll) {titleHtml += "<div style='float:right'><a href='javascript:mcfm.viewAll()' style='color:black;font-weight:bold'>" + this.txt_ViewAll + "</a>&nbsp;</div>";}this.e("fmSidebarTitle").innerHTML = titleHtml;};
    MCFM.prototype.pagePrev = function () {this.map.closeInfoWindow();if (this.aE > 1) {this.aE--;this.K();}};
    MCFM.prototype.pageNext = function () {this.map.closeInfoWindow();if (this.aE < this.bq) {this.aE++;this.K();}};
    MCFM.prototype.pageSelect = function (a) {this.map.closeInfoWindow();this.aE = a.selectedIndex + 1;this.K();};

    function FMFeed(aI, iM, hv, eR) {
        this.D = aI;
        this.bM = iM;
        this.O = hv;
        this.ac = "";
        this.cV = [];
        this.G = [];
        this.bC = [];
        this.aD = 0;
        if (eR == false || eR == 0) {
            this.aD = -1;
        }
        this.H = false;
        this.F = null;
        this.aj = new FMStyle;
        this.cU = false;
        this.v = null;
        this.feedTag = "";
        this.cL = "A";
        this.cW = "B";
        this.cI = "C";
        this.cD = "unset";
        this.dc = "unset";
        this.dB = "unset";
        this.dF = "unset";
        this.dN = "unset";
    }

    FMFeed.prototype.jj = function () {if (this.O == FM_GEOXML) {mcfm.map.addOverlay(this.v);} else {for (var i = 0; i < this.G.length; i++) {var o = this.G[i];o.bf();}}};
    FMFeed.prototype.gc = function () {if (this.F) {var L = this.F.getCenter();var R = mcfm.map.getBoundsZoomLevel(this.F);mcfm.map.setCenter(L, R);}};
    FMFeed.prototype.setMarkerStyle = function (ck, hI, hO, hM, hL, hK, hJ, fA, ig, gE) {var r = this.aj;r.iconUrl = ck;r.iconSize = new GSize(hI, hO);r.iconAnchor = new GPoint(hM, hL);r.infoAnchor = new GPoint(hK, hJ);if (typeof fA != "undefined") {r.shadowUrl = fA;r.shadowSize = new GSize(ig, gE);}this.cU = true;};
    FMFeed.prototype.setPolyStyle = function (hm, hn, hk, ho, hq, hs, hp) {var r = this.aj;r.lineWidth = parseInt(hm);r.lineOpacity = parseFloat(hn);r.lineCol = hk;r.polyFill = parseInt(ho);r.polyOutline = parseInt(hq);r.polyOpacity = parseFloat(hs);r.polyCol = hp;this.cU = true;};
    MCFM.prototype.hy = function () {this.dA = 0;for (var i = 0; i < this.I.length; i++) {var g = this.I[i];if (g.aD == 0) {this.dA++;g.cq();}}if (this.mapHotels) {this.gJ();}if (this.mapPanoramio) {this.gZ();}if (this.dA == 0) {this.fJ();}};
    FMFeed.prototype.cq = function () {switch (this.O) {case FM_GEOXML:this.hY();break;case FM_KML:this.dD();break;case FM_GEORSS:this.hW();break;case FM_SPREADSHEET:this.hV();break;case FM_TXT:this.dK();break;default:;}};
    FMFeed.prototype.setTag = function (a) {this.feedTag = a;};
    MCFM.prototype.addFeed = function (ao) {this.I.push(ao);};
    MCFM.prototype.bW = function (ao) {this.fN++;if (this.fN >= this.dA) {this.fJ();}setTimeout("mcfm.timerGetFeedBounds()", 1);};
    MCFM.prototype.timerGetFeedBounds = function () {var eU = false;for (var i = 0; i < this.I.length; i++) {var g = this.I[i];if (g.O == FM_GEOXML && g.F == null) {var eg = g.v;if (eg.hasLoaded()) {g.F = eg.getDefaultBounds();this.aW.extend(g.F.getSouthWest());this.aW.extend(g.F.getNorthEast());var L = this.aW.getCenter();var R = this.map.getBoundsZoomLevel(this.aW);this.map.setCenter(L, R);} else {eU = true;}}}var jn = mcfm.F;if (eU) {setTimeout("mcfm.timerGetFeedBounds()", 100);}};
    FMFeed.prototype.setXField = function (a) {this.cL = a;};
    FMFeed.prototype.setYField = function (a) {this.cW = a;};
    FMFeed.prototype.setTitleField = function (a) {this.cI = a;};
    FMFeed.prototype.setDescriptionField = function (a) {this.cD = a;};
    FMFeed.prototype.setLinkField = function (a) {this.dc = a;};
    FMFeed.prototype.setHeadingField = function (a) {this.dB = a;};
    FMFeed.prototype.setPitchField = function (a) {this.dF = a;};
    FMFeed.prototype.setMagnifyField = function (a) {this.dN = a;};
    FMFeed.prototype.setFields = function (x, y, t, d, l, h, p, m) {this.cL = x;this.cW = y;this.cI = t;this.cD = d;this.dc = l;this.dB = h;this.dF = p;this.dN = m;};
    FMFeed.prototype.hY = function () {var g = this;this.v = new GGeoXml(this.bM);this.H = true;mcfm.bW(g);};
    FMFeed.prototype.hP = function (bn) {var hh = GXml.parse(bn);var cr = hh.documentElement;var gl = cr.getElementsByTagName("Style");var gi = cr.getElementsByTagName("StyleMap");var gj = cr.getElementsByTagName("Placemark");var fy = cr.getElementsByTagName("name");if (fy.length > 0 && this.D.length == 0) {this.D = GXml.value(fy[0]);}var fz = cr.getElementsByTagName("description");if (fz.length > 0) {this.ac = GXml.value(fz[0]);}for (var i = 0; i < gl.length; i++) {var cB = gl[i];var r = new FMStyle;r.ii(cB);this.cV[r.cR] = r;}for (var i = 0; i < gi.length; i++) {var cB = gi[i];var r = new FMStyle;r.cR = cB.getAttribute("id");var ha = cB.getElementsByTagName("styleUrl");var io = GXml.value(ha[0]).substr(1);var eQ = this.cV[io];if (eQ) {r.iconUrl = eQ.iconUrl;this.cV[r.cR] = r;}}for (var i = 0; i < gj.length; i++) {var cj = gj[i];var o = new FMPlace(this);o.dD(cj, this);this.G.push(o);}};
    FMFeed.prototype.dD = function () {var g = this;GDownloadUrl(this.bM, function (bn) {g.H = true;g.hP(bn);mcfm.bW(g);});};
    FMFeed.prototype.hW = function () {var g = this;var dZ = new (google.feeds.Feed)(this.bM);dZ.setResultFormat(google.feeds.Feed.MIXED_FORMAT);dZ.setNumEntries(200);dZ.load(function (result) {if (!result.error) {var dS = result.feed.entries;for (var i = 0; i < dS.length; i++) {var o = new FMPlace(g);var aw = dS[i].xmlNode;o.je(aw, g);g.G.push(o);}g.H = true;}mcfm.bW(g);});};
    FMFeed.prototype.hV = function () {var g = this;var aF = "http://spreadsheets.google.com/feeds/cells/" + g.bM + "/od6/public/basic?alt=json-in-script&callback=FMloadSpreadsheet";var bc = new FMJSON(aF);bc.dh();bc.dk();};

    function FMloadSpreadsheet(a) {
        var dS = [];
        var dP = eval(a);
        var fj = dP.feed.id.$t;
        var iW = fj.indexOf("cells/") + 6;
        var cS = fj.substr(iW);
        var iV = cS.indexOf("/");
        cS = cS.substr(0, iV);
        var cn = false;
        var g = null;
        for (var i = 0; i < mcfm.I.length && !cn; i++) {
            g = mcfm.I[i];
            if (g.bM == cS) {
                cn = true;
            }
        }
        var jl = dP.feed.category[0];
        var fE = dP.feed.entry;
        var o = new FMPlace(g);
        var eo = 0;
        for (var i = 0; i < fE.length; i++) {
            var fh = fE[i];
            var gd = fh.title.$t;
            var aw = fh.content.$t;
            var ba = gd.substr(0, 1);
            var ea = parseInt(gd.substr(1));
            if (ea > 1) {
                if (ea != eo) {
                    if (eo > 1) {
                        if (o.bv != null && o.bt != null) {
                            g.G.push(o);
                        }
                        o = new FMPlace(g);
                    }
                    eo = ea;
                }
                if (ba == g.cL && aw.length > 0) {
                    o.bv = parseFloat(aw);
                } else if (ba == g.cW && aw.length > 0) {
                    o.bt = parseFloat(aw);
                } else if (ba == g.cI) {
                    o.D = aw;
                } else if (ba == g.cD) {
                    o.ac = aw;
                } else if (ba == g.dc) {
                    o.ah = aw;
                } else if (ba == g.dB) {
                    o.cb = aw;
                } else if (ba == g.dF) {
                    o.dM = aw;
                } else if (ba == g.dN) {
                    o.dL = aw;
                }
            }
        }
        if (o.bv != null && o.bt != null) {
            g.G.push(o);
        }
        for (var i = 0; i < g.G.length; i++) {
            var o = g.G[i];
            o.M = new GLatLng(o.bt, o.bv);
            o.O = FM_POINT;
            o.cT();
        }
        g.H = true;
        mcfm.bW(g);
    }

    FMFeed.prototype.iK = function (bn) {var cJ = bn.split("\r\n");for (var i = 1; i < cJ.length; i++) {var hT = cJ[i];var o = new FMPlace(this);o.dK(hT, this);if (o.bv != null && o.bt != null) {this.G.push(o);}}};
    FMFeed.prototype.dK = function () {var g = this;GDownloadUrl(this.bM, function (bn) {g.H = true;g.iK(bn);mcfm.bW(g);});};
    MCFM.prototype.al = function () {this.map.closeInfoWindow();this.bi();};
    MCFM.prototype.feedClick = function (ix) {var iL = this.I[ix];for (var i = 0; i < this.I.length; i++) {var g = this.I[i];if (g == iL) {if (this.e("f" + i)) {this.e("f" + i).checked = true;}g.H = true;if (g.aD < 0) {g.aD = 0;g.cq();this.cE = g;} else {g.gc();}} else {g.H = false;if (this.e("f" + i)) {this.e("f" + i).checked = false;}}}var ag = this.e("hotelsBox");if (ag) {ag.checked = false;this.hotelsCheck(ag);}var ai = this.e("panoramioBox");if (ai) {ai.checked = false;this.panoramioCheck(ai);}this.K();this.al();};
    MCFM.prototype.feedCheck = function (a) {var ix = parseInt(a.id.substr(1));var g = this.I[ix];g.H = a.checked;if (g.H && g.aD < 0) {g.aD = 0;g.cq();} else {this.K();}this.al();};
    MCFM.prototype.feedClickAll = function () {for (var i = 0; i < this.I.length; i++) {var g = this.I[i];g.H = true;if (this.e("f" + i)) {this.e("f" + i).checked = true;}if (g.aD < 0) {g.aD = 0;g.cq();}}this.cd();this.K();this.al();var C = null;for (var i = 0; i < this.I.length; i++) {var g = this.I[i];if (g.F) {if (i == 0) {C = g.F;} else {C.extend(g.F.getSouthWest());C.extend(g.F.getNorthEast());}}}if (C) {var L = C.getCenter();var R = mcfm.map.getBoundsZoomLevel(C);mcfm.map.setCenter(L, R);}};
    MCFM.prototype.feedClickNone = function () {this.al();for (var i = 0; i < this.I.length; i++) {var g = this.I[i];g.H = false;if (this.e("f" + i)) {this.e("f" + i).checked = false;}}this.cd();var ag = this.e("hotelsBox");if (ag) {ag.checked = false;this.hotelsCheck(ag);}var ai = this.e("panoramioBox");if (ai) {ai.checked = false;this.panoramioCheck(ai);}this.K();};
    MCFM.prototype.rowHi = function (a) {a.style.backgroundColor = "whitesmoke";var ix = parseInt(a.id.substr(1));var o = this.aC[ix];this.bK(o);};
    MCFM.prototype.rowLo = function (a) {a.style.backgroundColor = "white";this.bi();};
    MCFM.prototype.rowClick = function (a) {var ix = parseInt(a.id.substr(1));var o = this.aC[ix];if (o.O == FM_POINT) {this.be(o);} else {this.be(o, o.M);}};
    MCFM.prototype.bK = function (Q) {if (Q) {this.bQ.innerHTML = "<div class='markerTooltip'><b>" + Q.dr + "</b></div>";var bk = Q.v;var T = Q.M;var z = this.map.getZoom();var fS = this.map.getCurrentMapType().getProjection().fromLatLngToPixel(this.map.fromDivPixelToLatLng(new GPoint(0, 0), true), z);var fV = this.map.getCurrentMapType().getProjection().fromLatLngToPixel(T, z);var x = fV.x - fS.x;var y = fV.y - fS.y;if (Q.O == FM_POINT) {x += this.tooltipOffsetX;y += this.tooltipOffsetY;}var bm = new GControlPosition(G_ANCHOR_TOP_LEFT, new GSize(x, y));bm.apply(this.bQ);this.bQ.style.visibility = "visible";}};
    MCFM.prototype.bi = function () {this.bQ.style.visibility = "hidden";};
    MCFM.prototype.viewAll = function () {for (var i = 0; i < this.I.length; i++) {var g = this.I[i];g.H = true;if (g.aD < 0) {g.aD = 0;g.cq();}if (this.e("f" + i)) {this.e("f" + i).checked = true;}}this.cd();this.fu();this.fv();this.K();this.al();if (this.aW) {var C = this.aW;if (this.P && this.P.H && this.P.F) {C.extend(this.P.F.getSouthWest());C.extend(this.P.F.getNorthEast());}var L = C.getCenter();var R = this.map.getBoundsZoomLevel(this.aW);this.map.setCenter(L, R);}};
    MCFM.prototype.hH = function () {var dY = this.df - this.footerPadding * 2;var f = "<table id='footerTopDiv' cellpadding=0 cellspacing=0 style='width:" + dY + "px'><tr><td style='width:100%'>";f += "<div style='float:right'>" + this.linksHtml + "&nbsp;</div>";if (this.geocoder) {f += "<div id='geocoderDiv' style='float:left'>" + this.geocoderTitle + "&nbsp;<input id='geocoderAddress' type='text' style='width:" + this.geocoderWidth + "px;font-size:10px' onkeypress='return mcfm.geocoderKey(event)' /> " + "<input type='button' style='font-size:10px' value='" + this.txt_Go + "' onclick='mcfm.geocoderFind()' />&nbsp;&nbsp;<a id='geocoderClearLink'  style='display:none' href='javascript:mcfm.geocoderClear()'>" + this.txt_Clear + "</a>" + "</div>";}var A = this.aL;if (A && A.bs) {f += "</td></tr><tr><td style='padding-top:4px'>";f += "<div style='float:left'><b>" + A.iC + "</b> &nbsp;";f += "<input id='dfAny' type='checkbox' onclick='javascript:mcfm.dfCheckAny(this)' checked='true' /><a href='javascript:mcfm.dfClickAny()'  style='color:blue'>" + this.txt_Any + "</a> ";f += "</div>";for (var i = 0; i < A.bG.length; i++) {f += "<div style='float:left'><input id='d" + i + "' type='checkbox' onclick='javascript:mcfm.dfCheck(this)' />" + "<a href='javascript:mcfm.dfClick(" + i + ")' style='color:blue' >" + A.fQ[i] + "</a>&nbsp;&nbsp;</div>";}}var aH = this.aY;if (aH && aH.bs > 0) {f += "</td></tr><tr><td style='padding-top:4px'>";f += "<div style='float:left'><b>" + aH.D + "</b> &nbsp;&nbsp;";f += "<input id='mfAll' type='checkbox' checked='true' onclick='mcfm.mfCheckAll(this)' />" + "<a href='javascript:mcfm.mfClickAll()'>" + this.txt_All + "</a> &nbsp;</div>";for (var i = 0; i < aH.af.length; i++) {var V = aH.af[i];f += "<div style='float:left'><input id='mf" + i + "' type='checkbox' checked='true' onclick='mcfm.mfCheck(this)' />" + "<img src='" + V.gA + "' alt='' width='16' height='16' />" + "<a href='javascript:mcfm.mfClick(" + i + ")'>" + V.D + "</a>&nbsp;&nbsp;</div>";}}f += "</td></tr></table>";this.e("fmFooter").innerHTML = f;var fm = mcfm.e("fmNotice");var fl = mcfm.e("fmFooterNotice");if (fm) {fl.innerHTML = fm.innerHTML;fl.style.display = "inline";}};
    MCFM.prototype.ff = function (a) {var gp = this.e("fmSidebarCoords");if (gp) {var f = this.sidebarLatTitle + " <span style='color:darkred;font-weight:bold'>" + this.bA(a.lat(), 5) + "&deg;</span> &nbsp; " + this.sidebarLongTitle + " <span style='color:darkred;font-weight:bold'>" + this.bA(a.lng(), 5) + "&deg;</span>";gp.innerHTML = f;}};
    MCFM.prototype.geocoderClose = function (a) {this.e("geocoderDiv").style.display = "none";this.e("geocoderCheck").checked = false;if (this.ay) {this.ay.hide();}this.map.closeInfoWindow();};
    MCFM.prototype.ju = function () {this.ay = null;this.dz = "";var dW = this.e("geocoderDiv");if (dW) {var bm = new GControlPosition(G_ANCHOR_BOTTOM_RIGHT, new GSize(6, 22));bm.apply(dW);this.map.getContainer().appendChild(dW);}};
    MCFM.prototype.geocoderFind = function () {var eC = this.e("geocoderAddress").value;var dX = new GClientGeocoder(new GGeocodeCache);if (this.geocoderCountry.length > 0) {dX.setBaseCountryCode(this.geocoderCountry);}dX.getLatLng(eC, function (aG) {mcfm.map.closeInfoWindow();if (aG) {mcfm.dz = eC;mcfm.map.setCenter(aG, 12);if (mcfm.ay) {mcfm.ay.setPoint(aG);mcfm.ay.show();} else {mcfm.ay = new GMarker(aG);mcfm.map.addOverlay(mcfm.ay);GEvent.addListener(mcfm.ay, "click", function () {mcfm.ay.openInfoWindowHtml(mcfm.dz);});}mcfm.ay.openInfoWindowHtml(mcfm.dz);mcfm.e("geocoderClearLink").style.display = "inline";} else {var aP = dX.getCache().get(eC);var dO = "";if (aP) {var aQ = [];aQ[G_GEO_SUCCESS] = this.txt_G_GEO_SUCCESS;aQ[G_GEO_MISSING_ADDRESS] = this.txt_G_GEO_MISSING_ADDRESS;aQ[G_GEO_UNKNOWN_ADDRESS] = this.txt_G_GEO_UNKNOWN_ADDRESS;aQ[G_GEO_UNAVAILABLE_ADDRESS] = this.txt_G_GEO_UNAVAILABLE_ADDRESS;aQ[G_GEO_BAD_KEY] = this.txt_G_GEO_BAD_KEY;aQ[G_GEO_TOO_MANY_QUERIES] = this.txt_G_GEO_TOO_MANY_QUERIES;aQ[G_GEO_SERVER_ERROR] = this.txt_G_GEO_SERVER_ERROR;var dO = mcfm.txt_ErrorCode + " " + aP.Status.code + " : ";if (aQ[aP.Status.code]) {dO += aQ[aP.Status.code];}alert(dO);mcfm.e("geocoderAddress").focus();}}});};
    MCFM.prototype.geocoderKey = function (dj) {var el = dj.keyCode;if (el == 13) {this.geocoderFind();return false;}return true;};
    MCFM.prototype.hQ = function () {if (this.e("geocoderClearLink")) {this.e("geocoderClearLink").style.display = "none";}if (this.ay) {this.ay.hide();}};
    MCFM.prototype.geocoderClear = function () {this.hQ();this.map.closeInfoWindow();this.K();};
    MCFM.prototype.gO = function () {var bP = this.layoutWidth - this.sidebarWidth - this.headerPadding * 2 - 20;var f = "";if (this.headerRows > 1) {f += "<div id='headerDiv1' style='float:left;width:" + bP + "px' >";}f += "<div style='float:left; font-weight:bold; font-size:15px'>";f += this.mainFeedsTitle + " &nbsp;";if (this.I.length > 1) {f += "<a href='javascript:mcfm.feedClickAll()' >" + this.txt_All + "</a> &nbsp;" + "<a href='javascript:mcfm.feedClickNone()' >" + this.txt_None + "</a> &nbsp;";}f += "</div>";for (var i = 0; i < this.I.length; i++) {var g = this.I[i];var an = "";if (this.headerIcons > 0 && g.cU) {var r = g.aj;var wd = parseInt(r.iconSize.width / 2);var ht = parseInt(r.iconSize.height / 2);an = "<img src='" + r.iconUrl + "' alt='' width='" + wd + "' height='" + ht + "' border='0' /> ";}f += "<div style='float:left'><input id='f" + i + "' type='checkbox' onclick='mcfm.feedCheck(this)' " + ((g.aD >= 0 && g.H) ? "checked='true' " : "") + " />" + an + "<a href='javascript:mcfm.feedClick(" + i + ")'>" + g.D + "</a> &nbsp;</div>";}if (this.headerRows > 1) {f += "</div><div id='headerDiv2' style='float:left;width:" + bP + "px' ><span style='float:left;font-size:15px; font-weight:bold' >" + this.extraFeedsTitle + " &nbsp;</span>";}if (this.mapPanoramio) {var an = "";if (this.headerIcons > 0) {an = "<img src='http://www.panoramio.com/img/panoramio-marker.png' alt='' width='12' height='12' border='0' /> ";}f += "<div style='float:left'><input id='panoramioBox' type='checkbox' onclick='mcfm.panoramioCheck(this)' />" + an + "<a href='javascript:mcfm.panoramioClick()'>" + this.txt_Photos + "</a> &nbsp;</div>";}if (this.mapHotels) {var an = "";if (this.headerIcons > 0) {an = "<img src='http://maps.google.com/mapfiles/ms/micons/lodging.png' alt='' width='16' height='16' border='0' />";}f += "<div style='float:left'><input id='hotelsBox' type='checkbox' onclick='mcfm.hotelsCheck(this)' />" + an + "<a href='javascript:mcfm.hotelsClick()'> " + this.txt_Hotels + "</a> &nbsp;</div>";}if (this.mapStreetView) {var an = "";if (this.headerIcons > 0) {an = "<img src='http://maps.google.com/intl/en_us/mapfiles/cb/man_arrow-0.png' alt='' width='16' height='16' border='0' />";}f += "<div style='float:left'><input id='streetviewBox' type='checkbox' onclick='mcfm.streetviewCheck(this)' />" + an + this.txt_StreetView + " &nbsp;</div>";}if (this.mapTraffic) {var an = "";if (this.headerIcons > 0) {an = "<img src='http://maps.google.com/mapfiles/traffic.png' alt='' width='16' height='16' border='0' />";}f += "<div style='float:left'><input id='trafficBox' type='checkbox' onclick='mcfm.trafficCheck(this)' />" + an + this.txt_Traffic + " &nbsp;</div>";}if (this.headerRows > 1) {f += "</div>";}this.e("fmHeader").innerHTML = f;if (this.nameFilterOn) {this.e("fmNameFilter").innerHTML = "<div style='float:left; font-size:10px; width:" + this.sidebarWidth + "px'>" + this.nameFilterTitle + "  <input id='nameFilter' type='text' style='font-size:10px;width:" + this.nameFilterWidth + "px' onkeyup='mcfm.applyNameFilter()' /></div>";}};
    MCFM.prototype.cP = function () {var f = "";if (this.sidebarShow) {f = " <a href='javascript:mcfm.sidebarClick()'/>&laquo; " + this.txt_HideSidebar + "</a>";} else {f = " <a href='javascript:mcfm.sidebarClick()'/>" + this.txt_ShowSidebar + " &raquo;</a>";}this.e("fmFooterTitle").innerHTML = f;};
    MCFM.prototype.ir = function () {this.ic = this.mapHotels > 1 ? 140 : 80;var f = "<div id='hotelsDiv' style='padding:4px;display:none;background-color:white;border:solid 1px black;width:250px;height:" + this.ic + "px;overflow:hidden'></div>";return f;};
    MCFM.prototype.gH = function () {var dQ = this.e("hotelsDiv");if (dQ) {var x = 4;switch (mcfm.mapNavControl) {case 1:x = 48;break;case 2:x = 80;default:;}var bm = new GControlPosition(G_ANCHOR_TOP_LEFT, new GSize(x, 4));bm.apply(dQ);this.map.getContainer().appendChild(dQ);}};

    function FMHotel(a) {
        this.O = FM_POINT;
        this.ct = a.hotelid;
        this.D = a.hotelName;
        this.aU = this.D.toLowerCase();
        this.x = a.lon;
        this.y = a.lat;
        this.M = new GLatLng(this.y, this.x);
        this.bw = 0;
        this.dG = "";
        this.bx = 0;
        if (typeof a.hotelCurrency != "undefined") {
            this.dG = a.hotelCurrency;
        }
        if (typeof a.fromPrice != "undefined") {
            var fL = parseInt(a.fromPrice);
            if (fL > 0) {
                this.bx = fL;
            }
        }
        this.gC = a.hotelImage;
        this.iB = a.starRating;
        this.hZ = a.ratingSymbol;
        this.ah = "http://www.activehotels.com" + a.href;
        this.dr = mcfm.cX(this.D);
    }

    FMHotel.prototype.bZ = function () {var f = "<div id='h" + this.bw + "' style='cursor:pointer;width:" + mcfm.dw + "px;overflow:hidden;float:left' onmouseover='mcfm.hotelHi(this)' onmouseout='mcfm.hotelLo(this)' onclick='mcfm.hotelClick(this)'>";f += "<table cellspacing=0 cellpadding=2><tr valign=top><td>";f += "<img src='" + this.gC + "' alt='' />";f += "</td><td>";f += "<b>" + this.D + "</b> ";if (this.bx > 0) {f += "<br />" + mcfm.txt_From + " " + this.dG + "&nbsp;" + this.bx + "";}f += "</td></tr></table>";f += "</div></div>";return f;};
    FMHotel.prototype.bX = function () {var f = "";if (this.ah.length > 0) {f += "<a target='_blank' href=\"" + this.ah + "\" >" + this.D + "</a><br/>";} else {f += "<b>" + this.D + "</b><br/>";}return f;};

    function FMHotelFeed() {
        this.G = [];
        this.bC = [];
        this.F = null;
        this.H = false;
        this.eY = 0;
    }

    FMHotel.prototype.dC = function () {var f = "<table><tr><td><div style='float:left;width:68px; height:68px' alt='' >" + "<a href='" + this.ah + "' target='_blank' title='" + mcfm.txt_MoreInformation + "'><img src='" + this.gC + "' alt='' border=0 /></a></div>" + "<a href='" + this.ah + "' target='_blank' title='" + mcfm.txt_MoreInformation + "'>" + this.D + "</a><br />";if (this.bx > 0) {f += "From " + this.dG + " " + this.bx + "<br />";}f += this.iB + " " + this.hZ + "";f += "</td></tr><tr><td>Book through <a target='_blank' href='" + this.ah + "' title='" + mcfm.txt_MoreInformation + "'>Active Hotels</a></td></tr></table>";f += mcfm.dy(this);return f;};
    FMHotel.prototype.bf = function () {var ae = this;if (this.v) {this.v.show();} else {var B = new GIcon;B.image = "http://maps.google.com/mapfiles/ms/micons/lodging.png";B.iconSize = new GSize(32, 32);B.printImage = B.image;B.mozPrintImage = B.image;B.iconAnchor = new GPoint(16, 16);B.infoWindowAnchor = new GPoint(16, 0);this.v = new GMarker(this.M, {icon: B});mcfm.map.addOverlay(this.v);GEvent.addListener(this.v, "click", function () {mcfm.be(ae);});GEvent.addListener(this.v, "mouseover", function () {mcfm.bK(ae);});GEvent.addListener(this.v, "mouseout", function () {mcfm.bi();});}};
    FMHotelFeed.prototype.hide = function () {mcfm.map.closeInfoWindow();for (var i = 0; i < this.G.length; i++) {var o = this.G[i];o.v.hide();}};
    MCFM.prototype.hotelsCheck = function (a) {this.al();this.hotelShowOptions();this.P.H = a.checked;this.fk();};
    MCFM.prototype.hotelsClick = function (a) {for (var i = 0; i < this.I.length; i++) {var g = this.I[i];g.H = false;if (this.e("f" + i)) {this.e("f" + i).checked = false;}}this.cd();var ai = this.e("panoramioBox");if (ai) {ai.checked = false;this.panoramioCheck(ai);}var ag = this.e("hotelsBox");if (ag) {ag.checked = true;this.hotelsCheck(ag);}if (this.P.H && this.P.G.length > 0) {this.hotelViewAll();}};
    MCFM.prototype.hotelHi = function (a) {a.style.backgroundColor = "orange";var ix = parseInt(a.id.substr(1));var ae = this.P.G[ix];this.bK(ae);};
    MCFM.prototype.hotelLo = function (a) {a.style.backgroundColor = "white";this.bi();};
    MCFM.prototype.hotelClick = function (a) {var ix = parseInt(a.id.substr(1));var ae = this.P.G[ix];this.be(ae);};
    MCFM.prototype.hotelRefresh = function () {var g = this.P;for (var i = 0; i < g.G.length; i++) {var ae = g.G[i];mcfm.map.removeOverlay(ae.v);}g.G = [];g.bC = [];this.K();this.fk();};
    MCFM.prototype.hotelViewAll = function () {var C = this.P.F;if (C) {var L = C.getCenter();var R = this.map.getBoundsZoomLevel(C);this.map.setCenter(L, R);}};
    MCFM.prototype.hotelModeCheck = function (a) {this.e("hotelMode0").checked = a == 0;this.e("hotelMode1").checked = a == 1;this.e("dSelect").disabled = a == 0;this.e("mSelect").disabled = a == 0;this.e("nSelect").disabled = a == 0;this.e("rSelect").disabled = a == 0;this.cz = a == 0;};
    MCFM.prototype.hotelShowOptions = function (a) {if (this.e("hotelOptions0")) {this.e("hotelOptions0").style.display = a ? "block" : "none";}if (this.e("hotelOptions1")) {this.e("hotelOptions1").style.display = a ? "none" : "block";}if (this.e("hotelsDiv")) {this.e("hotelsDiv").style.display = a ? "block" : "none";}};
    MCFM.prototype.hotelSortBy = function (a) {this.P.eY = a;mcfm.e("hotelSort0").checked = a == 0;mcfm.e("hotelSort1").checked = a == 1;this.K();};
    MCFM.prototype.gJ = function () {this.P = new FMHotelFeed;this.il = [0, 31, 28, 31, 30, 31, 30, 31, 31, 30, 31, 30, 31];var ez = new Date;this.bz = ez.getDate();this.aN = ez.getMonth() + 1;this.aT = ez.getFullYear();this.cG = 1;this.dn = 1;this.gW = this.bz;this.gV = this.aN;this.gS = this.aT;this.cz = true;};
    MCFM.prototype.gR = function (bD, bR) {if (bD == 2 && ((bR % 4) == 0)) {return 29;} else {return this.il[bD];}};
    MCFM.prototype.jp = function () {var cA = true;var cZ = new Date;var gB = cZ.getDate();var ej = cZ.getMonth() + 1;var gz = cZ.getFullYear();if (this.aT < cZ.getFullYear()) {cA = false;} else if (this.aT == gz) {if (oTopS.aN < ej) {cA = false;} else if (this.aN == ej) {if (this.bz < gB) {cA = false;}}}if (!cA) {this.bz = gB;this.aN = ej;this.aT = gz;}};
    MCFM.prototype.gx = function (aB, dq, bD, bR) {var eu = this.gR(bD, bR);if (dq > eu) {dq = eu;}var fc = 0;if (bD == this.gV && bR == this.gS) {fc = this.gW - 1;}aB.options.length = 0;var ix = 0;for (var i = fc; i < eu; i++) {var aS = i + 1;var ak = dq == aS;var cu = aS.toString();var aR = new Option(cu, aS, ak, ak);aB.options[ix++] = aR;}};
    MCFM.prototype.hc = function (aB, bD, bR) {var gk = new Date;var ar = gk.getMonth();var bN = gk.getFullYear();var hD = 12;aB.options.length = 0;for (var i = 0; i < hD; i++) {var cu = this.txt_MonthNames[ar + 1] + " " + bN;var ak = (ar + 1) == bD && bN == bR;var hw = (bN * 100) + (ar + 1);var aR = new Option(cu, hw, ak, ak);aB.options[i] = aR;ar++;if (ar > 11) {ar = 0;bN++;}}};
    MCFM.prototype.gU = function (aB, hj) {aB.options.length = 0;for (var i = 0; i < 30; i++) {var ak = (i + 1) == hj;var aR = new Option((i + 1), (i + 1), ak, ak);aB.options[i] = aR;}};
    MCFM.prototype.iI = function (aB, hz) {aB.options.length = 0;for (var i = 0; i < 20; i++) {var ak = (i + 1) == hz;var aR = new Option((i + 1), (i + 1), ak, ak);aB.options[i] = aR;}};
    MCFM.prototype.hb = function () {this.gx(this.e("dSelect"), this.bz, this.aN, this.aT);this.hc(this.e("mSelect"), this.aN, this.aT);this.gU(this.e("nSelect"), this.cG);this.iI(this.e("rSelect"), this.dn);};
    MCFM.prototype.searchMonthChange = function () {var aS = this.e("dSelect").value;var au = this.e("mSelect").value;var ar = parseInt(au % 100);var bN = parseInt(au / 100);this.gx(this.e("dSelect"), aS, ar, bN);};
    MCFM.prototype.searchNow = function () {var aS = this.e("dSelect").value;var au = this.e("mSelect").value;var ei = this.e("nSelect").value;var dV = this.e("rSelect").value;this.bz = parseInt(aS);au = parseInt(au);this.aN = parseInt(au % 100);this.aT = parseInt(au / 100);this.cG = parseInt(ei);this.dn = parseInt(dV);};
    MCFM.prototype.fk = function () {this.e("hotelsDiv").style.display = this.P.H ? "block" : "none";var g = this.P;if (g.H) {if (g.G.length == 0) {var L = this.map.getCenter();var C = this.map.getBounds();var hG = C.getNorthEast();var iA = L.distanceFrom(hG) / 1000;var aF = "http://www.activehotels.com/wl/servlet/hoteladfeed?trkref=SWN&callback=mcfm.cbHotels";aF += "&centre=" + mcfm.bA(L.lng(), 6) + "^" + mcfm.bA(L.lat(), 6);aF += "&radius=" + mcfm.bA(iA, 3);if (this.e("hotelMode1") && this.e("hotelMode1").checked) {var aS = this.e("dSelect").value;var au = this.e("mSelect").value;var ei = this.e("nSelect").value;var dV = this.e("rSelect").value;this.bz = parseInt(aS);au = parseInt(au);this.aN = parseInt(au % 100);this.aT = parseInt(au / 100);this.cG = parseInt(ei);this.ji = parseInt(dV);var ar = this.aN;if (ar < 10) {ar = "0" + ar;}aF += "&day=" + this.bz + "&month=" + ar + "&year=" + this.aT + "&numnights=" + this.cG + "&numrooms=" + this.dn;}var bc = new FMJSON(aF, true);bc.dh();bc.dk();this.e("hotelsDiv").innerHTML = "<table cellspacing=2 cellpadding=2 style='width:100%'><tr style='color:white; background-color:darkred'><td>" + "<b>" + this.txt_PleaseWait + "</b>" + "</td></tr><tr><td>" + "<br />" + this.txt_FindingHotels + "</td></tr></table>";} else {for (var i = 0; i < g.G.length; i++) {var o = g.G[i];if (o.v) {o.v.show();}}}} else {for (var i = 0; i < g.G.length; i++) {var o = g.G[i];if (o.v) {o.v.hide();}}}this.K();};
    MCFM.prototype.iu = function (a) {var f = "";var fg = a.hotelCount == 1 ? this.txt_Hotel : this.txt_Hotels;if (this.mapHotels == 1) {f += "<table cellspacing=2 cellpadding=2 style='width:100%;'><tr style='color:white; background-color:darkred'><td style='width:100%'><b>";f += "<div style='float:right' >&nbsp;<a style='color:yellow' href='javascript:mcfm.hotelShowOptions(0)' >" + this.txt_Close + "</a></div>";f += "&nbsp; <a href='javascript:mcfm.hotelViewAll()' style='color:white' title='" + this.txt_ViewAll + "' >" + a.hotelCount + " " + fg + "</a>";f += "</td></tr></table>";f += "<table id='hotelOptions' cellspacing=4 cellpadding=0 style='width:100%;'><tr><td style='width:100%'>";f += "<input type='button' onclick='mcfm.hotelRefresh()' value='" + this.txt_Refresh + "' /> &nbsp;";f += this.txt_SortBy + " <input id='hotelSort0' type='checkbox' checked='true' onclick='mcfm.hotelSortBy(0)' /> " + this.txt_Name + " &nbsp;";f += "<input id='hotelSort1' type='checkbox' onclick='mcfm.hotelSortBy(1)' /> " + this.txt_Price;f += "</td></tr><tr style='font-size:11px'><td><i>";f += this.txt_ViewMore + " <a target=_blank href='http://hotels.mapchannels.com' >" + this.txt_MapChannelsHotels + "</a></i>";} else {f += "<table cellspacing=2 cellpadding=2 style='width:100%;'><tr style='color:white; background-color:darkred'><td style='width:100%'><b>";f += "<div style='float:right' >&nbsp;<a style='color:yellow' href='javascript:mcfm.hotelShowOptions(0)' >" + this.txt_Close + "</a></div>";f += a.hotelCount + " " + fg + " <b>";f += "&nbsp; <a href='javascript:mcfm.hotelViewAll()' style='color:white' >" + this.txt_ViewAll + "</a>";f += "</td></tr></table>";f += "<table id='hotelOptions' cellspacing=4 cellpadding=0 style='width:100%;'><tr><td style='width:100%'>";f += "Show <input id='hotelMode0' type='checkbox'" + (this.cz ? " checked='true' " : "") + " onclick='mcfm.hotelModeCheck(0)' /> " + this.txt_Any + " &nbsp; <input id='hotelMode1' type='checkbox' " + (this.cz ? "" : " checked='true' ") + " onclick='mcfm.hotelModeCheck(1)' /> " + this.txt_SelectedDate;f += "</td></tr></tr><td>";var cN = this.cz ? " disabled='true' " : "";f += "Date <select id='dSelect' style='width:40px' " + cN + " ></select> &nbsp; ";f += "<select id='mSelect' style='width:80px' " + cN + " onchange='mcfm.searchMonthChange()' ></select> &nbsp;";f += "</td></tr></tr><td>";f += " " + this.txt_Nights + " <select id='nSelect'  style='width:40px' " + cN + " ></select>";f += " " + this.txt_Rooms + " <select id='rSelect'  style='width:40px' " + cN + " ></select>";f += " &nbsp;<input type='button' onclick='mcfm.hotelRefresh()' value='" + this.txt_Update + "' /> ";f += "</td></tr></tr><td>";f += this.txt_SortBy + " <input id='hotelSort0' type='checkbox' checked='true' onclick='mcfm.hotelSortBy(0)' /> " + this.txt_Name + " &nbsp;";f += "<input id='hotelSort1' type='checkbox' onclick='mcfm.hotelSortBy(1)' /> " + this.txt_Price;f += "</td></tr><tr style='font-size:11px'><td><i>";f += this.txt_ViewMore + " <a target=_blank href='http://hotels.mapchannels.com' >" + this.txt_MapChannelsHotels + "</a></i>";}return f;};
    MCFM.prototype.cbHotels = function (a) {var f = this.iu(a);this.e("hotelsDiv").innerHTML = f;if (this.mapHotels > 1) {this.hb();}this.P.F = null;if (this.P.H) {var R = this.map.getZoom();for (var i = 0; i < a.hotels.length; i++) {var cj = a.hotels[i];this.P.gK(cj, R);}this.hotelViewAll();}this.K();};
    FMHotelFeed.prototype.gK = function (ap, bp) {var ae = new FMHotel(ap, bp);var bE = this.bC[ae.ct];if (bE == null) {this.G.push(ae);this.bC[ae.ct] = ae;if (this.F == null) {this.F = new GLatLngBounds(ae.M);} else {this.F.extend(ae.M);}ae.bf();}};

    function FMJSON(hB, hi) {
        this.hS = hB;
        this.fW = document.getElementsByTagName("head").item(0);
        this.ik = hi == true ? true : false;
        this.iw = "&noCacheIE=" + (new Date).getTime();
    }

    FMJSON.prototype.dh = function () {this.cg = document.createElement("script");this.cg.setAttribute("type", "text/javascript");this.cg.setAttribute("charset", "utf-8");var aF = this.hS;if (this.ik) {aF += this.iw;}this.cg.setAttribute("src", aF);};
    FMJSON.prototype.jo = function () {this.fW.removeChild(this.cg);};
    FMJSON.prototype.dk = function () {this.fW.appendChild(this.cg);};
    MCFM.prototype.fi = function (a) {if (this.db) {var L = this.map.getCenter();var gL = this.map.getZoom();Lat49.updateAdByLatLon("adcontainer", L.lat(), L.lng(), gL);}};
    MCFM.prototype.hA = function () {this.ga();var iy = this.e(this.layoutContainer);var ij = this.sidebarShow ? this.layoutWidth - this.sidebarWidth : this.layoutWidth;var gq = this.sidebarShow ? "" : ";display:none";var he = (this.sidebarShow && this.sidebarOptions) ? "" : ";display:none";var hx = this.visFilter ? "checked='true' " : "";var f = "<table id='mainTable' cellspacing='0' cellpadding='0' style='text-align:left;width:100%;color:black;background-color:white;'><tr valign='top' style='height:" + (this.headerHeight - this.headerPadding * 2) + "px'><td style='width:" + this.sidebarWidth + "px'>" + "<div id='fmNameFilter' style='float:left;padding:" + this.headerPadding + "px'></div>" + "</td><td>" + "<div id='fmHeader' style='padding:" + this.headerPadding + "px'></div>" + "</td></tr></table>" + "<table cellspacing='0' cellpadding='0' style='width:100%'><tr valign='top'><td style='width:" + this.sidebarWidth + "px'>" + "<div id='fmSidebarTitle' style='padding:2px;background-color:gainsboro;width:" + (this.sidebarWidth - 5) + "px;height:15px;border-top:solid 1px black;border-right:solid 1px black" + gq + "' valign='middle'></div>" + "<div id='fmPaging' style='padding:2px;background-color:gainsboro;width:" + (this.sidebarWidth - 5) + "px;height:18px;border-right:solid 1px black;display:none' valign='middle'>" + "<span id='pageTitle' style='float:right'></span>&nbsp;Page <select id='pageSelect' onchange='mcfm.pageSelect(this)' style='font-size:10px'></select> &nbsp; <a id='pagePrev' href='javascript:mcfm.pagePrev()'>&lt;&lt;</a> &nbsp; <a id='pageNext' href='javascript:mcfm.pageNext()'>&gt;&gt;</a> &nbsp;" + "</div>" + "\r\n\r\n<div id='fmSidebar' style='width:" + (this.sidebarWidth - 1) + "px;overflow:auto;height:" + this.bh + "px;border-top:solid 1px black;border-right:solid 1px black;border-bottom:solid 1px black" + gq + "'>" + "<div id='fmDirections'></div>" + "<div id='fmIndex'>&nbsp;" + this.txt_Loading + "</div>" + "</div>\r\n\r\n";f += "<div id='fmSidebarOptions' style='padding:2px;width:" + (this.sidebarWidth - 5) + "px;height:" + this.optionsHeight + "px;border-bottom:solid 1px black;border-right:solid 1px black" + he + "'>" + "<input type='checkbox' onclick='mcfm.visClick(this)' " + hx + " /> " + this.visFilterTitle;if (mcfm.mapCoords) {f += "<div id='fmSidebarCoords' style='padding-top:2px' title='" + this.txt_MapCursorCoordinates + "'></div>";}var fn = this.e("fmOptions");if (fn) {f += "<div>" + fn.innerHTML + "</div>";}f += "</div>\r\n\r\n</td><td>" + "<div id='fmMap' style='width:" + ij + "px; height:" + (this.cK - 2) + "px; border-top:solid 1px black;border-bottom:solid 1px black'></div>";if (this.db) {var es = this.sidebarShow ? this.sidebarWidth + 4 : 4;ih = "<div id='adcontainer' lat49adposition='bottom-left' style='position:absolute;left:" + es + "px;bottom:" + (this.footerHeight + 40) + "px;z-index:100000'></div>";f += ih;}f += "</td></tr></table>";f += "<table cellspacing='0' cellpadding='0' style='text-align:left;width:100%'><tr valign='top'><td style='width:" + this.sidebarWidth + "px'>" + "<div id='fmFooterTitle' style='padding:" + this.footerPadding + "px'></div>" + "<div id='fmFooterNotice' style='display:none;padding:" + this.footerPadding + "px'></div>" + "</td><td>" + "<div id='fmFooter' style='padding:" + this.footerPadding + "px'></div>" + "</td></tr></table>";f += this.ir();f += this.iz();iy.innerHTML = f;this.cP();};
    MCFM.prototype.ga = function () {if (this.co == 2) {this.layoutWidth = parseInt(document.documentElement.clientWidth);this.layoutHeight = parseInt(document.documentElement.clientHeight);} else {this.layoutWidth = parseInt(window.innerWidth);this.layoutHeight = parseInt(window.innerHeight);}this.df = this.layoutWidth - this.sidebarWidth;this.iq = this.sidebarShow ? this.layoutWidth - this.sidebarWidth : this.layoutWidth;this.cK = this.layoutHeight - this.footerHeight - this.headerHeight;this.bh = this.cK - this.fD;if (this.bV) {this.bh -= this.fC;}if (this.sidebarOptions) {this.bh -= (this.optionsHeight + 5);}};
    MCFM.prototype.ia = function () {this.bh = this.cK - this.fD;if (this.bV) {this.bh -= this.fC;}if (this.sidebarOptions) {this.bh -= (this.optionsHeight + 5);}var cv = this.e("fmSidebar");if (cv) {cv.style.height = this.bh + "px";}this.e("fmPaging").style.display = (this.bV && this.sidebarShow) ? "block" : "none";};
    MCFM.prototype.ib = function () {this.ga();var eZ = this.e("mainTable");var cv = this.e("fmSidebar");var ed = this.e("fmMap");var fo = this.e("footerTopDiv");var fr = this.e("headerDiv1");var fq = this.e("headerDiv2");if (eZ) {eZ.style.width = this.layoutWidth + "px";}if (cv) {cv.style.height = this.bh + "px";}if (ed) {ed.style.width = this.iq + "px";ed.style.height = (this.cK - 2) + "px";}if (fo) {var dY = this.df - this.footerPadding * 2;fo.style.width = dY + "px";}if (fr) {var bP = this.df - this.headerPadding * 2 - 20;fr.style.width = bP + "px";}if (fq) {var bP = this.df - this.headerPadding * 2 - 20;fq.style.width = bP + "px";}if (this.map) {this.map.checkResize();}};

    function MCFM() {
        this.map = null;
        this.I = [];
        this.aC = [];
        this.layoutContainer = "fmMain";
        this.layoutWidth = "500px";
        this.layoutHeight = "300px";
        this.sidebarWidth = 300;
        this.headerHeight = 30;
        this.footerHeight = 30;
        this.headerPadding = 2;
        this.footerPadding = 2;
        this.optionsHeight = 22;
        this.headerRows = 1;
        this.headerIcons = 0;
        this.mainFeedsTitle = "";
        this.extraFeedsTitle = "";
        this.mapNavControl = 2;
        this.mapTypeControl = 3;
        this.mapScaleControl = 1;
        this.mapCursor = 0;
        this.mapType = 0;
        this.mapBounds = [];
        this.mapOverviewMap = 0;
        this.mapScrollZoom = 0;
        this.mapDoubleClickZoom = 1;
        this.mapContinuousZoom = false;
        this.mapTerrain = 1;
        this.mapGoogleEarth = 0;
        this.mapStreetView = 0;
        this.mapTraffic = 0;
        this.mapGoogleBar = 0;
        this.mapCoords = 0;
        this.mapPanoramio = 1;
        this.mapHotels = 1;
        this.geocoder = 1;
        this.geocoderTitle = "";
        this.geocoderWidth = 120;
        this.geocoderCountry = "";
        this.infoIcon = 1;
        this.infoWidth = 0;
        this.infoHeight = 0;
        this.infoLatLong = 0;
        this.infoDirections = 0;
        this.infoZoom = 0;
        this.infoMagnify = 0;
        this.infoMagnifyMapType = -1;
        this.infoSpace = 0;
        this.infoStreetView = 0;
        this.infoTargetFrame = "_blank";
        this.sidebarShow = 1;
        this.sidebarIcon = 1;
        this.sidebarDescription = 0;
        this.sidebarLatTitle = "Latitude";
        this.sidebarLongTitle = "Longitude";
        this.sidebarViewAll = 0;
        this.sidebarOptions = 1;
        this.visFilter = 1;
        this.visFilterTitle = "Only Visible Locations";
        this.pagingEnabled = true;
        this.pageSize = 200;
        this.pageDetail = 1;
        this.nameFilterOn = 1;
        this.nameFilterTitle = "";
        this.nameFilterWidth = 50;
        this.tooltipOffsetX = 12;
        this.tooltipOffsetY = 0;
        this.streetviewWidth = 440;
        this.streetviewHeight = 220;
        this.linksHtml = "Free Mapping Tools from <a target='_blank' href='http://www.mapchannels.com'>Map Channels</a>";
        this.myMapsMarkers = 1;
        this.scrollbarWidth = 18;
        this.aW = null;
        this.fN = 0;
        this.aZ = "";
        this.aY = new FMMarkerFilterManager;
        this.aL = new FMDescriptionFilterManager;
        this.aO = null;
        this.cl = null;
        this.ci = null;
        this.bI = false;
        this.ax = null;
        this.bH = null;
        this.bL = "";
        this.aA = null;
        this.az = null;
        this.heading = 0;
        this.jr = null;
        this.ds = null;
        this.cE = null;
        this.bV = false;
        this.aE = 1;
        this.bq = 1;
        this.fD = 22;
        this.fC = 22;
        this.dH = false;
        this.cx = false;
        this.db = false;
        if (typeof Lat49 != "undefined") {
            this.db = true;
        }
        this.gG();
    }

    MCFM.prototype.iR = function () {this.nameFilterTitle = this.txt_Name;this.geocoderTitle = this.txt_FindAddress;};

    function MCFMloadPage() {
        mcfm.setLanguageTable();
        mcfm.iR();
        mcfm.iF();
        if (typeof "MCFMinit" != "undefined") {
            MCFMinit();
        }
        mcfm.hA();
        if (mcfm.myMapsMarkers) {
            mcfm.gY();
        }
        if (mcfm.mapBounds.length >= 4) {
            mcfm.eK();
        }
        mcfm.hy();
    }


    function MCFMunloadPage() {
        if (typeof "GUnload" != "undefined") {
            GUnload();
        }
        if (mcfm.az) {
            mcfm.az.remove();
            mcfm.az = null;
        }
    }


    function MCFMresizePage() {
        mcfm.ib();
    }

    MCFM.prototype.fJ = function () {this.iJ();if (this.mapBounds.length < 4) {this.eK();}if (this.cE) {this.cE.gc();this.cE = null;}this.K();this.gO();this.hH();};
    MCFM.prototype.eK = function () {this.im = [G_NORMAL_MAP, G_SATELLITE_MAP, G_HYBRID_MAP, G_PHYSICAL_MAP, G_SATELLITE_3D_MAP];var cH = this.e("fmMap");var C = new GLatLngBounds;if (this.mapBounds.length >= 4) {C.extend(new GLatLng(this.mapBounds[1], this.mapBounds[0]));C.extend(new GLatLng(this.mapBounds[3], this.mapBounds[2]));}for (var i = 0; i < this.I.length; i++) {g = this.I[i];if (g.O != FM_GEOXML) {var ev = g.F;if (ev) {C.extend(ev.getSouthWest());C.extend(ev.getNorthEast());}}}this.aW = C;this.mapBounds = [1, 1, 1, 1];var aa = {};if (this.mapCursor) {aa = {draggableCursor: "crosshair"};}var map = new GMap2(cH, aa);this.map = map;this.ge = null;switch (this.mapNavControl) {case 1:map.addControl(new GSmallMapControl);break;case 2:map.addControl(new GLargeMapControl);break;default:;}switch (this.mapTypeControl) {case 1:map.addControl(new GMapTypeControl);break;case 2:map.addControl(new GHierarchicalMapTypeControl);break;case 3:map.addControl(new GMenuMapTypeControl);break;default:;}if (this.mapScaleControl) {map.addControl(new GScaleControl);}if (this.mapTerrain || this.mapType == 3) {map.addMapType(G_PHYSICAL_MAP);}if (this.mapGoogleEarth || this.mapType == 4) {map.addMapType(G_SATELLITE_3D_MAP);map.getEarthInstance(mcfm.getEarthInstanceCB);this.ge = null;}if (this.mapDoubleClickZoom) {map.enableDoubleClickZoom();}if (this.mapContinuousZoom) {map.enableContinuousZoom();}if (this.mapScrollZoom) {map.enableScrollWheelZoom();}if (this.mapGoogleBar) {map.enableGoogleBar();}if (this.mapOverviewMap) {this.map.addControl(new GOverviewMapControl);}this.bQ = document.createElement("toolDiv");map.getPane(G_MAP_FLOAT_PANE).appendChild(this.bQ);this.bQ.style.visibility = "hidden";if (this.mapHotels) {this.gH();}if (this.mapPanoramio) {this.gT();}var R = map.getBoundsZoomLevel(C);var L = C.getCenter();map.setCenter(L, R);var ip = this.im[this.mapType];map.setMapType(ip);if (this.googleMapAds) {var aa = {channel: this.adsenseChannel, maxAdsOnMap: this.adsenseMarkerLimit, minZoomLevel: this.adsenseMinZoom};var U = new GAdsManager(map, this.adsenseID, aa);U.enable();}if (this.db) {var iH = "http://www.mapchannels.com/iepngfix.htc";Lat49.initAds(this.lat49ID, iH);}map.checkResize();if (mcfm.mapCoords) {if (mcfm.sidebarOptions) {GEvent.addListener(map, "mousemove", function (a) {mcfm.ff(a);});}}GEvent.addListener(map, "moveend", function (a) {if (mcfm.av && mcfm.av.H) {mcfm.ft();}if (mcfm.visFilter) {mcfm.K();}mcfm.fi();});GEvent.addListener(map, "infowindowbeforeclose", function () {if (mcfm.az) {var bg = mcfm.e("panDiv");mcfm.az.remove();mcfm.az = null;}});GEvent.addListener(map, "infowindowopen", function () {if (mcfm.dH) {mcfm.dH = false;mcfm.dsiw2();} else if (mcfm.cx) {mcfm.cx = false;FMplacePanorama();}});if (mcfm.mapCoords) {mcfm.ff(map.getCenter());}mcfm.fi();};
    MCFM.prototype.getEarthInstanceCB = function (object) {mcfm.ge = object;};

    function FMMarkerFilter(aI, ck) {
        this.D = aI;
        this.gA = ck;
        this.by = true;
    }


    function FMMarkerFilterManager() {
        this.D = false;
        this.bs = false;
        this.iY = true;
        this.iS = false;
        this.af = [];
        this.fM = [];
    }

    MCFM.prototype.initMarkerFilters = function (aI) {var U = this.aY;U.D = aI;};
    MCFM.prototype.addMarkerFilter = function (aI, ck) {var V = new FMMarkerFilter(aI, ck);var U = this.aY;U.bs = true;U.af.push(V);U.fM[V.gA] = V;};
    MCFM.prototype.mfClick = function (ix) {var U = this.aY;for (var i = 0; i < U.af.length; i++) {V = U.af[i];V.by = ix == i;this.e("mf" + i).checked = V.by;}this.e("mfAll").checked = false;this.K();this.al();};
    MCFM.prototype.mfCheck = function (a) {var U = this.aY;var ix = parseInt(a.id.substr(2));V = U.af[ix];V.by = a.checked;var eE = 0;for (var i = 0; i < U.af.length; i++) {if (this.e("mf" + i).checked) {eE++;}}this.e("mfAll").checked = U.af.length == eE;this.K();this.al();};
    MCFM.prototype.mfClickAll = function (a) {this.fv();this.K();};
    MCFM.prototype.mfCheckAll = function (a) {var U = this.aY;for (var i = 0; i < U.af.length; i++) {V = U.af[i];V.by = a.checked;this.e("mf" + i).checked = a.checked;}this.K();this.al();};
    MCFM.prototype.fv = function () {var U = this.aY;if (U.bs) {for (var i = 0; i < U.af.length; i++) {V = U.af[i];V.by = true;this.e("mf" + i).checked = true;}this.e("mfAll").checked = true;}};
    MCFM.prototype.gY = function () {this.eW = [["blue-dot", "msmarker.shadow.png", 16, 31], ["red-dot", "msmarker.shadow.png", 16, 31], ["green-dot", "msmarker.shadow.png", 16, 31], ["ltblue-dot", "msmarker.shadow.png", 16, 31], ["yellow-dot", "msmarker.shadow.png", 16, 31], ["purple-dot", "msmarker.shadow.png", 16, 31], ["pink-dot", "msmarker.shadow.png", 16, 31], ["blue", "msmarker.shadow.png", 16, 31], ["red", "msmarker.shadow.png", 16, 31], ["green", "msmarker.shadow.png", 16, 31], ["lightblue", "msmarker.shadow.png", 16, 31], ["yellow", "msmarker.shadow.png", 16, 31], ["purple", "msmarker.shadow.png", 16, 31], ["pink", "msmarker.shadow.png", 16, 31], ["ylw-circle_maps", "msmarker.shadow.png", 16, 31], ["grn-circle_maps", "msmarker.shadow.png", 16, 31], ["ltblu-circle_maps", "msmarker.shadow.png", 16, 31], ["red-circle_maps", "msmarker.shadow.png", 16, 31], ["pink-circle_maps", "msmarker.shadow.png", 16, 31], ["blue-pushpin", "msmarker.shadow.png", 10, 30], ["red-pushpin", "msmarker.shadow.png", 10, 30], ["grn-pushpin", "msmarker.shadow.png", 10, 30], ["ltblu-pushpin", "msmarker.shadow.png", 10, 30], ["ylw-pushpin", "msmarker.shadow.png", 10, 30], ["purple-pushpin", "msmarker.shadow.png", 10, 30], ["pink-pushpin", "msmarker.shadow.png", 10, 30], ["restaurant", "restaurant.shadow.png", 16, 16], ["coffeehouse", "coffeehouse.shadow.png", 16, 16], ["bar", "bar.shadow.png", 16, 16], ["snack_bar", "snack_bar.shadow.png", 16, 16], ["man", "man.shadow.png", 16, 16], ["woman", "woman.shadow.png", 16, 16], ["wheel_chair_accessible", "wheel_chair_accessible.shadow.png", 16, 16], ["parkinglot", "parkinglot.shadow.png", 16, 16], ["cabs", "cabs.shadow.png", 16, 16], ["bus", "bus.shadow.png", 16, 16], ["truck", "truck.shadow.png", 16, 16], ["rail", "rail.shadow.png", 16, 16], ["plane", "plane.shadow.png", 16, 16], ["ferry", "ferry.shadow.png", 16, 16], ["helicopter", "helicopter.shadow.png", 16, 16], ["subway", "subway.shadow.png", 16, 16], ["tram", "tram.shadow.png", 16, 16], ["info", "info.shadow.png", 16, 16], ["info_circle", "info_circle.shadow.png", 16, 16], ["flag", "flag.shadow.png", 11, 29], ["rainy", "rainy.shadow.png", 16, 16], ["water", "water.shadow.png", 16, 16], ["snowflake_simple", "snowflake_simple.shadow.png", 16, 16], ["marina", "marina.shadow.png", 16, 16], ["fishing", "fishing.shadow.png", 16, 16], ["sailing", "sailing.shadow.png", 16, 16], ["swimming", "swimming.shadow.png", 16, 16], ["ski", "ski.shadow.png", 16, 16], ["tree", "tree.shadow.png", 16, 16], ["campfire", "campfire.shadow.png", 16, 16], ["picnic", "picnic.shadow.png", 16, 16], ["campground", "campground.shadow.png", 16, 16], ["rangerstation", "rangerstation.shadow.png", 16, 16], ["toilets", "toilets.shadow.png", 16, 16], ["poi", "POI.shadow.png", 25, 24], ["hiker", "hiker.shadow.png", 16, 16], ["cycling", "cycling.shadow.png", 16, 16], ["motorcycling", "motorcycling.shadow.png", 16, 16], ["horsebackriding", "horsebackriding.shadow.png", 16, 16], ["sportvenue", "sportvenue.shadow.png", 16, 16], ["golfer", "golfer.shadow.png", 16, 16], ["trail", "trail.shadow.png", 16, 16], ["shopping", "shopping.shadow.png", 16, 16], ["movies", "movies.shadow.png", 16, 16], ["grocerystore", "grocerystore.shadow.png", 16, 16], ["convienancestore", "convienancestore.shadow.png", 16, 16], ["arts", "arts.shadow.png", 16, 16], ["homegardenbusiness", "homegardenbusiness.shadow.png", 16, 31], ["electronics", "electronics.shadow.png", 16, 16], ["mechanic", "mechanic.shadow.png", 16, 16], ["gas", "gas.shadow.png", 16, 16], ["realestate", "realestate.shadow.png", 16, 16], ["salon", "salon.shadow.png", 16, 16], ["dollar", "dollar.shadow.png", 16, 16], ["euro", "euro.shadow.png", 16, 16], ["yen", "yen.shadow.png", 16, 16], ["firedept", "firedept.shadow.png", 16, 16], ["hospitals", "hospitals.shadow.png", 16, 16], ["lodging", "lodging.shadow.png", 16, 16], ["phone", "phone.shadow.png", 16, 16], ["caution", "caution.shadow.png", 16, 16], ["earthquake", "earthquake.shadow.png", 16, 16], ["fallingrocks", "fallingrocks.shadow.png", 16, 16], ["postoffice-us", "postoffice-us.shadow.png", 16, 16], ["police", "police.shadow.png", 16, 16], ["sunny", "sunny.shadow.png", 16, 16], ["partly_cloudy", "partly_cloudy.shadow.png", 16, 16], ["volcano", "volcano.shadow.png", 16, 16], ["camera", "camera.shadow.png", 16, 16], ["webcam", "webcam.shadow.png", 16, 16]];this.fb = [];for (var i = 0; i < this.eW.length; i++) {var eV = this.eW[i];var cu = eV[0];this.fb[cu] = eV;}};
    MCFM.prototype.ie = function (dE) {var gr = dE.iconUrl.toLowerCase();var bF = "";for (var i = 0; i < gr.length; i++) {var c = gr.substr(i, 1);if (c == "/") {bF = "";} else {bF += c;}}var fZ = bF.indexOf(".png");if (fZ > -1) {bF = bF.substr(0, fZ);}var B = this.fb[bF];if (B) {dE.shadowUrl = "http://maps.google.com/mapfiles/ms/micons/" + B[1];dE.iconAnchor = new GPoint(B[2], B[3]);} else {}};
    MCFM.prototype.cd = function () {var fI = this.e("nameFilter");if (fI) {fI.value = "";}this.aZ = "";};
    MCFM.prototype.applyNameFilter = function (a) {this.map.closeInfoWindow();this.aZ = this.e("nameFilter").value.toLowerCase();this.K();};
    MCFM.prototype.iz = function () {var f = "<div id='panLoadDiv' style='padding:4px;display:none;color:dodgerblue;background-color:white;border:solid 1px black;width:84px;height:12px'>&nbsp;<img src='http://www.panoramio.com/img/panoramio-marker.png' width='12' height='12' alt='' border=0 /> " + this.txt_Loading + "</div>";return f;};
    MCFM.prototype.gT = function () {var eq = this.e("panLoadDiv");if (eq) {var bm = new GControlPosition(G_ANCHOR_TOP_RIGHT, new GSize(8, 36));bm.apply(eq);this.map.getContainer().appendChild(eq);}};
    MCFM.prototype.gZ = function () {this.av = new FMPanoramioFeed;};
    MCFM.prototype.ft = function () {var g = this.av;g.bb = [];if (g.H) {var C = this.map.getBounds();var R = this.map.getZoom();for (var i = 0; i < g.G.length; i++) {var J = g.G[i];if (C.contains(J.M) && R >= J.cY) {g.bb.push(J);J.v.show();} else {J.v.hide();}}var ne = C.getNorthEast();var sw = C.getSouthWest();var aF = "http://www.panoramio.com/map/get_panoramas.php?order=popularity&set=public&from=0&to=50" + "&minx=" + sw.lng() + "&miny=" + sw.lat() + "&maxx=" + ne.lng() + "&maxy=" + ne.lat() + "&size=small&callback=mcfm.cbPanoramio";var bc = new FMJSON(aF, true);bc.dh();bc.dk();if (this.e("panLoadDiv")) {this.e("panLoadDiv").style.display = "block";}} else {g.hide();}this.K();};
    MCFM.prototype.panoramioCheck = function (a) {this.al();this.av.H = a.checked;this.ft();};
    MCFM.prototype.panoramioClick = function (a) {for (var i = 0; i < this.I.length; i++) {var g = this.I[i];g.H = false;if (this.e("f" + i)) {this.e("f" + i).checked = false;}}this.cd();var ag = this.e("hotelsBox");if (ag) {ag.checked = false;this.hotelsCheck(ag);}var ai = this.e("panoramioBox");if (ai) {ai.checked = true;this.panoramioCheck(ai);}};

    function FMPanoramio(a, bp) {
        this.O = FM_POINT;
        this.ct = "pan" + a.photo_id;
        this.D = a.photo_title;
        if (this.D == "") {
            this.D = "Untitled";
        }
        this.aU = this.D.toLowerCase();
        this.js = a.upload_date;
        this.x = a.longitude;
        this.y = a.latitude;
        this.M = new GLatLng(this.y, this.x);
        this.cY = bp;
        this.bw = 0;
        var is = a.photo_file_url;
        this.ah = a.photo_url;
        this.ac = "<div>" + "<a target='_blank' href='" + a.photo_url + "'><img src='" + is + "' alt='' border='0' width='" + a.width + "' height='" + a.height + "' title='" + mcfm.txt_ViewThisImage + "' /></a></div>" + "<div style='font-size:11px'>" + "<a target='_blank' href='" + a.owner_url + "'>" + a.owner_name + "</a> " + a.upload_date + "<div style='color:gray;font-size:10px'>" + mcfm.txt_PhotosProvided + ".</div>";
        this.dr = mcfm.cX(this.D);
    }

    FMPanoramio.prototype.dC = function () {var f = "<b>" + this.D + "</b><br />" + this.ac;f += mcfm.dy(this);return f;};
    FMPanoramio.prototype.bX = function () {var f = "";if (this.ah.length > 0) {f += "<a target='_blank' href=\"" + this.ah + "\" >" + this.D + "</a><br/>";} else {f += "<b>" + this.D + "</b><br/>";}return f;};
    FMPanoramio.prototype.bZ = function () {var f = "<div id='p" + this.bw + "' style='cursor:pointer;width:" + mcfm.dw + "px;overflow:hidden;float:left' onmouseover='mcfm.panHi(this)' onmouseout='mcfm.panLo(this)' onclick='mcfm.panClick(this)'>" + "<img src='http://www.panoramio.com/img/panoramio-marker.png' width='12' height='12' alt='' />" + " &nbsp; " + this.D + "</div>";return f;};

    function FMPanoramioFeed() {
        this.G = [];
        this.bC = [];
        this.bb = [];
        this.F = null;
        this.H = false;
    }

    FMPanoramioFeed.prototype.gN = function (ap, bp) {var J = new FMPanoramio(ap, bp);var bE = this.bC[J.ct];if (bE == null) {this.G.push(J);this.bC[J.ct] = J;J.bf();} else {if (bp < bE.cY) {bE.cY = bp;}bE.v.show();}};
    FMPanoramio.prototype.bf = function () {var J = this;var B = new GIcon;B.image = "http://www.panoramio.com/img/panoramio-marker.png";B.shadow = "http://www.panoramio.com/img/panoramio-shadow.png";B.iconSize = new GSize(18, 18);B.shadowSize = new GSize(22, 22);B.iconAnchor = new GPoint(9, 9);B.infoWindowAnchor = new GPoint(9, 0);this.v = new GMarker(this.M, {icon: B});mcfm.map.addOverlay(this.v);GEvent.addListener(this.v, "click", function () {mcfm.be(J);});GEvent.addListener(this.v, "mouseover", function () {mcfm.bK(J);});GEvent.addListener(this.v, "mouseout", function () {mcfm.bi();});};
    FMPanoramioFeed.prototype.hide = function () {mcfm.map.closeInfoWindow();for (var i = 0; i < this.G.length; i++) {var o = this.G[i];o.v.hide();}this.bb = [];};
    MCFM.prototype.cbPanoramio = function (a) {if (this.e("panLoadDiv")) {this.e("panLoadDiv").style.display = "none";}var g = this.av;g.bb = [];if (g.H) {var R = this.map.getZoom();for (var i = 0; i < a.photos.length; i++) {var cj = a.photos[i];g.gN(cj, R);}var C = this.map.getBounds();var R = this.map.getZoom();for (var i = 0; i < g.G.length; i++) {var J = g.G[i];if (C.contains(J.M) && R >= J.cY) {g.bb.push(J);J.v.show();} else {J.v.hide();}}}this.K();};
    MCFM.prototype.panHi = function (a) {a.style.backgroundColor = "lightskyblue";var ix = parseInt(a.id.substr(1));var J = this.av.bb[ix];this.bK(J);};
    MCFM.prototype.panLo = function (a) {a.style.backgroundColor = "white";this.bi();};
    MCFM.prototype.panClick = function (a) {var ix = parseInt(a.id.substr(1));var J = this.av.bb[ix];this.be(J);};

    function FMPlace(ao) {
        this.bv = null;
        this.bt = null;
        this.M = null;
        this.as = [];
        this.F = null;
        this.D = "";
        this.aU = "";
        this.ac = "";
        this.dx = "";
        this.cb = null;
        this.dM = null;
        this.dL = null;
        this.fP = [];
        this.ah = "";
        this.jt = "";
        this.aj = new FMStyle;
        this.type = 0;
        this.H = false;
        this.du = ao;
        this.v = null;
        this.fF = "";
    }

    FMPlace.prototype.bf = function () {var o = this;var r = o.aj;if (o.v) {o.v.show();return;}switch (this.O) {case FM_POINT:var B = new GIcon;B.image = r.iconUrl;B.iconSize = r.iconSize;B.printImage = r.iconUrl;B.mozPrintImage = r.iconUrl;B.iconAnchor = r.iconAnchor;B.infoWindowAnchor = r.infoAnchor;if (r.shadowUrl.length > 0) {B.shadow = r.shadowUrl;B.shadowSize = r.shadowSize;}this.v = new GMarker(this.M, {icon: B});break;case FM_POLYLINE:this.v = new GPolyline(this.as, r.lineCol, r.lineWidth, r.lineOpacity);break;case FM_POLYGON:this.v = new GPolygon(this.as, r.lineCol, r.lineWidth, r.lineOpacity, r.polyCol, r.polyOpacity);break;default:;}if (this.v) {mcfm.map.addOverlay(this.v);switch (this.O) {case FM_POINT:GEvent.addListener(this.v, "click", function () {mcfm.be(o);});GEvent.addListener(this.v, "mouseover", function () {mcfm.bK(o);});GEvent.addListener(this.v, "mouseout", function () {mcfm.bi();});break;case FM_POLYLINE:case FM_POLYGON:GEvent.addListener(this.v, "click", function (T) {mcfm.be(o, T);});break;default:;}}};
    MCFM.prototype.dy = function (Q) {var f = "";if (this.infoSpace) {f += "<div style='height:" + this.infoSpace + "px'></div>";}if (this.infoLatLong) {var T = Q.M;f += this.sidebarLatTitle + " <span style='color:darkred;font-weight:bold'>" + this.bA(T.lat(), 5) + "&deg;</span> &nbsp; " + this.sidebarLongTitle + " <span style='color:darkred;font-weight:bold'>" + this.bA(T.lng(), 5) + "&deg;</span><br /><br />";}if (this.infoMagnify || this.infoZoom) {f += "<div style='width:250px'>";if (this.infoZoom) {f += "<a href='javascript:mcfm.zoomIn()' style='color:blue'>" + this.txt_ZoomIn + "</a> - " + "<a href='javascript:mcfm.zoomOut()' style='color:blue'>" + this.txt_ZoomOut + "</a>";}if (mcfm.infoMagnify) {f += " - <a href='javascript:mcfm.magnify()' style='color:blue'>" + this.txt_Magnify + "</a> ";}f += "</div>";}return f;};
    MCFM.prototype.iv = function (Q) {var f = Q.bX() + "<br />";if (mcfm.infoDirections) {f += "<div id='directions1' style='width:250px'>" + "Get Directions " + "<a href='javascript:mcfm.directionsToHere()' style='color:blue'>" + this.txt_ToHere + "</a> " + "<a href='javascript:mcfm.directionsFromHere()' style='color:blue'>" + this.txt_FromHere + "</a></div>";f += "<div id='directions2' style='display:none;width:250px'>" + this.txt_GetDirections + " <span id='directionsTitle'></span><br/>" + "<div id='directionsSubtitle' style='color:gray;font-size:10px'></div>" + "<input id='directionsLocation' type='text' style='width:180px' onkeypress='return mcfm.directionsKey(event)' />&nbsp;" + "<input id='directionsFindBtn' type='button' onclick='mcfm.directionsFind()' value='" + this.txt_Go + "' />" + "<br /><a href='javascript:mcfm.directionsBack()' style='font-size:10px'>&laquo; " + this.txt_Back + "</a>" + "</div>";f += "<div style='width:320px;height:42px'>";}return f;};
    FMPlace.prototype.bX = function () {var f = "";var r = this.aj;if (this.O == FM_POINT) {switch (mcfm.infoIcon) {case 1:var wd = parseInt(r.iconSize.width / 2);var ht = parseInt(r.iconSize.height / 2);f += "<img src='" + r.iconUrl + "' alt='' width='" + wd + "' height='" + ht + "' /> &nbsp;";break;case 2:var wd = r.iconSize.width;var ht = r.iconSize.height;f += "<img src='" + r.iconUrl + "' alt='' width='" + wd + "' height='" + ht + "' /> &nbsp;";break;default:;}}if (this.ah.length > 0) {f += "<a target='_blank' href=\"" + this.ah + "\" >" + this.D + "</a><br/>";} else {f += "<b>" + this.D + "</b><br/>";}return f;};
    FMPlace.prototype.dC = function () {var f = this.bX();if (mcfm.infoHeight) {f += "<div style='overflow:auto;height:" + mcfm.infoHeight + "px'>";}f += this.ac;if (this.cb != null) {mcfm.cx = true;f += mcfm.fX(this, false);mcfm.dI = this;}if (this.du) {f += "<div>" + this.du.feedTag + "</div>";}if (mcfm.infoHeight) {f += "</div>";}f += mcfm.dy(this);return f;};
    MCFM.prototype.fX = function (Q, eP) {var f = "";if (Q.O == FM_POINT && this.infoStreetView) {if (eP) {f += "<div style='height:20px'>" + Q.bX() + "</div>";}f += "<div id='panDiv' style='width:" + mcfm.streetviewWidth + "px;height:" + mcfm.streetviewHeight + "px' align='center' valign='middle'></div>";if (eP) {f += "<div id='panInfo' style='height:20px'>&nbsp;</div>";}}return f;};
    FMPlace.prototype.bZ = function () {var f = "<div id='r" + this.bw + "' style='cursor:pointer;width:" + (mcfm.dw - 2) + "px;padding:1px;overflow:hidden;float:left' onmouseover='mcfm.rowHi(this)' onmouseout='mcfm.rowLo(this)' onclick='mcfm.rowClick(this)'>" + this.fF + "</div>";return f;};
    MCFM.prototype.be = function (Q, aG) {this.ds = Q;var dT = Q.dC();var aa = {};if (mcfm.infoWidth) {aa = {maxWidth: mcfm.infoWidth};}if (typeof aG != "undefined") {mcfm.map.openInfoWindowHtml(aG, dT, aa);} else {var ce = "";if (Q.cb == null) {ce = mcfm.fX(Q, true);}var gP = mcfm.iv(Q);this.dI = Q;var et = new GInfoWindowTab(mcfm.txt_Information, dT);if (!this.infoDirections) {if (ce.length) {this.cx = true;var cy = new GInfoWindowTab(mcfm.txt_StreetView, ce);Q.v.openInfoWindowTabsHtml([et, cy], aa);} else {Q.v.openInfoWindowHtml(dT, aa);}} else {var cy = new GInfoWindowTab(mcfm.txt_Directions, gP);if (ce.length) {this.cx = true;var gI = new GInfoWindowTab(mcfm.txt_StreetView, ce);Q.v.openInfoWindowTabsHtml([et, cy, gI], aa);} else {Q.v.openInfoWindowTabsHtml([et, cy], aa);}}}};

    function FMplacePanorama() {
        if (!mcfm.bH) {
            mcfm.bH = new GStreetviewClient;
        }
        var bg = mcfm.e("panDiv");
        mcfm.az = new GStreetviewPanorama(bg);
        var o = mcfm.dI;
        mcfm.eN = o.M;
        mcfm.bH.getNearestPanorama(o.M, FMplacePanorama2);
    }


    function FMplacePanorama2(a) {
        var bg = mcfm.e("panDiv");
        var gb = mcfm.e("panInfo");
        var cn = false;
        if (a != null) {
            var bT = a.location;
            if (bT != null) {
                var o = mcfm.dI;
                var T = bT.latlng;
                var fY = 0;
                var eG = 0;
                var ec = mcfm.hX(T, mcfm.eN);
                var gF = T.distanceFrom(mcfm.eN);
                if (o.cb != null) {
                    ec = o.cb;
                }
                if (o.dM != null) {
                    fY = o.dM;
                }
                if (o.dL != null) {
                    eG = o.dL;
                }
                mcfm.az.setLocationAndPOV(T, {yaw: ec, pitch: fY, zoom: eG});
                if (gb) {
                    gb.innerHTML = mcfm.txt_Distance + ": " + parseInt(gF) + " " + mcfm.txt_metres + ", &nbsp; " + mcfm.txt_Direction + ": " + parseInt(ec) + "&deg;";
                }
                cn = true;
            }
        }
        if (!cn && bg) {
            bg.style.backgroundColor = "gainsboro";
            bg.innerHTML = "<br /><br />" + mcfm.txt_StreetViewUnavailable;
        }
    }

    FMPlace.prototype.cT = function () {var g = this.du;this.aU = this.D.toLowerCase();this.dx = this.ac.toLowerCase();if (g.cU) {this.aj = g.aj;}this.dr = mcfm.cX(this.D);if (mcfm.targetFrame != "") {var bS = this.ac;var eh = "";var bl = 0;while (bl >= 0) {var bl = bS.indexOf("<a");var iE = bS.indexOf("<A");if (bl < 0) {bl = iE;}if (bl >= 0) {eh += bS.substr(0, bl + 2) + " target='" + mcfm.targetFrame + "' ";bS = bS.substr(bl + 2);} else {eh += bS;}}this.ac = eh;}this.jb();if (g.F == null) {g.F = new GLatLngBounds(this.M);} else {g.F.extend(this.M);}if (this.F) {g.F.extend(this.F.getSouthWest());g.F.extend(this.F.getNorthEast());}};
    FMPlace.prototype.jb = function () {var f = "";var bJ = "";if (!mcfm.sidebarIcon) {bJ = "&nbsp;&bull;&nbsp;";} else {var r = this.aj;switch (this.O) {case FM_POINT:if (mcfm.sidebarIcon && this.aj) {if (mcfm.sidebarIcon == 1) {var wd = parseInt(r.iconSize.width / 2);var ht = parseInt(r.iconSize.height / 2);bJ = "<img src='" + r.iconUrl + "' alt='' width='" + wd + "' height='" + ht + "' /> ";} else {var wd = r.iconSize.width;var ht = r.iconSize.height;bJ = "<img src='" + r.iconUrl + "' alt='' width='" + wd + "' height='" + ht + "' /> ";}}break;case FM_POLYLINE:var jh = parseInt(r.lineWidth);var ek = r.lineCol;var ca = ";opacity:" + r.lineOpacity;var bd = "16px";bJ = "<table cellpadding=0 cellpsacing=0 style='width:" + bd + ";height:" + bd + "'><tr valign='middle'><td style='width:" + bd + "'>" + "<table style='width:" + bd + "'><tr style='height:4px'><td style='width:" + bd + ca + ";background-color:" + ek + "'></td></tr></table>" + "</td></tr></table>";break;case FM_POLYGON:var jm = parseInt(r.lineWidth);var ek = r.lineCol;var iX = r.polyCol;var ca = (r.polyOpacity > r.lineOpacity) ? r.polyOpacity : r.lineOpacity;ca = ";opacity:" + ca;var bd = "12px";var gX = "10px";bJ = "<div style='width:" + bd + ";height:" + gX + ";border:solid 2px " + ek + ca + ";background-color:" + iX + "'></div>";break;default:;}}f += "<div style='float:left'>" + bJ + "</div>&nbsp;";if (mcfm.sidebarDescription) {f += "<b>" + this.D + "</b><br/>" + this.ac;} else {f += this.D;}this.fF = f;};
    FMPlace.prototype.fB = function () {var C = new GLatLngBounds;for (var i = 0; i < this.as.length; i++) {C.extend(this.as[i]);}this.F = C;this.M = C.getCenter();};
    FMPlace.prototype.fw = function () {var C = new GLatLngBounds;this.M = this.as[0];for (var i = 0; i < this.as.length; i++) {C.extend(this.as[i]);}var iQ = parseInt(this.as.length / 2);this.M = this.as[iQ];this.F = C;};
    FMPlace.prototype.dD = function (ap, ao) {var ad = ap.getElementsByTagName("Point");var cJ = ap.getElementsByTagName("LineString");var iU = ap.getElementsByTagName("Polygon");if (ad.length > 0) {this.O = FM_POINT;} else if (cJ.length > 0) {this.O = FM_POLYLINE;} else if (iU.length > 0) {this.O = FM_POLYGON;}var eJ = ap.getElementsByTagName("name");if (eJ.length > 0) {this.D = GXml.value(eJ[0]);}var fx = ap.getElementsByTagName("description");if (fx.length > 0) {this.ac = GXml.value(fx[0]);}var eI = ap.getElementsByTagName("link");if (eI.length > 0) {this.ah = GXml.value(eI[0]);}var gu = ap.getElementsByTagName("styleUrl");if (gu.length > 0) {var hd = GXml.value(gu[0]).substr(1);var r = ao.cV[hd];if (r) {this.aj = r;}} else {var cf = ap.getElementsByTagName("href");if (cf.length > 0) {var B = GXml.value(cf[0]);if (B) {this.aj.iconUrl = B;}}}var fa = ap.getElementsByTagName("coordinates");if (fa.length > 0) {var hN = GXml.value(fa[0]).trim();var eB = [];var ey = hN.split(" ");for (var k = 0; k < ey.length; k++) {if (ey[k].length > 1) {eB.push(ey[k]);}}for (var j = 0; j < eB.length; j++) {var di = eB[j].split(",");if (di.length > 1) {var x = parseFloat(di[0]);var y = parseFloat(di[1]);var T = new GLatLng(y, x);this.as.push(T);}}}switch (this.O) {case FM_POINT:this.M = this.as[0];break;case FM_POLYLINE:this.fw();break;case FM_POLYGON:this.fB();break;default:;}this.cT();};
    FMPlace.prototype.je = function (aJ, ao) {this.aj = ao.aj;var gh = aJ.getElementsByTagName("title")[0];if (gh) {this.D = gh.firstChild.nodeValue;this.aU = this.D.toLowerCase();}var eL = aJ.getElementsByTagName("description")[0];if (eL) {this.ac = eL.firstChild.nodeValue;this.dx = this.ac.toLowerCase();}if (this.ac.length == 0) {var gf = aJ.getElementsByTagName("summary")[0];if (gf) {this.ac = gf.firstChild.nodeValue;}}var eD = aJ.getElementsByTagName("link")[0];if (eD) {this.ah = eD.firstChild.nodeValue;}var bB = null;bB = aJ.getElementsByTagName("georss:point")[0];if (!bB) {bB = aJ.getElementsByTagName("point")[0];}var cc = aJ.getElementsByTagName("Polygon")[0];if (!cc) {cc = aJ.getElementsByTagName("gml:Polygon")[0];}var cw = aJ.getElementsByTagName("LineString")[0];if (!cw) {cw = aJ.getElementsByTagName("gml:LineString")[0];}if (cc) {var bo = cc.getElementsByTagName("posList")[0];if (!bB) {bo = cc.getElementsByTagName("gml:posList")[0];}if (bo) {var ad = bo.firstChild.nodeValue;this.ja(ad);}} else if (cw) {var bo = cw.getElementsByTagName("posList")[0];if (!bB) {bo = cw.getElementsByTagName("gml:posList")[0];}if (bo) {var ad = bo.firstChild.nodeValue;this.jf(ad);}} else if (bB) {var T = bB.firstChild.nodeValue;this.jc(T);}switch (this.O) {case FM_POINT:break;case FM_POLYLINE:this.fw();break;case FM_POLYGON:this.fB();break;default:;}if (this.M != null) {this.cT();}};
    FMPlace.prototype.jc = function (aG) {this.O = FM_POINT;var ad = aG.split(" ");this.y = parseFloat(ad[0]);this.x = parseFloat(ad[1]);this.M = new GLatLng(this.y, this.x);};
    FMPlace.prototype.jf = function (dg) {this.O = FM_POLYLINE;var bu = dg.split(" ");var ad = [];for (var i = 0; i < bu.length; i += 2) {var y = parseFloat(bu[i]);var x = parseFloat(bu[i + 1]);ad.push(new GLatLng(y, x));}this.as = ad;this.M = ad[0];};
    FMPlace.prototype.ja = function (dg) {this.O = FM_POLYGON;var bu = dg.split(" ");var ad = [];for (var i = 0; i < bu.length; i += 2) {var y = parseFloat(bu[i]);var x = parseFloat(bu[i + 1]);ad.push(new GLatLng(y, x));}this.as = ad;this.M = ad[0];};
    FMPlace.prototype.dK = function (hl, ao) {var bO = hl.split("\t");this.O = FM_POINT;if (bO.length > 3) {var hg = ao.cL.charCodeAt(0) - 65;var hE = ao.cW.charCodeAt(0) - 65;var hf = ao.cI.charCodeAt(0) - 65;var gM = ao.cD.charCodeAt(0) - 65;var it = ao.dc.charCodeAt(0) - 65;this.bv = bO[hg];this.bt = bO[hE];this.M = new GLatLng(this.bt, this.bv);this.D = bO[hf];this.ac = bO[gM];this.ah = bO[it];this.cT();}};
    MCFM.prototype.zoomIn = function () {var at = this.map.getInfoWindow();if (at) {var L = at.getPoint();var R = this.map.getZoom() + 1;this.map.setCenter(L, R);}};
    MCFM.prototype.zoomOut = function () {var at = this.map.getInfoWindow();if (at) {var L = at.getPoint();var R = this.map.getZoom() - 1;this.map.setCenter(L, R);}};
    MCFM.prototype.magnify = function () {var at = this.map.getInfoWindow();if (at) {var L = at.getPoint();this.map.closeInfoWindow();var aa = {};switch (this.infoMagnifyMapType) {case 0:aa = {mapType: G_NORMAL_MAP};break;case 1:aa = {mapType: G_SATELLITE_MAP};break;case 2:aa = {mapType: G_HYBRID_MAP};break;case 3:aa = {mapType: G_PHYSICAL_MAP};break;default:;}this.map.showMapBlowup(L, aa);}};
    MCFM.prototype.sidebarClick = function () {var gm = this.e("fmSidebar");var gn = this.e("fmSidebarTitle");var fU = this.e("fmPaging");var cC = this.e("fmSidebarCoords");var cF = this.e("fmSidebarOptions");var cH = this.e("fmMap");var da = this.e("adcontainer");var L = null;if (this.map) {L = this.map.getCenter();}this.sidebarShow = !this.sidebarShow;if (this.sidebarShow) {gm.style.display = "block";gn.style.display = "block";fU.style.display = this.bV ? "block" : "none";if (cC) {cC.style.display = "block";}if (this.sidebarOptions && cF) {cF.style.display = "block";}cH.style.width = (this.layoutWidth - this.sidebarWidth) + "px";if (da) {var es = this.sidebarWidth + 4;da.style.left = es + "px";}} else {gm.style.display = "none";gn.style.display = "none";fU.style.display = "none";if (cC) {cC.style.display = "none";}if (cF) {cF.style.display = "none";}cH.style.width = this.layoutWidth + "px";if (da) {da.style.left = "4px";}}mcfm.cP();if (L) {this.map.checkResize();this.map.setCenter(L);}};
    MCFM.prototype.visClick = function (a) {this.visFilter = a.checked;this.K();};
    MCFM.prototype.iO = function (dp) {this.al();if (!this.ci) {this.iP();}if (dp) {this.bI = true;this.map.addOverlay(this.ci);if (this.aA) {this.map.addOverlay(this.aA);}} else {this.bI = false;this.map.removeOverlay(this.ci);if (this.aA) {this.map.removeOverlay(this.aA);}}};
    MCFM.prototype.streetviewCheck = function (a) {this.iO(a.checked);};
    MCFM.prototype.streetviewClick = function () {var ew = this.e("streetviewBox");ew.checked = true;this.streetviewEnable(true);};
    MCFM.prototype.iP = function () {this.ci = new GStreetviewOverlay;this.ax = this.map.getCenter();if (!this.bH) {this.bH = new GStreetviewClient;}this.bL = "";GEvent.addListener(this.map, "click", function (eg, T) {if (T && mcfm.bI) {mcfm.dv(T);}});if (this.streetviewLayer) {this.bI = true;this.map.addOverlay(this.ci);if (this.streetviewMarker) {this.dv(this.ax);}} else {this.bI = false;}};
    MCFM.prototype.dv = function (aG, jq) {mcfm.map.closeInfoWindow();if (!this.bI) {return;}this.bH.getNearestPanorama(aG, FMinitPanorama2);};

    function FMinitPanorama2(a) {
        if (a == null) {
            return;
        }
        var bT = a.location;
        if (bT == null) {
            mcfm.bL = mcfm.txt_ImageNotAvailable;
            if (mcfm.aA) {
                mcfm.ax = mcfm.aA.getPoint();
            }
            return;
        }
        mcfm.ax = bT.latlng;
        mcfm.bL = bT.description;
        mcfm.dm();
        mcfm.fO();
    }

    MCFM.prototype.fO = function () {var f = "<table cellspacing=0 cellpadding=0 style='width:" + this.streetviewWidth + "px'><tr><td style='width:" + this.streetviewWidth + "px'>" + "<div id='svTitleDiv' style='color:dodgerblue;font-weight:bold;width:" + this.streetviewWidth + "px;height:20px'>" + this.bL + "</div>" + "<div id='panDiv' style='width:" + this.streetviewWidth + "px;height:" + this.streetviewHeight + "px' ></div>" + "</td></tr></table>" + "<div id='svFooterDiv' style='color:dodgerblue;font-weight:bold;width:" + this.streetviewWidth + "px;height:20px'></div>";mcfm.dH = true;mcfm.aA.openInfoWindowHtml(f);};
    MCFM.prototype.dsiw2 = function () {var bg = mcfm.e("panDiv");mcfm.az = new GStreetviewPanorama(bg);GEvent.addListener(mcfm.az, "yawchanged", function (a) {mcfm.heading = parseFloat(a);mcfm.dm();});GEvent.addListener(mcfm.az, "initialized", function (a) {mcfm.ax = a.latlng;mcfm.bL = a.description;mcfm.gw = mcfm.ax;mcfm.x = mcfm.gw.lng();mcfm.y = mcfm.gw.lat();mcfm.dm();});mcfm.az.setLocationAndPOV(mcfm.ax, {yaw: mcfm.heading});};
    MCFM.prototype.dm = function () {if (!this.aA) {var B = new GIcon;var dR = Math.round(mcfm.heading / 22.5) % 16;var dU = "http://maps.google.com/intl/en_us/mapfiles/cb/man_arrow-" + dR + ".png";B.image = dU;B.iconSize = new GSize(49, 52);B.printImage = B.image;B.mozPrintImage = B.image;B.iconAnchor = new GPoint(25, 36);B.infoWindowAnchor = new GPoint(25, 6);var bk = new GMarker(this.ax, {icon: B, draggable: true});this.map.addOverlay(bk);this.aA = bk;GEvent.addListener(bk, "dragstart", function () {mcfm.map.closeInfoWindow();mcfm.bi();});GEvent.addListener(bk, "dragend", function () {mcfm.ax = bk.getPoint();mcfm.dv(mcfm.ax);});GEvent.addListener(bk, "click", function () {mcfm.fO();});} else {var gg = mcfm.e("svTitleDiv");if (gg) {gg.innerHTML = mcfm.bL;}var dR = Math.round(mcfm.heading / 22.5) % 16;var dU = "http://maps.google.com/intl/en_us/mapfiles/cb/man_arrow-" + dR + ".png";this.aA.setImage(dU);this.aA.setPoint(this.ax);var at = this.map.getInfoWindow();if (at) {at.reposition(this.ax, new GSize(0, -30));}}};

    function FMStyle() {
        this.cR = "0";
        this.iconUrl = "http://maps.google.com/mapfiles/ms/icons/red-dot.png";
        this.shadowUrl = "";
        this.iconSize = new GSize(32, 32);
        this.iconAnchor = new GPoint(15, 31);
        this.infoAnchor = new GPoint(15, 0);
        this.shadowAnchor = new GPoint(0, 31);
        this.shadowSize = new GSize(59, 32);
        this.lineWidth = "2";
        this.lineOpacity = 0.7;
        this.lineCol = "#00FF00";
        this.polyFill = "1";
        this.polyOutline = "1";
        this.polyOpacity = 0.4;
        this.polyCol = "#80FF80";
        this.cs = "FF000080";
        this.cp = "80FF8055";
    }

    FMStyle.prototype.ii = function (a) {this.cR = a.getAttribute("id");var cf = a.getElementsByTagName("Icon");if (cf.length > 0) {this.iconUrl = GXml.value(cf[0].getElementsByTagName("href")[0]);mcfm.ie(this);}var eF = a.getElementsByTagName("LineStyle");if (eF.length > 0) {var eO = eF[0];this.lineWidth = parseInt(GXml.value(eO.getElementsByTagName("width")[0]));this.cs = GXml.value(eO.getElementsByTagName("color")[0]);this.lineCol = "#" + this.cs.substr(6, 2) + this.cs.substr(4, 2) + this.cs.substr(2, 2);var bY = this.cs.substr(0, 2);var c0 = bY.substr(0, 1);var c1 = bY.substr(1, 1);var hR = mcfm.ab[c0] * 16 + mcfm.ab[c1];this.lineOpacity = parseFloat(hR / 255);}var fK = a.getElementsByTagName("PolyStyle");if (fK.length > 0) {var en = fK[0];this.polyOutline = parseInt(GXml.value(en.getElementsByTagName("outline")[0]));this.polyFill = parseInt(GXml.value(en.getElementsByTagName("fill")[0]));this.cp = GXml.value(en.getElementsByTagName("color")[0]);this.polyCol = "#" + this.cp.substr(6, 2) + this.cp.substr(4, 2) + this.cp.substr(2, 2);var bY = this.cp.substr(0, 2);var c0 = bY.substr(0, 1);var c1 = bY.substr(1, 1);var iT = mcfm.ab[c0] * 16 + mcfm.ab[c1];this.polyOpacity = parseFloat(iT / 255);}};
    MCFM.prototype.gG = function () {this.ab = [];for (var i = 0; i < 10; i++) {var c = i.toString();this.ab[c] = i;}this.ab.A = 10;this.ab.B = 11;this.ab.C = 12;this.ab.D = 13;this.ab.E = 14;this.ab.F = 15;this.ab.a = 10;this.ab.b = 11;this.ab.c = 12;this.ab.d = 13;this.ab.e = 14;this.ab.f = 15;};
    MCFM.prototype.fp = function (dp) {this.fs = dp;if (!this.cl) {if (this.fs) {this.cl = new GTrafficOverlay;this.map.addOverlay(this.cl);}} else {if (this.fs) {this.cl.show();} else {this.cl.hide();}}};
    MCFM.prototype.trafficCheck = function (a) {this.fp(a.checked);};
    MCFM.prototype.trafficClick = function () {var ew = this.e("trafficBox");ew.checked = true;this.fp(true);};
    MCFM.prototype.e = function (id) {return document.getElementById(id);};
    String.prototype.trim = function () {return this.replace(/^\s*|\s*$/g, "");};
    MCFM.prototype.cQ = function (p1, p2) {var v1 = p1.aU;var v2 = p2.aU;var aP = (v1 < v2) ? -1 : (v1 > v2) ? 1 : 0;return aP;};
    MCFM.prototype.iD = function (p1, p2) {var v1 = p1.bx;var v2 = p2.bx;if (v1 == 0) {v1 = 100000;}if (v2 == 0) {v2 = 100000;}if (v1 == v2) {return mcfm.cQ(p1, p2);} else {return (v1 < v2) ? -1 : (v1 > v2) ? 1 : 0;}return aP;};
    MCFM.prototype.iG = function (p1, p2) {var aP = (p1 < p2) ? -1 : (p1 > p2) ? 1 : 0;return aP;};
    MCFM.prototype.bA = function (hC, hu) {var eH = Math.pow(10, hu);return parseInt(hC * eH, 10) / eH;};
    MCFM.prototype.cX = function (gy) {var gD = "";for (var i = 0; i < gy.length; i++) {var c = gy.substr(i, 1);if (c == " ") {c = "&nbsp;";}gD += c;}return gD;};
    MCFM.prototype.hX = function (p1, p2) {var angle = null;if (p1 != null && p2 != null && !p1.equals(p2)) {var y1 = p1.latRadians();var x1 = p1.lngRadians();var y2 = p2.latRadians();var x2 = p2.lngRadians();var a = Math.sin(x1 - x2) * Math.cos(y2);var b = Math.cos(y1) * Math.sin(y2) - Math.sin(y1) * Math.cos(y2) * Math.cos(x1 - x2);angle = - Math.atan2(a, b);if (angle < 0) {angle += Math.PI * 2;}}return angle * 180 / Math.PI;};
