function Kh(a){Kh.h.constructor.call(this,a)}m("AdfDhtmlChooseDateNavigationPanelBase",Kh);r.v(Kh,Lh);Kh.prototype.kb=function(a,b){u.s(a,AdfRichChooseDate);u.u(b);return U.xva(a,b)?U.as(a,b,T.Kf):!0};r.a("AdfDhtmlChooseDateNavigationPanelBase.prototype.isVisible",{kb:Kh.prototype.kb});Kh.prototype.Xe=function(a,b){u.s(a,AdfRichChooseDate);u.s(b,na);return Kh.FF(b,T.ME)||Kh.FF(b,T.JE)?!0:!1};r.a("AdfDhtmlChooseDateNavigationPanelBase.prototype.canProcessDomUIInputEvent",{Xe:Kh.prototype.Xe});
Kh.prototype.re=function(a,b){u.s(a,AdfRichChooseDate);u.s(b,ha);return b instanceof Ih||b instanceof Ah};r.a("AdfDhtmlChooseDateNavigationPanelBase.prototype.canProcessComponentEvent",{re:Kh.prototype.re});Kh.prototype.os=function(a,b){return this.Lz(a,b)};r.a("AdfDhtmlChooseDateNavigationPanelBase.prototype.handleComponentClick",{os:Kh.prototype.os});Kh.prototype.Oi=function(a,b){var d=q.b.na(b.U());return d==w.gd||d==w.jb?this.Lz(a,b):!1};
r.a("AdfDhtmlChooseDateNavigationPanelBase.prototype.handleComponentKeyDown",{Oi:Kh.prototype.Oi});Kh.prototype.qc=function(a,b){u.s(a,AdfRichChooseDate);u.u(b);var d=A.c.H();if(0==b.children.length){var e=Qh.uc("td",{"class":d.getStyleClass("af|chooseDate::month-year-row"),align:"center",colspan:7},b);Wh(this,a,d,e);q.b.Ia(e);return this.Mv(a)}e=b.children[0];Wh(this,a,d,e);q.b.Ia(e);return[]};r.a("AdfDhtmlChooseDateNavigationPanelBase.prototype.render",{qc:Kh.prototype.qc});Kh.prototype.Mv=function(){return[]};
r.a("AdfDhtmlChooseDateNavigationPanelBase.prototype.ConstructNewRichComponents",{Mv:Kh.prototype.Mv});Kh.prototype.Lz=function(a,b){u.s(a,AdfRichChooseDate);u.s(b,ha);return Kh.FF(b,T.ME)?(Xh(this,a,!1),!0):Kh.FF(b,T.JE)?(Xh(this,a,!0),!0):!1};r.a("AdfDhtmlChooseDateNavigationPanelBase.prototype.HandleComponentEvent",{Lz:Kh.prototype.Lz});
Kh.prototype.At=function(a,b,d,e,f){u.s(a,AdfRichChooseDate);u.u(b);u.u(d);u.jf(e);u.Mb(f);a=C.Ou(d,T.O_a,"true","TD");u.u(a);a.textContent=f[e.getMonth()]+" "+e.getFullYear()};r.a("AdfDhtmlChooseDateNavigationPanelBase.prototype.UpdateGridHeader",{At:Kh.prototype.At});Kh.prototype.Us=function(a,b,d,e,f,g){d=Qh.uc("td",{"class":d.getStyleClass("af|chooseDate::month-year-label-cell"),"data-afr-mnt-yr-lbl":"true"},e);b=U.cb(a);a=U.Su(a,b).getMonths().slice(0,12);d.textContent=a[f]+" "+g};
r.a("AdfDhtmlChooseDateNavigationPanelBase.prototype.BuildCalendarLabelForMonth",{Us:Kh.prototype.Us});Kh.prototype.uw=function(a,b,d,e){u.s(a,AdfRichChooseDate);u.dc(e);var f=d.getMonth();d=d.getFullYear();a=Math.min(12,U.Vp(a,b));f=e?f+a:f-a;e=0;0>f?(f+=12,e=-1):11<f&&(f-=12,e=1);e&&(d+=e);return{month:f,year:d}};r.a("AdfDhtmlChooseDateNavigationPanelBase.prototype.ManipulateMonth",{uw:Kh.prototype.uw});Kh.prototype.ED=function(a,b){b.setMonth(b.getMonth()+1);return b};
r.a("AdfDhtmlChooseDateNavigationPanelBase.prototype.GetNextDisplayedMonth",{ED:Kh.prototype.ED});Kh.prototype.DD=function(a){return U.IH(a)};r.a("AdfDhtmlChooseDateNavigationPanelBase.prototype.GetMonthDisplayRange",{DD:Kh.prototype.DD});
function Wh(a,b,d,e){if(0!=e.children.length){u.s(b,AdfRichChooseDate);u.u(e);var f=a.DD(b);d=f.months;u.assert(e.children.length==d);for(var f=f.start,g=U.cb(b),h=U.Su(b,g).getMonths().slice(0,12),l=0;l<d;l++){var n=a,t=b,y=g,z=e.children[l],B=f,F=h;u.s(t,AdfRichChooseDate);u.u(y);u.u(z);u.jf(B);q.b.setAttribute(z,T.on,B.getFullYear()+"-"+B.getMonth());n.At(t,y,z,B,F);f=a.ED(b,f)}}else for(g=a.DD(b),f=g.months,g=g.start,h=0;h<f;h++)e.appendChild(Yh(a,b,d,g.getMonth(),g.getFullYear(),0==h,h==f-1)),
g=a.ED(b,g)}function Xh(a,b,d){var e=U.cb(b),f=U.mf(b,e);a=a.uw(b,e,f,d);d=a.year;f.setMonth(a.month);f.setFullYear(d);Ah.F(b,f)}
function Yh(a,b,d,e,f,g,h){var l=U.cb(b),n=d.getStyleClass("af|chooseDate::month-year-header"),t=U.mf(b,l),y=U.Vp(b,l);f==t.getFullYear()&&e==t.getMonth()&&1<y&&(n+=" "+T.s2);n=Qh.ck("table",{"data-afr-yyyymm":f+"-"+e,"class":n,cellpadding:"0",cellspacing:"0",border:"0",summary:"",role:"presentation"});t=Qh.uc("tbody",{},n);t=Qh.uc("tr",{},t);g?Kh.Z$a(b,d,t):Kh.$$a(d,t);a.Us(b,l,d,t,e,f);h?Kh.U$a(b,d,t):Kh.V$a(d,t);return n}
Kh.Z$a=function(a,b,d){d=Qh.uc("td",{"class":b.getStyleClass("af|chooseDate::prev-month-arrow-cell")},d);var e=b.Z("af_chooseDate.TIP_PREVIOUS_MONTH");a=a.g();Qh.uc("a",{role:"button","aria-label":e,href:"#",onclick:"this.focus(); return false","class":b.getStyleClass("af|chooseDate::prev-month-arrow"),id:I.j(a,T.ME),title:e},d)};Kh.$$a=function(a,b){Qh.uc("td",{"class":a.getStyleClass("af|chooseDate::prev-month-arrow-stub-cell")},b)};
Kh.U$a=function(a,b,d){d=Qh.uc("td",{"class":b.getStyleClass("af|chooseDate::next-month-arrow-cell")},d);var e=b.Z("af_chooseDate.TIP_NEXT_MONTH");a=a.g();Qh.uc("a",{role:"button","aria-label":e,href:"#",onclick:"this.focus();return false","class":b.getStyleClass("af|chooseDate::next-month-arrow"),id:I.j(a,T.JE),title:e},d)};Kh.V$a=function(a,b){Qh.uc("td",{"class":a.getStyleClass("af|chooseDate::next-month-arrow-stub-cell")},b)};
Kh.FF=function(a,b){var d=a.X(),e=a.he(),e=I.j(e.g(),b);return C.Nb(q.b.getElementById(e),d)};