var eventTabs=null;var Views={hash:$H(),keys:[],get:function(a){return this.hash.get(a)},push:function(a,b){this.hash.set(a,b);this.keys.push(a);if(this.hash.size()>10){this.hash.unset(this.keys.pop())}},invalidate:function(){this.hash=$H();this.keys=[]}};function ShowView(a,d,b){if(Object.isUndefined(Ajax.Updater)){return true}if(Object.isUndefined(b)){b=true}var e=$H({view:a});if(typeof d=="object"){e.update(d)}else{e.set("timestamp",d)}var c=KronolithVar.view_url+(KronolithVar.view_url.include("?")?"&":"?")+e.toQueryString();if(Views.get(c)){$("page").update(Views.get(c));_ShowView()}else{$("page").appendChild(new Element("DIV",{id:"pageLoading"}).update(KronolithText.loading));$("pageLoading").clonePosition("page");new Effect.Opacity("pageLoading",{from:0,to:0.5});if(b){new Ajax.Updater("page",c,{onComplete:function(){Views.push(c,$("page").innerHTML);_ShowView()}})}else{new Ajax.Updater("page",c,{onComplete:_ShowView})}}return false}function _ShowView(){if(Object.isFunction(stripeAllElements)){stripeAllElements()}if(typeof ToolTips=="object"){ToolTips.out();ToolTips.attachBehavior()}var b=$("view_title");if(b&&b.firstChild&&b.firstChild.nodeValue){var d=KronolithVar.page_title+b.firstChild.nodeValue;try{document.title=d;if(parent.frames.horde_main){parent.document.title=d}}catch(c){}}var a=$("view_vars");if(a){kronolithView=a.readAttribute("view");kronolithTimestamp=a.readAttribute("timestamp");kronolithPrintLink=a.readAttribute("print")}}function ShowTab(a){if(eventTabs==null){eventTabs=$("page").select(".tabset ul li")}eventTabs.each(function(d){var b=$(d.id.substring(3));if(!b){return}if(d.id=="tab"+a){d.addClassName("activeTab");b.show()}else{d.removeClassName("activeTab");b.hide()}});return false};