/* FILE ARCHIVED ON 6:55:39 Dec 12, 2013 AND RETRIEVED FROM THE INTERNET ARCHIVE ON 22:01:13 Dec 12, 2016. JAVASCRIPT APPENDED BY WAYBACK MACHINE, COPYRIGHT INTERNET ARCHIVE. ALL OTHER CONTENT MAY ALSO BE PROTECTED BY COPYRIGHT (17 U.S.C. SECTION 108(a)(3)). */ (function(){function n(a,b,c,d){function e(){if(f)return null;var h=b;b.childNodes&&b.childNodes.length&&!k?b=b[d?"lastChild":"firstChild"]:b[d?"previousSibling":"nextSibling"]?(b=b[d?"previousSibling":"nextSibling"],k=!1):b.parentNode&&(b=b.parentNode,b===a&&(f=!0),k=!0,e());h===c&&(f=!0);return h}var d=!!d,b=b||a[d?"lastChild":"firstChild"],f=!b,k=!1;return e}function q(a){for(var b=1;b\u2026\\n\u00a0\\*]+", selectable:"selectable-content",marker:"txtselect_marker",ignored:null,selectMessage:null,location:new m,validate:!1,enableHaschange:!0,onMark:null,onUnmark:null,onHashRead:function(){var a=t(this.selectable,"user_selection_true");a&&!this.hashWasRead&&(this.hashWasRead=!0,window.setTimeout(function(){for(var b=0,c=0;a;)b+=a.offsetLeft,c+=a.offsetTop,a=a.offsetParent;window.scrollTo(b,c-150)},1))},isBlock:function(a){return"BR"==a.nodeName||-1==z(B(a,"display"),["inline","none"])}};j.prototype={init:function(){function a(a){y(a); a.stopPropagation?a.stopPropagation():a.cancelBubble=!0;a=a.target||a.srcElement;if(!l(this,"masha-marker-bar")||l(a,"masha-social")||l(a,"masha-marker"))if(s(b.marker,"show"),b.rangeIsSelectable()&&(b.addSelection(),b.updateHash(),b.options.onMark&&b.options.onMark.call(b),b.options.selectMessage&&b._showMessage(),l(a,"masha-social")&&(a=a.getAttribute("data-pattern"))))a=a.replace("{url}",encodeURIComponent(window.location.toString())),b.openShareWindow(a)}this.selectable="string"==typeof this.options.selectable? document.getElementById(this.options.selectable):this.options.selectable;"string"==typeof this.options.marker?(this.marker=document.getElementById(this.options.marker),null===this.marker&&(this.marker=document.createElement("a"),this.marker.setAttribute("id",this.options.marker),this.marker.setAttribute("href","#"),document.body.appendChild(this.marker))):this.marker=this.options.marker;if("string"!=typeof this.options.regexp)throw"regexp is set as string";this.regexp=RegExp(this.options.regexp,"ig"); var b=this;this.selectable&&(this.isIgnored=this.constructIgnored(this.options.ignored),this.options.selectMessage&&this.initMessage(),this.enumerateElements(),"ontouchstart"in window||window.DocumentTouch&&document instanceof DocumentTouch?g(this.selectable,"touchend",function(){window.setTimeout(function(){var a=window.getSelection();if(a.rangeCount){a=a.getRangeAt(0).getClientRects();if(a=a[a.length-1])var d={x:a.left+a.width+document.body.scrollLeft,y:a.top+a.height/2+document.body.scrollTop}; b.showMarker(d)}},1)}):g(this.selectable,"mouseup",function(a){var d=C(a);window.setTimeout(function(){b.showMarker(d)},1)}),g(this.marker,"click",a),g(this.marker,"touchend",a),g(document,"click",function(a){(a.target||a.srcElement)!=b.marker&&s(b.marker,"show")}),this.options.enableHaschange&&this.options.location.addHashchange(function(){if(b.lastHash!=b.options.location.getHash()){var a=[],d;for(d in b.ranges)a.push(d);b.deleteSelections(a);b.readHash()}}),this.readHash())},openShareWindow:function(a){window.open(a, "","status=no,toolbar=no,menubar=no,width=800,height=400")},getMarkerCoords:function(a,b){return{x:b.x+5,y:b.y-33}},getPositionChecksum:function(a){for(var b="",c=0;3>c;c++){var d=(a()||"").charAt(0);d&&(d="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz1234567890".charAt(d.charCodeAt(0)%62));b+=d}return b},showMarker:function(a){var b=RegExp(this.options.regexp,"g"),c=window.getSelection().toString();""!=c&&b.test(c)&&this.rangeIsSelectable()&&(a=this.getMarkerCoords(this.marker,a),this.marker.style.top= a.y+"px",this.marker.style.left=a.x+"px",x(this.marker,"show"))},deleteSelections:function(a){for(var b=a.length;b--;){var c=a[b],d=v(this.selectable,c),e=t(d[d.length-1],"closewrap");e.parentNode.removeChild(e);this.removeTextSelection(d);delete this.ranges[c]}},removeTextSelection:function(a){for(var b=a.length;b--;){for(var c=a[b],d=0;d