if((typeof Secondsight)==="undefined"){Secondsight={};}if((typeof Secondsight.UI)==="undefined"){Secondsight.UI={};}Secondsight.UI.Menu=function(c,a,b){return(function(g,f,n){var l={},e=(g instanceof jQuery)?g:$(g),m=(f instanceof jQuery)?f:$(f),k=e.children(".rootGroup"),i,h;h=$.extend(true,{},Secondsight.UI.Menu.defaults,n);function j(){var q=k.children("li.menuItem"),o,p,r=false;q.each(function(){o=$(this);if(o.hasClass("match")){p=o.children("ul.subGroup");if((p)&&(p.length>0)){p.remove().appendTo(e).show();if(!r){m.addClass(h.expandedClass);r=true;}}}});}function d(){var x=k.find("a.link"),u,y,o,q,p,r,w=new Abl.Uri(),s=false,t=i.getFolder(),v=i.getPath();x.each(function(){u=$(this);o=u.attr("href");w.setUri(this.href);q=w.getFolder();p=w.getPath();if((o)&&(typeof o==="string")&&(o.substr(0,1)!=="#")){if((t.length>1)&&(q.length>1)&&(w.compare(i,"folder",true))){u.parent().andSelf().addClass("match folderMatch");s=true;if(((v.substr(v.length-1,1)==="/")&&(w.getFile().toLowerCase()==="default.aspx")&&(w.compare(i,"folder",false)))||(w.compare(i,"path"))){s=true;u.parent("li.menuItem").andSelf().addClass("match exactMatch");y=u.parent("li.menuItem").parents("li.menuItem");if((y)&&(y.length>0)){for(r=0;r<y.length;r++){y.eq(r).children("a.link").andSelf().addClass("match targetTrail");}}}}}});}l.init=function(){i=new Abl.Uri();d();j();};l.dispose=function(){};return l;}(c,a,b));};Secondsight.UI.Menu.defaults={expandedClass:"expanded"};
