///<summary>Checks whether a column should be suppressed from automatic population.</summary> public static bool IsSuppressed(SmartGridColumn column) { if (column == null) { throw new ArgumentNullException("column"); } return(columnSuppressors.Any(s => s(column))); }
protected internal override void Apply(SmartGridColumn column) { column.OptionsColumn.AllowSort = DefaultBoolean.True; column.OptionsColumn.AllowGroup = DefaultBoolean.True; column.MaxWidth = 90; column.Caption = "Deposited"; column.OptionsColumn.AllowEdit = false; column.OptionsColumn.ReadOnly = true; }
///<summary>Applies this controller to a column.</summary> protected internal override void Apply(SmartGridColumn column) { column.OptionsColumn.ReadOnly = true; column.OptionsColumn.AllowSort = DefaultBoolean.True; column.OptionsColumn.AllowGroup = DefaultBoolean.True; column.ShowButtonMode = ShowButtonModeEnum.ShowAlways; column.ShowEditorOnMouseDown = true; column.AllowKeyboardActivation = false; if (AppFramework.Current.CanShowDetails <Person>()) { column.SetDefaultEditor(PersonEditSettings.Instance.CreateItem()); } else { column.OptionsColumn.AllowEdit = false; //Person fields should not be edited. Also, the default editor would show the native ToString, which is ugly. } if (column.Caption.StartsWith("Person", StringComparison.OrdinalIgnoreCase)) { column.Caption = "Full Name"; } }
///<summary>Gets the ColumnController instance for a field in a datasource.</summary> public static ColumnController GetController(SmartGridColumn gridColumn) { return(columnControllers.FirstOrDefault(kvp => kvp.Key(gridColumn)).Value); }
//No settings to apply protected internal override void Apply(SmartGridColumn column) { }
///<summary>Applies this controller to a column. This method should set the column's properties.</summary> protected internal override void Apply(SmartGridColumn column) { column.SetDefaultEditor(EditorRepository.CommentsPopupEditor.CreateItem()); }