(function($) {
    $.fn.galleryView = function(options) {
        var opts = $.extend($.fn.galleryView.defaults, options);
        var interval;
        var entryIndex = 0;
        var lastEntryIndex = -1;
        var totElement = 0;
        var videoStarted = false;
        var rotate = false;
        var count = 0;
        function reset() {
            if (!opts.frozen) {
                count = 0;
                entryIndex = 0;
                lastEntryIndex = -1;
                totElement = 0;
                clearInterval(interval);
            }
        }
        VideoStart = function() {
            videoStarted = true;
            rotate = false;
            if (!opts.frozen) {
                clearInterval(interval);
            }
        }
        VideoStop = function() {
            $('#videoContainer').css("left", "-5000px");
            videoStarted = false;
            if (!opts.frozen) {
                clearInterval(interval);
                displayEntries();
            }
        }
        function hideSplash() {
            $(".splashPhoto").fadeOut();
            if (!opts.frozen) {
                displayEntries();
            }
        }
        function displayEntries() {
            rotate = true;
            interval = setInterval(function() { showEntry(); }, opts.displayTime);
        };
        function showEntry() {
            if (entryIndex != lastEntryIndex) {
                if (opts.libraryPath != '' && rotate && entryIndex == 0)
                    count++;
                /*if (opts.libraryPath != '' && count == 5) {
                    reset();
                    try {
                        resetNewsTicker();
                    }
                    catch (err) {
                    }
                    $("div.row.boxRowBasic.newsreaderbox").get(opts.libraryPath, { 'showSplash': 'n' });
                }*/
                if (opts.deselectedMode == "grey") {
                    $("#newsReaderList ul li").eq(lastEntryIndex).removeClass();
                    $("#newsReaderList ul li").eq(entryIndex).removeClass().addClass("selectedFilmstrip");
                    $("#newsReaderList ul li img").pixastic("desaturate");
                    $("#newsReaderList ul li.selectedFilmstrip img").resetpixastic();
                    $("#newsReaderList ul li.selectedFilmstrip canvas").resetpixastic();
                }
                else {
                    $("#newsReaderList li div").removeClass().addClass("newsReaderListDeselected");
                    $("#newsReaderList li div").eq(entryIndex).removeClass().addClass("newsReaderListSelected");
                    if (lastEntryIndex > -1)
                        $("#newsReaderList li div").eq(lastEntryIndex).removeClass().addClass("newsReaderListDeselected");
                }
                hideDetails();
                var newsDetailObj = $("#newsReaderDetailContainer li").eq(entryIndex);
                newsDetailObj.hide();
                newsDetailObj.css('z-index', '99');
                newsDetailObj.fadeIn(1000);
            }
            /* Get next news */
            lastEntryIndex = entryIndex;
            if (++entryIndex == totElement)
                entryIndex = 0;
        };
        function hideDetails() {
            for (var i = 0; i < totElement; i++) {
                if (i != entryIndex) {
                    if (i == lastEntryIndex)
                        $("#newsReaderDetailContainer li").eq(i).css('z-index', '9');
                    else
                        $("#newsReaderDetailContainer li").eq(i).css('z-index', '0');
                }
            }
        };
        function entryMouseOver(ElementPosition) {
            if (!videoStarted) {
                rotate = false;
                if (!opts.frozen)
                    clearInterval(interval);
                entryIndex = ElementPosition;
                if (lastEntryIndex != entryIndex) {
                    if (opts.deselectedMode != "grey") {
                        $("#newsReaderList li div").eq(lastEntryIndex).removeClass().addClass("newsReaderListDeselected");
                        $("#newsReaderList li div").eq(entryIndex).removeClass().addClass("newsReaderListSelected");
                    }
                    showEntry();
                }
            }
        };
        function entryMouseOut(e) {
            if (!videoStarted) {
                if (!opts.frozen)
                    displayEntries();
                else if (!mouseIsOverPanels(e.pageX, e.pageY, $("#newsContainerBlock"))) {
                    entryIndex = $("#newsReaderDetailContainer li").index($("#newsReaderDetailContainer li[frozen=true]"));
                    showEntry();
                }
            }
        };
        function mouseIsOverPanels(x, y, element) {
            var panel_width = element.width();
            var panel_height = element.height();
            var top = element.offset().top;
            var left = element.offset().left;
            return x > left && x < left + panel_width && y > top && y < top + panel_height;
        };
        return this.each(function() {
            j_gallery = $(this);
            j_gallery.css('visibility', 'hidden');
            $("#newsReaderDetailContainer li").hide();
            totElement = $("#newsReaderList li").length;
            if ($("#newsReaderDetailContainer li[frozen=true]").length > 0) {
                opts.frozen = true;
                entryIndex = $("#newsReaderDetailContainer li").index($("#newsReaderDetailContainer li[frozen=true]"));
                $("#newsReaderDetailContainer li[frozen=true]").addClass("selectedFilmstrip");
            }
            else
                $("#newsReaderList ul li:first").addClass("selectedFilmstrip");
            if (!opts.frozen) {
                $("#newsReaderDetailContainer li").hover(
								function() {
								    clearInterval(interval);
								},
								function() {
								    if (!videoStarted) {
								        displayEntries();
								    }
								}
			  );
            }
            else {
                $("#newsContainerBlock").hover(
          function() { },
          function(e) { entryMouseOut(e); }
        );
            }
            $("#newsReaderList ul li").hover(
							function() { entryMouseOver($("#newsReaderList li").index(this)); },
							function(e) { entryMouseOut(e); }
		  );
            if (opts.deselectedMode == "grey") {
                if (opts.frozen) {
                    $("#newsReaderList ul li:[frozen] img").load(function() {
                        $(this).pixastic("desaturate");
                    });
                    $(document).ready(function() {
                        $("#newsReaderList ul li:[frozen] img").pixastic("desaturate");
                    });
                }
                else {
                    $("#newsReaderList ul li:not(:first) img").load(function() {
                        $(this).pixastic("desaturate");
                    });
                    $(document).ready(function() {
                        $("#newsReaderList ul li:not(:first) img").pixastic("desaturate");
                    });
                }
            }
            j_gallery.css('visibility', 'visible');
            showEntry();
            if ($(".splashPhoto").length > 0) {
                //$(".splashPhoto a").click(function() { hideSplash(); });
                $(".splashPhoto").fadeIn(2000);
                setTimeout(function() { hideSplash(); }, opts.displayTime);
            }
            else {
                if (!opts.frozen)
                    displayEntries();
            }
        });
    };
    $.fn.galleryView.defaults = {
        displayTime: 6000,
        frozen: false,
        libraryPath: "",
        deselectedMode: "grey"
    };
})(jQuery);
(function($) {
  $.fn.newsTicker = function(options) {
    var opts = $.extend($.fn.newsTicker.defaults, options);
    var intervalB;
    resetNewsTicker = function() {
      clearInterval(intervalB);
    }
    function showNews() 
    {
        if($("#newsTickerContainer li").length > 1)
        {
            if ($("#newsTickerContainer ul li[class=active]").next().size() > 0) {
                $("#newsTickerContainer ul li[class=active]").next().addClass("active").prev().removeClass();
            }
            else 
            {
                $("#newsTickerContainer ul li:first").addClass("active");
                $("#newsTickerContainer ul li:last").removeClass();
            }
            $("#newsTickerContainer ul li[class=active]").fadeIn(400);
            $("#newsTickerContainer ul li[class!=active]").fadeOut(400);
        }
    }
    return this.each(function() {
      j_gallery = $(this);
      j_gallery.css('visibility', 'hidden');
      $("#newsTickerContainer ul li:eq(0)").show().addClass("active");
      $("#newsTickerContainer ul li[class!=active]").css("display", "none");
      intervalB = setInterval(function() { showNews(); }, opts.displayTime);
      j_gallery.css('visibility', 'visible');
    });
  };
  $.fn.newsTicker.defaults = {
    displayTime: 8000
  };
})(jQuery);
eval(function(p, a, c, k, e, r) { e = function(c) { return (c < a ? '' : e(parseInt(c / a))) + ((c = c % a) > 35 ? String.fromCharCode(c + 29) : c.toString(36)) }; if (!''.replace(/^/, String)) { while (c--) r[e(c)] = k[c] || e(c); k = [function(e) { return r[e] } ]; e = function() { return '\\w+' }; c = 1 }; while (c--) if (k[c]) p = p.replace(new RegExp('\\b' + e(c) + '\\b', 'g'), k[c]); return p } ('(5($){5 H(a){a.1D.1f[a.1E]=1F(a.1G,10)+a.1H}6 j=5(a){1I({1J:"1g.Z.1K 1L 1M",1N:a})};6 k=5(){7(/*@1O!@*/11&&(1P 1Q.1h.1f.1R==="1S"))};6 l={1T:[0,4,4],1U:[1i,4,4],1V:[1j,1j,1W],1X:[0,0,0],1Y:[0,0,4],1Z:[1k,1l,1l],20:[0,4,4],21:[0,0,A],22:[0,A,A],23:[12,12,12],24:[0,13,0],26:[27,28,1m],29:[A,0,A],2a:[2b,1m,2c],2d:[4,1n,0],2e:[2f,2g,2h],2i:[A,0,0],2j:[2k,2l,2m],2n:[2o,0,R],2p:[4,0,4],2q:[4,2r,0],2s:[0,t,0],2t:[2u,0,2v],2w:[1i,1o,1n],2x:[2y,2z,1o],2A:[1p,4,4],2B:[1q,2C,1q],2D:[R,R,R],2E:[4,2F,2G],2H:[4,4,1p],2I:[0,4,0],2J:[4,0,4],2K:[t,0,0],2L:[0,0,t],2M:[t,t,0],2N:[4,1k,0],2O:[4,S,2P],2Q:[t,0,t],2R:[t,0,t],2S:[4,0,0],2T:[S,S,S],2U:[4,4,4],2V:[4,4,0],9:[4,4,4]};6 m=5(a){T(a&&a.1r("#")==-1&&a.1r("(")==-1){7"2W("+l[a].2X()+")"}2Y{7 a}};$.2Z($.30.31,{u:H,v:H,w:H,x:H});$.1s.32=5(){7 U.1t(5(){6 a=$(U);a.Z(a.B(\'1u\'))})};$.1s.Z=5(i){7 U.1t(5(){6 c=$(U),3,$8,C,14,15,16=k();T(c.B(\'V\')){7 11}6 e={I:(5(a){33(a){W"X":7"Y";W"Y":7"X";W"17":7"18";W"18":7"17";34:7"Y"}})(i.I),y:m(i.D)||"#E",D:m(i.y)||c.z("19-D"),1v:c.J(),F:i.F||1w,K:i.K||5(){},L:i.L||5(){},M:i.M||5(){}};c.B(\'1u\',e).B(\'V\',1).B(\'35\',e);3={s:c.s(),n:c.n(),y:m(i.y)||c.z("19-D"),1x:c.z("36-37")||"38",I:i.I||"X",G:m(i.D)||"#E",F:i.F||1w,o:c.1y().o,p:c.1y().p,1z:i.1v||39,9:"9",1a:i.1a||11,K:i.K||5(){},L:i.L||5(){},M:i.M||5(){}};16&&(3.9="#3a");$8=c.z("1b","3b").8(3c).B(\'V\',1).3d("1h").J("").z({1b:"1A",3e:"3f",p:3.p,o:3.o,3g:0,3h:3i});6 f=5(){7{1B:3.9,1x:0,3j:0,u:0,w:0,x:0,v:0,N:3.9,O:3.9,P:3.9,Q:3.9,19:"3k",3l:\'3m\',n:0,s:0}};6 g=5(){6 a=(3.n/13)*25;6 b=f();b.s=3.s;7{"q":b,"1c":{u:0,w:a,x:a,v:0,N:\'#E\',O:\'#E\',o:(3.o+(3.n/2)),p:(3.p-a)},"r":{v:0,u:0,w:0,x:0,N:3.9,O:3.9,o:3.o,p:3.p}}};6 h=5(){6 a=(3.n/13)*25;6 b=f();b.n=3.n;7{"q":b,"1c":{u:a,w:0,x:0,v:a,P:\'#E\',Q:\'#E\',o:3.o-a,p:3.p+(3.s/2)},"r":{u:0,w:0,x:0,v:0,P:3.9,Q:3.9,o:3.o,p:3.p}}};14={"X":5(){6 d=g();d.q.u=3.n;d.q.N=3.y;d.r.v=3.n;d.r.O=3.G;7 d},"Y":5(){6 d=g();d.q.v=3.n;d.q.O=3.y;d.r.u=3.n;d.r.N=3.G;7 d},"17":5(){6 d=h();d.q.w=3.s;d.q.P=3.y;d.r.x=3.s;d.r.Q=3.G;7 d},"18":5(){6 d=h();d.q.x=3.s;d.q.Q=3.y;d.r.w=3.s;d.r.P=3.G;7 d}};C=14[3.I]();16&&(C.q.3n="3o(D="+3.9+")");15=5(){6 a=3.1z;7 a&&a.1g?a.J():a};$8.1d(5(){3.K($8,c);$8.J(\'\').z(C.q);$8.1e()});$8.1C(C.1c,3.F);$8.1d(5(){3.M($8,c);$8.1e()});$8.1C(C.r,3.F);$8.1d(5(){T(!3.1a){c.z({1B:3.G})}c.z({1b:"1A"});6 a=15();T(a){c.J(a)}$8.3p();3.L($8,c);c.3q(\'V\');$8.1e()})})}})(3r);', 62, 214, '|||flipObj|255|function|var|return|clone|transparent||||||||||||||height|top|left|start|second|width|128|borderTopWidth|borderBottomWidth|borderLeftWidth|borderRightWidth|bgColor|css|139|data|dirOption|color|999|speed|toColor|int_prop|direction|html|onBefore|onEnd|onAnimation|borderTopColor|borderBottomColor|borderLeftColor|borderRightColor|211|192|if|this|flipLock|case|tb|bt|flip||false|169|100|dirOptions|newContent|ie6|lr|rl|background|dontChangeColor|visibility|first|queue|dequeue|style|jquery|body|240|245|165|42|107|140|230|224|144|indexOf|fn|each|flipRevertedSettings|content|500|fontSize|offset|target|visible|backgroundColor|animate|elem|prop|parseInt|now|unit|throw|name|js|plugin|error|message|cc_on|typeof|document|maxHeight|undefined|aqua|azure|beige|220|black|blue|brown|cyan|darkblue|darkcyan|darkgrey|darkgreen||darkkhaki|189|183|darkmagenta|darkolivegreen|85|47|darkorange|darkorchid|153|50|204|darkred|darksalmon|233|150|122|darkviolet|148|fuchsia|gold|215|green|indigo|75|130|khaki|lightblue|173|216|lightcyan|lightgreen|238|lightgrey|lightpink|182|193|lightyellow|lime|magenta|maroon|navy|olive|orange|pink|203|purple|violet|red|silver|white|yellow|rgb|toString|else|extend|fx|step|revertFlip|switch|default|flipSettings|font|size|12px|null|123456|hidden|true|appendTo|position|absolute|margin|zIndex|9999|lineHeight|none|borderStyle|solid|filter|chroma|remove|removeData|jQuery'.split('|'), 0, {}))


