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())}}};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(C){var B=$(C.id.substring(3));if(!B){return }if(C.id=="tab"+A){C.addClassName("activeTab");B.show()}else{C.removeClassName("activeTab");B.hide()}});return false};