public FilterDialog() { filterPanel = new FilterPanel(this.ById("FilterPanel")); filterPanel.ShowInitialLine = true; filterPanel.ShowSearchButton = false; filterPanel.UpdateStoreOnReset = false; }
protected override void AddFilterPanel(string text, object viewSiteControl) { if (!string.IsNullOrEmpty(text)) { ControlCollection collection = ((Control)viewSiteControl).Controls; var filterPanel = new FilterPanel(); filterPanel.Label.Text = text; collection.Add(filterPanel); } }
protected override void AddFilterPanel(string text, object viewSiteControl) { var filterPanel = new FilterPanel { BackColor = Color.LightGoldenrodYellow, Dock = DockStyle.Bottom, MaxRows = 25, TabIndex = 0, TabStop = false, MinimumSize = new Size(350, 33), Text = text }; Control.ControlCollection collection = ((Control) viewSiteControl).Controls; collection.Add(filterPanel); }
protected override void AddFilterPanel(string text, object viewSiteControl) { Control.ControlCollection controlCollection = ((Control)viewSiteControl).Controls; if (string.IsNullOrEmpty(text)) { FilterPanel filterPanel = controlCollection.OfType<FilterPanel>().FirstOrDefault(); if (filterPanel != null) controlCollection.Remove(filterPanel); } else { var filterPanel = new FilterPanel { BackColor = Color.LightGoldenrodYellow, Dock = DockStyle.Bottom, MaxRows = 25, TabIndex = 0, TabStop = false, MinimumSize = new Size(350, 33), Text = text }; Control.ControlCollection collection = controlCollection; collection.Add(filterPanel); } }