Module java.desktop

Class DefaultColorSelectionModel

java.lang.Object
javax.swing.colorchooser.DefaultColorSelectionModel
All Implemented Interfaces:
Serializable, ColorSelectionModel

public class DefaultColorSelectionModel extends Object implements ColorSelectionModel, Serializable
A generic implementation of ColorSelectionModel.
See Also:
  • Field Details

    • changeEvent

      protected transient ChangeEvent changeEvent
      Only one ChangeEvent is needed per model instance since the event's only (read-only) state is the source property. The source of events generated here is always "this".
    • listenerList

      protected EventListenerList listenerList
      The listener list.
  • Constructor Details

    • DefaultColorSelectionModel

      public DefaultColorSelectionModel()
      Creates a DefaultColorSelectionModel with the current color set to Color.white. This is the default constructor.
    • DefaultColorSelectionModel

      public DefaultColorSelectionModel(Color color)
      Creates a DefaultColorSelectionModel with the current color set to color, which should be non-null. Note that setting the color to null is undefined and may have unpredictable results.
      Parameters:
      color - the new Color
  • Method Details