//>>built
define("dojo/back","./_base/config,./_base/lang,./sniff,./dom,./dom-construct,./_base/window,require".split(","),function(h,y,j,z,A,B,t){function f(){var a=c.pop();if(a){var b=c[c.length-1];!b&&0==c.length&&(b=k);b&&(b.kwArgs.back?b.kwArgs.back():b.kwArgs.backButton?b.kwArgs.backButton():b.kwArgs.handle&&b.kwArgs.handle("back"));e.push(a)}}function n(){var a=e.pop();a&&(a.kwArgs.forward?a.kwArgs.forward():a.kwArgs.forwardButton?a.kwArgs.forwardButton():a.kwArgs.handle&&a.kwArgs.handle("forward"),
c.push(a))}function l(a,b,c){return{url:a,kwArgs:b,urlHash:c}}function o(a){a=a.split("?");return 2>a.length?null:a[1]}function u(){var a=(h.dojoIframeHistoryUrl||t.toUrl("./resources/iframe_history.html"))+"?"+(new Date).getTime();p=!0;if(i)j("webkit")?i.location=a:window.frames[i.name].location=a;return a}function C(){if(!q){var a=c.length,b=m();(b===v||window.location.href==w)&&1==a?f():0<e.length&&e[e.length-1].urlHash===b?n():2<=a&&c[a-2]&&c[a-2].urlHash===b&&f()}}var d={};y.setObject("dojo.back",
d);var m=d.getHash=function(){var a=window.location.hash;"#"==a.charAt(0)&&(a=a.substring(1));return j("mozilla")?a:decodeURIComponent(a)},r=d.setHash=function(a){a||(a="");window.location.hash=encodeURIComponent(a)},w="undefined"!==typeof window?window.location.href:"",v="undefined"!==typeof window?m():"",k=null,x=null,s=null,i=null,e=[],c=[],p=!1,q=!1;d.goBack=f;d.goForward=n;d.init=function(){if(!z.byId("dj_history")){var a=h.dojoIframeHistoryUrl||t.toUrl("./resources/iframe_history.html");h.afterOnLoad||
document.write('<iframe style="border:0;width:1px;height:1px;position:absolute;visibility:hidden;bottom:0;right:0;" name="dj_history" id="dj_history" src="'+a+'"></iframe>')}};d.setInitialState=function(a){k=l(w,a,v)};d.addToHistory=function(a){e=[];var b=null,d=null;i||(i=window.frames.dj_history);s||(s=A.create("a",{style:{display:"none"}},B.body()));if(a.changeUrl){b=""+(!0!==a.changeUrl?a.changeUrl:(new Date).getTime());if(0==c.length&&k.urlHash==b){k=l(d,a,b);return}if(0<c.length&&c[c.length-
1].urlHash==b){c[c.length-1]=l(d,a,b);return}q=!0;setTimeout(function(){r(b);q=!1},1);s.href=b;if(j("ie")){var d=u(),f=a.back||a.backButton||a.handle,g=function(a){""!=m()&&setTimeout(function(){r(b)},1);f.apply(this,[a])};if(a.back)a.back=g;else if(a.backButton)a.backButton=g;else if(a.handle)a.handle=g;var h=a.forward||a.forwardButton||a.handle,g=function(a){""!=m()&&r(b);h&&h.apply(this,[a])};if(a.forward)a.forward=g;else if(a.forwardButton)a.forwardButton=g;else if(a.handle)a.handle=g}else j("ie")||
x||(x=setInterval(C,200))}else d=u();c.push(l(d,a,b))};d._iframeLoaded=function(a,b){var d=o(b.href);null==d?1==c.length&&f():p?p=!1:2<=c.length&&d==o(c[c.length-2].url)?f():0<e.length&&d==o(e[e.length-1].url)&&n()};return d});