Esempio n. 1
0
        /// <summary>
        /// Initialize a new instance of the PaletteTripleJustImageRedirect class.
        /// </summary>
        /// <param name="redirect">Inheritence redirection instance.</param>
        /// <param name="backStyle">Initial background style.</param>
        /// <param name="borderStyle">Initial border style.</param>
        /// <param name="contentStyle">Initial content style.</param>
        /// <param name="needPaint">Delegate for notifying paint requests.</param>
        public PaletteTripleJustImageRedirect(PaletteRedirect redirect,
                                              PaletteBackStyle backStyle,
                                              PaletteBorderStyle borderStyle,
                                              PaletteContentStyle contentStyle,
                                              NeedPaintHandler needPaint)
        {
            // Store the provided paint notification delegate
            NeedPaint = needPaint;

            // Store the inherit instances
            _backInherit    = new PaletteBackInheritRedirect(redirect, backStyle);
            _borderInherit  = new PaletteBorderInheritRedirect(redirect, borderStyle);
            _contentInherit = new PaletteContentInheritRedirect(redirect, contentStyle);

            // Create storage that maps onto the inherit instances
            Back    = new PaletteBack(_backInherit, needPaint);
            Border  = new PaletteBorder(_borderInherit, needPaint);
            Content = new PaletteContentJustImage(_contentInherit, needPaint);
        }
Esempio n. 2
0
        /// <summary>
        /// Initialize a new instance of the PaletteTreeStateRedirect class.
        /// </summary>
        /// <param name="redirect">Inheritence redirection instance.</param>
        /// <param name="back">Storage for back values.</param>
        /// <param name="backInherit">Inheritence for back values.</param>
        /// <param name="border">Storage for border values.</param>
        /// <param name="borderInherit">Inheritence for border values.</param>
        /// <param name="needPaint">Delegate for notifying paint requests.</param>
        public PaletteTreeStateRedirect(PaletteRedirect redirect,
                                        PaletteBack back,
                                        PaletteBackInheritRedirect backInherit,
                                        PaletteBorder border,
                                        PaletteBorderInheritRedirect borderInherit,
                                        NeedPaintHandler needPaint)
            : base(redirect, back, backInherit, border, borderInherit, needPaint)
        {
            Debug.Assert(redirect != null);

            // Remember the redirect reference
            _redirect = redirect;

            // Create the item redirector
            Node = new PaletteTripleRedirect(redirect,
                                             PaletteBackStyle.ButtonListItem,
                                             PaletteBorderStyle.ButtonListItem,
                                             PaletteContentStyle.ButtonListItem,
                                             needPaint);
        }
Esempio n. 3
0
        /// <summary>
        /// Initialize a new instance of the PaletteDataGridViewTripleRedirect class.
        /// </summary>
        /// <param name="redirect">Inheritence redirection instance.</param>
        /// <param name="backStyle">Initial background style.</param>
        /// <param name="borderStyle">Initial border style.</param>
        /// <param name="contentStyle">Initial content style.</param>
        /// <param name="needPaint">Delegate for notifying paint requests.</param>
        public PaletteDataGridViewTripleRedirect(PaletteRedirect redirect,
                                                 PaletteBackStyle backStyle,
                                                 PaletteBorderStyle borderStyle,
                                                 PaletteContentStyle contentStyle,
                                                 NeedPaintHandler needPaint)
        {
            Debug.Assert(redirect != null);

            // Store the provided paint notification delegate
            NeedPaint = needPaint;

            // Store the inherit instances
            _backInherit    = new PaletteBackInheritRedirect(redirect, backStyle);
            _borderInherit  = new PaletteBorderInheritRedirect(redirect, borderStyle);
            _contentInherit = new PaletteContentInheritRedirect(redirect, contentStyle);

            // Create storage that maps onto the inherit instances
            Back    = new PaletteBack(_backInherit, needPaint);
            Border  = new PaletteBorder(_borderInherit, needPaint);
            Content = new PaletteDataGridViewContentCommon(_contentInherit, needPaint);
        }