using System; using System.Web; using System.Web.UI; using System.Web.UI.WebControls; using CMS.GlobalHelper; using CMS.PortalControls; public partial class CMSWebParts_Filters_DocumentNameFilter : CMSAbstractWebPart { #region "Public properties" /// /// Gets or sets the filter button text. /// public string ButtonText { get { return ValidationHelper.GetString(GetValue("ButtonText"), string.Empty); } set { SetValue("ButtonText", value); filterDocuments.ButtonText = value; } } /// /// Gets or sets the button css class. /// public string ButtonCssClass { get { return ValidationHelper.GetString(GetValue("ButtonCssClass"), string.Empty); } set { SetValue("ButtonCssClass", value); filterDocuments.ButtonCssClass = value; } } /// /// Gets or sets the label text. /// public string LabelText { get { return ValidationHelper.GetString(GetValue("LabelText"), string.Empty); } set { SetValue("LabelText", value); filterDocuments.LabelText = value; } } /// /// Gets or sets the label css class. /// public string LabelCssClass { get { return ValidationHelper.GetString(GetValue("LabelCssClass"), string.Empty); } set { SetValue("LabelCssClass", value); filterDocuments.LabelCssClass = value; } } /// /// Gets or sets the textbox css class. /// public string TextBoxCssClass { get { return ValidationHelper.GetString(GetValue("TextBoxCssClass"), string.Empty); } set { SetValue("TextBoxCssClass", value); filterDocuments.TextBoxCssClass = value; } } #endregion #region "Methods" /// /// Content loaded event handler. /// public override void OnContentLoaded() { base.OnContentLoaded(); SetupControl(); } /// /// Initializes the control properties. /// public void SetupControl() { if (StopProcessing) { // Do nothing } else { filterDocuments.FilterName = ValidationHelper.GetString(GetValue("WebPartControlID"), string.Empty); filterDocuments.ButtonText = ButtonText; filterDocuments.ButtonCssClass = ButtonCssClass; filterDocuments.LabelText = LabelText; filterDocuments.LabelCssClass = LabelCssClass; filterDocuments.TextBoxCssClass = TextBoxCssClass; } } #endregion }