Exemplo n.º 1
0
        /// <summary>
        /// Resets the control colors when the system colors change
        /// </summary>
        /// <param name="e">The object representing the event   </param>
        protected override void OnSystemColorsChanged(EventArgs e)
        {
            base.OnSystemColorsChanged(e);

            // This sets the background control for all this control and all of its children
            //this.BackColor = XHelperMethods.GetVsColor(XHelperMethods.Vs2010Color.VSCOLOR_BUTTONFACE);

            // The forecolor has to be set explicitly for each control
            XHelperMethods.SetControlTreeColors(this);
        }
        // =========================================================================================
        // Constructors
        // =========================================================================================

        /// <summary>
        /// Initializes a new instance of the <see cref="XBuildEventEditorForm"/> class.
        /// </summary>
        public XBuildEventEditorForm(IServiceProvider serviceProvider)
        {
            this.serviceProvider = serviceProvider;
            this.InitializeComponent();

            this.Font = XHelperMethods.GetDialogFont();

            //this.BackColor = XHelperMethods.GetVsColor(XHelperMethods.Vs2010Color.VSCOLOR_BUTTONFACE);
            XHelperMethods.SetControlTreeColors(this);
        }
Exemplo n.º 3
0
            // =========================================================================================
            // Methods
            // =========================================================================================

            /// <summary>
            /// Adds a control to the collection of child controls
            /// </summary>
            /// <param name="value">Control to be added</param>
            public override void Add(Control value)
            {
                base.Add(value);
                XHelperMethods.SetControlTreeColors(value);
            }