var Tq=I.ea(I,"AdfDhtmlTogglePeer");m("AdfDhtmlTogglePeer",Tq);Tq.C=function(a){a&&(I.sb(this,a.oUa),I.ra(this,a.IRa));this.i6a=["toggledStyleClass","untoggledStyleClass"];this.i7a=["toggledTipResource","untoggledTipResource"];this.a_a="propertyName clientEventType ltrToggledIconName ltrUntoggledIconName rtlToggledIconName rtlUntoggledIconName".split(" ")};m("AdfDhtmlTogglePeer.InitSubclass",Tq.C);
Tq.Vs=function(a,b){for(var d=A.c.H(),e=a.prototype,f=Tq.i6a,g=f.length,h=0;h<g;h++){var l=f[h],n=b[l];n&&(e[l]=d.getStyleClass(n))}l=Tq.i7a;g=l.length;for(h=0;h<g;h++)if(f=l[h],n=b[f+"Key"])n=d.Z(n),u.J(n),e[f]=n;d=Tq.a_a;g=d.length;for(h=0;h<g;h++)l=d[h],l in b&&(e[l]=b[l])};m("AdfDhtmlTogglePeer.Config",Tq.Vs);Tq.prototype.xw=function(){u.fa()};r.a("AdfDhtmlTogglePeer.prototype.QueueClientEvent",{xw:Tq.prototype.xw});
Tq.prototype.vda=function(a){var b=this.tk();if(!b)return!1;var d=this.l_,e=this.r_,f=this.Ywb;a&&(f=d,d=e,e=f,f=this.Xwb);if(d)C.O(b,d),C.w(b,e);else if(b=this.Pba())if(d=this.Ura(a))b.src=d;this.fba(a);f&&(a=TrFastMessageFormatUtils.format(f,this.Hz()),this.gD(a),this.gba(a));return!0};r.a("AdfDhtmlTogglePeer.prototype.UpdateButton",{vda:Tq.prototype.vda});Tq.prototype.fba=function(a){var b=this.tk();q.b.setAttribute(b,"aria-expanded",a)};r.a("AdfDhtmlTogglePeer.prototype.ApplyAriaExpanded",{fba:Tq.prototype.fba});
Tq.prototype.gba=function(a){var b=this.tk();q.b.setAttribute(b,"aria-label",a)};r.a("AdfDhtmlTogglePeer.prototype.ApplyAriaLabel",{gba:Tq.prototype.gba});Tq.prototype.gD=function(a){var b=this.tk();q.b.setAttribute(b,"title",a)};r.a("AdfDhtmlTogglePeer.prototype.ApplyTitle",{gD:Tq.prototype.gD});Tq.prototype.Hz=function(){return this.f().K("text")};r.a("AdfDhtmlTogglePeer.prototype.GetTitle",{Hz:Tq.prototype.Hz});Tq.prototype.tk=function(){return this.i()};
r.a("AdfDhtmlTogglePeer.prototype.GetButtonElement",{tk:Tq.prototype.tk});Tq.prototype.Pba=function(){var a=this.tk();return a?a.firstChild:null};r.a("AdfDhtmlTogglePeer.prototype.GetButtonImageElement",{Pba:Tq.prototype.Pba});Tq.prototype.Ura=function(a){a=A.c.Ka().La()?a?this.Grb:this.Hrb:a?this.crb:this.drb;return(a=A.c.H().aZ(a))?a.src:null};r.a("AdfDhtmlTogglePeer.prototype.getIconURL",{Ura:Tq.prototype.Ura});Tq.prototype.fh=function(){return!0};
r.a("AdfDhtmlTogglePeer.prototype.EventPropagatesToServer",{fh:Tq.prototype.fh});Tq.prototype.JP=function(a){a=q.b.ca(a);a="A"!=a.tagName?a.parentNode:a;var b=this.tk();return b&&a==b};r.a("AdfDhtmlTogglePeer.prototype.isEventForButton",{JP:Tq.prototype.JP});Tq.prototype.Oh=function(a){return this.vda(a)};r.a("AdfDhtmlTogglePeer.prototype.HandleClientSideToggle",{Oh:Tq.prototype.Oh});
Tq.prototype.M=function(a){if(!a.Aa()){var b=a.U();if(a.ec()&&this.JP(b)){var d=!this.jR();this.xw(d,!0);q.b.preventDefault(b);a.cancel()}}};r.a("AdfDhtmlTogglePeer.prototype.HandleComponentClick",{M:Tq.prototype.M});Tq.prototype.za=function(a){if(!a.Aa()){var b=a.U();if(this.JP(b)){var d=q.b.na(b),e=this.jR();if(d==w.gd||d==w.ab&&!e||d==w.Ra&&e)this.xw(!e,!0),q.b.preventDefault(b),a.cancel()}}};r.a("AdfDhtmlTogglePeer.prototype.HandleComponentKeyUp",{za:Tq.prototype.za});
Tq.tda=function(a,b,d){this.ULa||this.xw(d,!0);return!0};m("AdfDhtmlTogglePeer.TogglePropertyChangedImpl",Tq.tda);Tq.qca=function(a){var b=this.f();if(!a.Aa()&&a.getSource()==b){this.ULa=!0;try{var d=this.dw(a);a.aa()||null==a.MO||null!=a.MO()?null==a.MO&&b.setProperty(this.propertyName,d,!0):b.setProperty(this.propertyName,d,!0);return this.Oh(d)}finally{delete this.ULa}}return!1};m("AdfDhtmlTogglePeer.HandleToggleEventImpl",Tq.qca);Tq.prototype.dw=function(){return!this.jR()};
r.a("AdfDhtmlTogglePeer.prototype.GetNewValueFromEvent",{dw:Tq.prototype.dw});Tq.prototype.jR=function(){return this.f().K(this.propertyName)};r.a("AdfDhtmlTogglePeer.prototype.GetPropertyValue",{jR:Tq.prototype.jR});