1. /*
  2. * @(#)ColorChooserComponentFactory.java 1.12 01/11/29
  3. *
  4. * Copyright 2002 Sun Microsystems, Inc. All rights reserved.
  5. * SUN PROPRIETARY/CONFIDENTIAL. Use is subject to license terms.
  6. */
  7. package javax.swing.colorchooser;
  8. import javax.swing.*;
  9. /**
  10. * A class designed to produce preconfigured "accessory" objects to
  11. * insert into color choosers.
  12. *
  13. * <p>
  14. * <strong>Warning:</strong>
  15. * Serialized objects of this class will not be compatible with
  16. * future Swing releases. The current serialization support is appropriate
  17. * for short term storage or RMI between applications running the same
  18. * version of Swing. A future release of Swing will provide support for
  19. * long term persistence.
  20. *
  21. * @version 1.12 11/29/01
  22. * @author Steve Wilson
  23. */
  24. public class ColorChooserComponentFactory {
  25. private ColorChooserComponentFactory() { } // can't instantiate
  26. public static AbstractColorChooserPanel[] getDefaultChooserPanels() {
  27. AbstractColorChooserPanel[] choosers = { new DefaultSwatchChooserPanel(),
  28. new DefaultHSBChooserPanel(),
  29. new DefaultRGBChooserPanel() };
  30. return choosers;
  31. }
  32. public static JComponent getPreviewPanel() {
  33. return new DefaultPreviewPanel();
  34. }
  35. }