/// <summary> /// Initialize a new instance of the PaletteDataGridViewAll class. /// </summary> /// <param name="inherit">Source for inheriting values.</param> /// <param name="needPaint">Delegate for notifying paint requests.</param> public PaletteDataGridViewAll(PaletteDataGridViewRedirect inherit, NeedPaintHandler needPaint) : base(inherit, needPaint) { Debug.Assert(inherit != null); // Create storage that maps onto the inherit instances _background = new PaletteDouble(inherit.BackgroundDouble, needPaint); }
/// <summary> /// Initialize a new instance of the PaletteDataGridViewHeaders class. /// </summary> /// <param name="inherit">Source for inheriting values.</param> /// <param name="needPaint">Delegate for notifying paint requests.</param> public PaletteDataGridViewHeaders(PaletteDataGridViewRedirect inherit, NeedPaintHandler needPaint) { Debug.Assert(inherit != null); // Store the provided paint notification delegate NeedPaint = needPaint; // Create storage that maps onto the inherit instances _headerColumn = new PaletteDataGridViewTripleStates(inherit.HeaderColumn, needPaint); _headerRow = new PaletteDataGridViewTripleStates(inherit.HeaderRow, needPaint); }
/// <summary> /// Initialize a new instance of the KryptonPaletteGrid class. /// </summary> /// <param name="redirect">Redirector to inherit values from.</param> /// <param name="gridStyle">Grid style.</param> /// <param name="needPaint">Delegate for notifying paint requests.</param> public KryptonPaletteGrid(PaletteRedirect redirect, GridStyle gridStyle, NeedPaintHandler needPaint) { // Create the storage objects _stateCommon = new PaletteDataGridViewRedirect(redirect, needPaint); _stateDisabled = new PaletteDataGridViewAll(_stateCommon, needPaint); _stateNormal = new PaletteDataGridViewAll(_stateCommon, needPaint); _stateTracking = new PaletteDataGridViewHeaders(_stateCommon, needPaint); _statePressed = new PaletteDataGridViewHeaders(_stateCommon, needPaint); _stateSelected = new PaletteDataGridViewCells(_stateCommon, needPaint); }
/// <summary> /// Sets the inheritence parent. /// </summary> public virtual void SetInherit(PaletteDataGridViewRedirect inherit) { _headerColumn.SetInherit(inherit.HeaderColumn); _headerRow.SetInherit(inherit.HeaderRow); }
/// <summary> /// Sets the inheritence parent. /// </summary> public override void SetInherit(PaletteDataGridViewRedirect inherit) { base.SetInherit(inherit); _background.SetInherit(inherit.BackgroundDouble); }