Ext.Net.ButtonBase.OnBeforeClientInit C# (CSharp) Method

OnBeforeClientInit() private method

private OnBeforeClientInit ( Observable sender ) : void
sender Observable
return void
        protected override void OnBeforeClientInit(Observable sender)
        {
            base.OnBeforeClientInit(sender);
            
            if (this.OnClientClick.IsNotEmpty())
            {
                this.Handler = new JFunction(TokenUtils.ParseTokens(this.OnClientClick, this), "el", "e").ToScript();
            }

            string fn = this.PostBackFunction;

            if (this.ParentForm != null && fn.IsNotEmpty())
            {
                this.CustomConfig.Add(new ConfigItem("postback", JSON.Serialize(new { eventName = "click", fn = new JFunction(fn) }), ParameterMode.Raw));
            }

            if (this.StandOut)
            {
                if (this.Icon != Icon.None || this.IconCls.IsNotEmpty())
                {
                    this.Cls = (this.Text.IsEmpty() ? "x-btn-icon" : "x-btn-text-icon") + " x-btn-over";
                }
                else
                {
                    this.Cls = "x-btn-over";
                }
            }
        }