jQuery(document).ready(function(){
jQuery('#translateBlockNews').append('
').after('This translation is not completely accurate as it was automatically generated by a computer.
Powered by
');
jQuery("#transPageHeaderNews").one("click", function(){
jQuery(this).animate({width:"125px",fontSize:"1.1em"},500,
function(){jQuery(this).text("Translate This Page");jQuery.getScript('http://jquery-translate.googlecode.com/files/jquery.translate-1.3.7.min.js', function(){ //when the script is loaded
jQuery.translate(function(){ //when the Google Language API is loaded
jQuery.translate.ui('select', 'option') //generate dropdown
.change(function(){ //when selecting another language
jQuery("#disclaimer,#disclaimerMessage").show();
jQuery('#mainContent,#headerPhrase,#disclaimer,.homeText,#read,#maincontent, #disclaimerMessage, #disclaimerDialog').translate( 'english', jQuery(this).val(), { //translate from english to the selected language
not: '.option, .jq-translate-ui,#source,pre,#demo,.retweet,#fontSize,.addthis_toolbox,#transPageHeaderNews,#showDialog, .dimLights, .clickMeToExit', //exclude these elements
fromOriginal:true, //always translate from english (even after the page has been translated)
start:function(){jQuery("#disclaimer").after('');jQuery(".loaderTrans").fadeIn("slow");},
complete:function(){jQuery(".loaderTrans").fadeOut("slow",function(){jQuery(this).remove();});}
})
})
.val('English') //select English as default
.appendTo('#transDrop'); //insert the dropdown to the page
});} );
jQuery("#transDrop").show("slow");
});
});
if (jQuery('#tabs').length == 0) {
jQuery('.commentInvite').hide();
jQuery('.socialBarJr').hide();
}
jQuery("#showDialog").click(
function() {
jQuery("#disclaimerDialog").dialog( {
bgiframe: true,
height: 100,
modal: true,
closeOnEscape: true,
beforeclose: function(event, ui) {jQuery("#disclaimerDialog").dialog('destroy');}
} );
jQuery('.siteTools').attr("title","Hello there buddy
How are you??");
(function($) {
jQuery.fn.tipsy = function(opts) {
opts = jQuery.extend({fade: false, gravity: 'n'}, opts || {});
var tip = null, cancelHide = false;
this.hover(function() {
jQuery.data(this, 'cancel.tipsy', true);
var tip = jQuery.data(this, 'active.tipsy');
if (!tip) {
tip = jQuery('' + jQuery(this).attr('title') + '
');
tip.css({position: 'absolute', zIndex: 100000});
jQuery(this).attr('title', '');
$.data(this, 'active.tipsy', tip);
}
var pos = $.extend({}, jQuery(this).offset(), {width: this.offsetWidth, height: this.offsetHeight});
tip.remove().css({top: 0, left: 0, visibility: 'hidden', display: 'block'}).appendTo(document.body);
var actualWidth = tip[0].offsetWidth, actualHeight = tip[0].offsetHeight;
switch (opts.gravity.charAt(0)) {
case 'n':
tip.css({top: pos.top + pos.height, left: pos.left + pos.width / 2 - actualWidth / 2}).addClass('tipsy-north');
break;
case 's':
tip.css({top: pos.top - actualHeight, left: pos.left + pos.width / 2 - actualWidth / 2}).addClass('tipsy-south');
break;
case 'e':
tip.css({top: pos.top + pos.height / 2 - actualHeight / 2, left: pos.left - actualWidth}).addClass('tipsy-east');
break;
case 'w':
tip.css({top: pos.top + pos.height / 2 - actualHeight / 2, left: pos.left + pos.width}).addClass('tipsy-west');
break;
}
if (opts.fade) {
tip.css({opacity: 0, display: 'block', visibility: 'visible'}).animate({opacity: 1});
} else {
tip.css({visibility: 'visible'});
}
}, function() {
$.data(this, 'cancel.tipsy', false);
var self = this;
setTimeout(function() {
if ($.data(this, 'cancel.tipsy')) return;
var tip = $.data(self, 'active.tipsy');
if (opts.fade) {
tip.stop().fadeOut(function() { jQuery(this).remove(); });
} else {
tip.remove();
}
}, 100);
});
};
})(jQuery);
});
jQuery("body").append("Press ESC or click anywhere to exit.
Raise Lights
");
/*jQuery(".videoPlayer").prepend("");*/
jQuery(".dimLights").click(
function(){
jQuery("#fadeDiv,.clickMeToExit,#presESC").css({'opacity':'0','display':'block'}).fadeTo("slow",0.87);
jQuery("div.dimLights").fadeOut("slow");
setTimeout(function(){jQuery("#presESC").fadeOut("slow") },5000);
});
jQuery(".clickMeToExit,#fadeDiv,#presESC").click(
function() {
jQuery("#fadeDiv,.clickMeToExit").fadeOut("slow");
jQuery("div.dimLights").fadeIn("slow");
});
/*var longFreakinText=jQuery("div#video div.videoPlayer embed").attr("flashvars");
var re=new RegExp(/http:\/\/media\.umcom\.org.*\.mp4|http:\/\/umcmedia\.org.*\.mp4/);
var m=re.exec(longFreakinText);
var url="";
for (i = 0; i < m.length; i++) {
url = url + m[i];
}
var newURL = "";
newURL = url.replace(/\_lo\.mp4/gi, "_hi.mp4");
jQuery(".regexDownlaodLink").attr("href",newURL);*/
});
jQuery(document).keydown( function(e) {
if( e.which == 27) {
jQuery("#fadeDiv,.clickMeToExit").fadeOut("slow");
jQuery("div.dimLights").fadeIn("slow");
}});