Ejemplo n.º 1
0
        /// <summary>
        /// Raises the ColorScheme changed event
        /// </summary>
        /// <param name="sender">The source of the event.</param>
        /// <param name="e">A EventArgs that contains the event data.</param>
        protected virtual void OnColorSchemeChanged(object sender, ColorSchemeChangeEventArgs e)
        {
            ColorScheme eColorScheme = e.ColorSchema;

            foreach (XPanderPanel xpanderPanel in this.XPanderPanels)
            {
                PropertyDescriptor propertyDescriptor = TypeDescriptor.GetProperties(xpanderPanel)["ColorScheme"];
                if (propertyDescriptor != null)
                {
                    propertyDescriptor.SetValue(xpanderPanel, eColorScheme);
                }
            }
            if (this.ColorSchemeChanged != null)
            {
                this.ColorSchemeChanged(sender, e);
            }
        }
Ejemplo n.º 2
0
 /// <summary>
 /// Raises the ColorScheme changed event
 /// </summary>
 /// <param name="sender">The source of the event.</param>
 /// <param name="e">A EventArgs that contains the event data.</param>
 protected virtual void OnColorSchemeChanged(object sender, ColorSchemeChangeEventArgs e)
 {
     this.PanelColors.Clear();
     this.Invalidate(false);
     if (this.ColorSchemeChanged != null)
     {
         this.ColorSchemeChanged(sender, e);
     }
 }
Ejemplo n.º 3
0
 /// <summary>
 /// Raises the ColorScheme changed event
 /// </summary>
 /// <param name="sender">The source of the event.</param>
 /// <param name="e">A EventArgs that contains the event data.</param>
 protected virtual void OnColorSchemeChanged(object sender, ColorSchemeChangeEventArgs e)
 {
     ColorScheme eColorScheme = e.ColorSchema;
     foreach (XPanderPanel xpanderPanel in this.XPanderPanels)
     {
         PropertyDescriptor propertyDescriptor = TypeDescriptor.GetProperties(xpanderPanel)["ColorScheme"];
         if (propertyDescriptor != null)
         {
             propertyDescriptor.SetValue(xpanderPanel, eColorScheme);
         }
     }
     if (this.ColorSchemeChanged != null)
     {
         this.ColorSchemeChanged(sender, e);
     }
 }