/hg/release/icedtea7-forest-2.3/jdk: 4 new changesets

andrew at icedtea.classpath.org andrew at icedtea.classpath.org
Thu Aug 30 12:27:11 PDT 2012


changeset 8a226f6a768a in /hg/release/icedtea7-forest-2.3/jdk
details: http://icedtea.classpath.org/hg/release/icedtea7-forest-2.3/jdk?cmd=changeset;node=8a226f6a768a
author: malenkov
date: Thu Aug 30 18:56:09 2012 +0100

	7162473: ConstructorFinder/FieldFinder/MethodFinder gives access to restricted classes
	Reviewed-by: art, ahgross


changeset 2d21460a0530 in /hg/release/icedtea7-forest-2.3/jdk
details: http://icedtea.classpath.org/hg/release/icedtea7-forest-2.3/jdk?cmd=changeset;node=2d21460a0530
author: malenkov
date: Tue Jun 19 21:04:48 2012 +0400

	7162476: XMLDecoder security issue via ClassFinder
	Reviewed-by: art, ahgross


changeset 6df0f825c24e in /hg/release/icedtea7-forest-2.3/jdk
details: http://icedtea.classpath.org/hg/release/icedtea7-forest-2.3/jdk?cmd=changeset;node=6df0f825c24e
author: bagiras
date: Tue Jun 19 14:08:24 2012 +0400

	7163201: Simplify toolkit internals references
	Reviewed-by: art, anthony, ahgross


changeset 5f709891901c in /hg/release/icedtea7-forest-2.3/jdk
details: http://icedtea.classpath.org/hg/release/icedtea7-forest-2.3/jdk?cmd=changeset;node=5f709891901c
author: malenkov
date: Tue Aug 28 12:00:26 2012 -0700

	7194567: Improve long term persistence of java.beans objects
	Reviewed-by: ahgross, art


diffstat:

 make/sun/Makefile                                                    |    2 +-
 make/sun/beans/Makefile                                              |   43 -
 src/macosx/classes/sun/lwawt/macosx/LWCToolkit.java                  |   12 +-
 src/share/classes/com/sun/beans/decoder/MethodElementHandler.java    |    6 +-
 src/share/classes/com/sun/beans/editors/BooleanEditor.java           |   76 +
 src/share/classes/com/sun/beans/editors/ByteEditor.java              |   48 +
 src/share/classes/com/sun/beans/editors/ColorEditor.java             |  214 +++++
 src/share/classes/com/sun/beans/editors/DoubleEditor.java            |   41 +
 src/share/classes/com/sun/beans/editors/EnumEditor.java              |  143 +++
 src/share/classes/com/sun/beans/editors/FloatEditor.java             |   48 +
 src/share/classes/com/sun/beans/editors/FontEditor.java              |  219 +++++
 src/share/classes/com/sun/beans/editors/IntegerEditor.java           |   42 +
 src/share/classes/com/sun/beans/editors/LongEditor.java              |   48 +
 src/share/classes/com/sun/beans/editors/NumberEditor.java            |   44 +
 src/share/classes/com/sun/beans/editors/ShortEditor.java             |   49 +
 src/share/classes/com/sun/beans/editors/StringEditor.java            |   74 +
 src/share/classes/com/sun/beans/finder/BeanInfoFinder.java           |    8 +-
 src/share/classes/com/sun/beans/finder/ClassFinder.java              |    6 +-
 src/share/classes/com/sun/beans/finder/ConstructorFinder.java        |    7 +-
 src/share/classes/com/sun/beans/finder/FieldFinder.java              |    8 +-
 src/share/classes/com/sun/beans/finder/MethodFinder.java             |    7 +-
 src/share/classes/com/sun/beans/finder/PropertyEditorFinder.java     |   28 +-
 src/share/classes/com/sun/beans/infos/ComponentBeanInfo.java         |   62 +
 src/share/classes/java/awt/AWTEvent.java                             |   13 +-
 src/share/classes/java/awt/CheckboxMenuItem.java                     |    8 +
 src/share/classes/java/awt/Cursor.java                               |   20 +-
 src/share/classes/java/awt/DefaultKeyboardFocusManager.java          |   10 +
 src/share/classes/java/awt/EventQueue.java                           |   12 +-
 src/share/classes/java/awt/KeyboardFocusManager.java                 |    4 +-
 src/share/classes/java/awt/Menu.java                                 |    8 +
 src/share/classes/java/awt/MenuBar.java                              |   11 +
 src/share/classes/java/awt/MenuComponent.java                        |    4 +-
 src/share/classes/java/awt/MenuItem.java                             |   25 +-
 src/share/classes/java/awt/ScrollPaneAdjustable.java                 |    9 +
 src/share/classes/java/awt/SystemTray.java                           |   13 +
 src/share/classes/java/awt/TrayIcon.java                             |   20 +-
 src/share/classes/java/awt/event/KeyEvent.java                       |   19 +-
 src/share/classes/javax/swing/ClientPropertyKey.java                 |   11 +
 src/share/classes/sun/awt/AWTAccessor.java                           |  418 +++++++++-
 src/share/classes/sun/awt/EmbeddedFrame.java                         |   71 +-
 src/share/classes/sun/awt/SunToolkit.java                            |  123 +--
 src/share/classes/sun/beans/editors/BooleanEditor.java               |   76 -
 src/share/classes/sun/beans/editors/ByteEditor.java                  |   48 -
 src/share/classes/sun/beans/editors/ColorEditor.java                 |  214 -----
 src/share/classes/sun/beans/editors/DoubleEditor.java                |   41 -
 src/share/classes/sun/beans/editors/EnumEditor.java                  |  143 ---
 src/share/classes/sun/beans/editors/FloatEditor.java                 |   48 -
 src/share/classes/sun/beans/editors/FontEditor.java                  |  219 -----
 src/share/classes/sun/beans/editors/IntegerEditor.java               |   42 -
 src/share/classes/sun/beans/editors/LongEditor.java                  |   48 -
 src/share/classes/sun/beans/editors/NumberEditor.java                |   44 -
 src/share/classes/sun/beans/editors/ShortEditor.java                 |   49 -
 src/share/classes/sun/beans/editors/StringEditor.java                |   74 -
 src/share/classes/sun/beans/infos/ComponentBeanInfo.java             |   62 -
 src/solaris/classes/sun/awt/X11/XCheckboxMenuItemPeer.java           |   29 +-
 src/solaris/classes/sun/awt/X11/XEmbedCanvasPeer.java                |   18 +-
 src/solaris/classes/sun/awt/X11/XEmbeddingContainer.java             |   16 +-
 src/solaris/classes/sun/awt/X11/XGlobalCursorManager.java            |   26 +-
 src/solaris/classes/sun/awt/X11/XMenuBarPeer.java                    |   28 +-
 src/solaris/classes/sun/awt/X11/XMenuItemPeer.java                   |   72 +-
 src/solaris/classes/sun/awt/X11/XMenuPeer.java                       |   20 +-
 src/solaris/classes/sun/awt/X11/XPopupMenuPeer.java                  |   59 +-
 src/solaris/classes/sun/awt/X11/XScrollPanePeer.java                 |   16 +-
 src/solaris/classes/sun/awt/X11/XSystemTrayPeer.java                 |   49 +-
 src/solaris/classes/sun/awt/X11/XTextAreaPeer.java                   |    6 +-
 src/solaris/classes/sun/awt/X11/XTextFieldPeer.java                  |    6 +-
 src/solaris/classes/sun/awt/X11/XTextTransferHelper.java             |   47 -
 src/solaris/classes/sun/awt/X11/XToolkit.java                        |   30 +-
 src/solaris/classes/sun/awt/X11/XWindow.java                         |   48 +-
 src/solaris/classes/sun/awt/X11/XlibWrapper.java                     |   12 +-
 src/windows/classes/sun/awt/windows/WCanvasPeer.java                 |    1 -
 src/windows/classes/sun/awt/windows/WMouseDragGestureRecognizer.java |    2 -
 src/windows/classes/sun/awt/windows/WPopupMenuPeer.java              |    2 -
 src/windows/classes/sun/awt/windows/WWindowPeer.java                 |    2 -
 test/java/beans/Introspector/4520754/Test4520754.java                |    4 +-
 test/java/beans/PropertyEditor/6380849/TestPropertyEditor.java       |   24 +-
 test/java/beans/PropertyEditor/Test6963811.java                      |    4 +-
 77 files changed, 1845 insertions(+), 1818 deletions(-)

diffs (truncated from 5010 to 500 lines):

diff -r 507eee662587 -r 5f709891901c make/sun/Makefile
--- a/make/sun/Makefile	Wed Aug 29 17:57:30 2012 +0100
+++ b/make/sun/Makefile	Tue Aug 28 12:00:26 2012 -0700
@@ -87,7 +87,7 @@
 endif
 SUBDIRS_desktop    = audio $(RENDER_SUBDIR) image \
                      $(LWAWT_PRE_SUBDIR) $(DISPLAY_LIBS) $(DGA_SUBDIR) $(LWAWT_SUBDIR) \
-                     jawt font jpeg cmm $(DISPLAY_TOOLS) beans
+                     jawt font jpeg cmm $(DISPLAY_TOOLS)
 SUBDIRS_management = management
 SUBDIRS_misc       = $(ORG_SUBDIR) rmi $(JDBC_SUBDIR) tracing
 SUBDIRS_tools      = native2ascii serialver tools jconsole
diff -r 507eee662587 -r 5f709891901c make/sun/beans/Makefile
--- a/make/sun/beans/Makefile	Wed Aug 29 17:57:30 2012 +0100
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,43 +0,0 @@
-#
-# Copyright (c) 1997, 2005, Oracle and/or its affiliates. All rights reserved.
-# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
-#
-# This code is free software; you can redistribute it and/or modify it
-# under the terms of the GNU General Public License version 2 only, as
-# published by the Free Software Foundation.  Oracle designates this
-# particular file as subject to the "Classpath" exception as provided
-# by Oracle in the LICENSE file that accompanied this code.
-#
-# This code is distributed in the hope that it will be useful, but WITHOUT
-# ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
-# FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
-# version 2 for more details (a copy is included in the LICENSE file that
-# accompanied this code).
-#
-# You should have received a copy of the GNU General Public License version
-# 2 along with this work; if not, write to the Free Software Foundation,
-# Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
-#
-# Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
-# or visit www.oracle.com if you need additional information or have any
-# questions.
-#
-
-#
-# Makefile for building sun.beans.*
-#
-
-BUILDDIR = ../..
-PACKAGE = sun.beans
-PRODUCT = sun
-include $(BUILDDIR)/common/Defs.gmk
-
-#
-# Files
-#
-AUTO_FILES_JAVA_DIRS = sun/beans
-
-#
-# Rules
-#
-include $(BUILDDIR)/common/Classes.gmk
diff -r 507eee662587 -r 5f709891901c src/macosx/classes/sun/lwawt/macosx/LWCToolkit.java
--- a/src/macosx/classes/sun/lwawt/macosx/LWCToolkit.java	Wed Aug 29 17:57:30 2012 +0100
+++ b/src/macosx/classes/sun/lwawt/macosx/LWCToolkit.java	Tue Aug 28 12:00:26 2012 -0700
@@ -90,14 +90,6 @@
         }
     }
 
-    static String getSystemProperty(final String name, final String deflt) {
-        return AccessController.doPrivileged (new PrivilegedAction<String>() {
-            public String run() {
-                return System.getProperty(name, deflt);
-            }
-        });
-    }
-
     public LWCToolkit() {
         SunToolkit.setDataTransfererClassName("sun.lwawt.macosx.CDataTransferer");
 
@@ -709,8 +701,8 @@
      */
     public synchronized static boolean getSunAwtDisableCALayers() {
         if (sunAwtDisableCALayers == null) {
-            sunAwtDisableCALayers =
-            getBooleanSystemProperty("sun.awt.disableCALayers");
+            sunAwtDisableCALayers = AccessController.doPrivileged(
+                new GetBooleanAction("sun.awt.disableCALayers")));
         }
         return sunAwtDisableCALayers.booleanValue();
     }
diff -r 507eee662587 -r 5f709891901c src/share/classes/com/sun/beans/decoder/MethodElementHandler.java
--- a/src/share/classes/com/sun/beans/decoder/MethodElementHandler.java	Wed Aug 29 17:57:30 2012 +0100
+++ b/src/share/classes/com/sun/beans/decoder/MethodElementHandler.java	Tue Aug 28 12:00:26 2012 -0700
@@ -1,5 +1,5 @@
 /*
- * Copyright (c) 2008, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2008, 2012, Oracle and/or its affiliates. All rights reserved.
  * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
  *
  * This code is free software; you can redistribute it and/or modify it
@@ -28,6 +28,8 @@
 
 import java.lang.reflect.Method;
 
+import sun.reflect.misc.MethodUtil;
+
 /**
  * This class is intended to handle &lt;method&gt; element.
  * It describes invocation of the method.
@@ -101,7 +103,7 @@
         if (method.isVarArgs()) {
             args = getArguments(args, method.getParameterTypes());
         }
-        Object value = method.invoke(bean, args);
+        Object value = MethodUtil.invoke(method, bean, args);
         return method.getReturnType().equals(void.class)
                 ? ValueObjectImpl.VOID
                 : ValueObjectImpl.create(value);
diff -r 507eee662587 -r 5f709891901c src/share/classes/com/sun/beans/editors/BooleanEditor.java
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/src/share/classes/com/sun/beans/editors/BooleanEditor.java	Tue Aug 28 12:00:26 2012 -0700
@@ -0,0 +1,76 @@
+/*
+ * Copyright (c) 2006, 2012, Oracle and/or its affiliates. All rights reserved.
+ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+ *
+ * This code is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU General Public License version 2 only, as
+ * published by the Free Software Foundation.  Oracle designates this
+ * particular file as subject to the "Classpath" exception as provided
+ * by Oracle in the LICENSE file that accompanied this code.
+ *
+ * This code is distributed in the hope that it will be useful, but WITHOUT
+ * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
+ * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
+ * version 2 for more details (a copy is included in the LICENSE file that
+ * accompanied this code).
+ *
+ * You should have received a copy of the GNU General Public License version
+ * 2 along with this work; if not, write to the Free Software Foundation,
+ * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
+ *
+ * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
+ * or visit www.oracle.com if you need additional information or have any
+ * questions.
+ */
+
+package com.sun.beans.editors;
+
+/**
+ * Property editor for a java builtin "boolean" type.
+ */
+
+import java.beans.*;
+
+public class BooleanEditor extends PropertyEditorSupport {
+
+
+    public String getJavaInitializationString() {
+        Object value = getValue();
+        return (value != null)
+                ? value.toString()
+                : "null";
+    }
+
+    public String getAsText() {
+        Object value = getValue();
+        return (value instanceof Boolean)
+             ? getValidName((Boolean) value)
+             : null;
+    }
+
+    public void setAsText(String text) throws java.lang.IllegalArgumentException {
+        if (text == null) {
+            setValue(null);
+        } else if (isValidName(true, text)) {
+            setValue(Boolean.TRUE);
+        } else if (isValidName(false, text)) {
+            setValue(Boolean.FALSE);
+        } else {
+            throw new java.lang.IllegalArgumentException(text);
+        }
+    }
+
+    public String[] getTags() {
+        return new String[] {getValidName(true), getValidName(false)};
+    }
+
+    // the following method should be localized (4890258)
+
+    private String getValidName(boolean value) {
+        return value ? "True" : "False";
+    }
+
+    private boolean isValidName(boolean value, String name) {
+        return getValidName(value).equalsIgnoreCase(name);
+    }
+}
diff -r 507eee662587 -r 5f709891901c src/share/classes/com/sun/beans/editors/ByteEditor.java
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/src/share/classes/com/sun/beans/editors/ByteEditor.java	Tue Aug 28 12:00:26 2012 -0700
@@ -0,0 +1,48 @@
+/*
+ * Copyright (c) 1996, 2012, Oracle and/or its affiliates. All rights reserved.
+ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+ *
+ * This code is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU General Public License version 2 only, as
+ * published by the Free Software Foundation.  Oracle designates this
+ * particular file as subject to the "Classpath" exception as provided
+ * by Oracle in the LICENSE file that accompanied this code.
+ *
+ * This code is distributed in the hope that it will be useful, but WITHOUT
+ * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
+ * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
+ * version 2 for more details (a copy is included in the LICENSE file that
+ * accompanied this code).
+ *
+ * You should have received a copy of the GNU General Public License version
+ * 2 along with this work; if not, write to the Free Software Foundation,
+ * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
+ *
+ * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
+ * or visit www.oracle.com if you need additional information or have any
+ * questions.
+ */
+
+package com.sun.beans.editors;
+
+/**
+ * Property editor for a java builtin "byte" type.
+ *
+ */
+
+import java.beans.*;
+
+public class ByteEditor extends NumberEditor {
+
+    public String getJavaInitializationString() {
+        Object value = getValue();
+        return (value != null)
+                ? "((byte)" + value + ")"
+                : "null";
+    }
+
+    public void setAsText(String text) throws IllegalArgumentException {
+        setValue((text == null) ? null : Byte.decode(text));
+    }
+
+}
diff -r 507eee662587 -r 5f709891901c src/share/classes/com/sun/beans/editors/ColorEditor.java
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/src/share/classes/com/sun/beans/editors/ColorEditor.java	Tue Aug 28 12:00:26 2012 -0700
@@ -0,0 +1,214 @@
+/*
+ * Copyright (c) 1996, 2012, Oracle and/or its affiliates. All rights reserved.
+ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+ *
+ * This code is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU General Public License version 2 only, as
+ * published by the Free Software Foundation.  Oracle designates this
+ * particular file as subject to the "Classpath" exception as provided
+ * by Oracle in the LICENSE file that accompanied this code.
+ *
+ * This code is distributed in the hope that it will be useful, but WITHOUT
+ * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
+ * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
+ * version 2 for more details (a copy is included in the LICENSE file that
+ * accompanied this code).
+ *
+ * You should have received a copy of the GNU General Public License version
+ * 2 along with this work; if not, write to the Free Software Foundation,
+ * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
+ *
+ * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
+ * or visit www.oracle.com if you need additional information or have any
+ * questions.
+ */
+
+package com.sun.beans.editors;
+
+import java.awt.*;
+import java.beans.*;
+
+public class ColorEditor extends Panel implements PropertyEditor {
+    private static final long serialVersionUID = 1781257185164716054L;
+
+    public ColorEditor() {
+        setLayout(null);
+
+        ourWidth = hPad;
+
+        // Create a sample color block bordered in black
+        Panel p = new Panel();
+        p.setLayout(null);
+        p.setBackground(Color.black);
+        sample = new Canvas();
+        p.add(sample);
+        sample.reshape(2, 2, sampleWidth, sampleHeight);
+        add(p);
+        p.reshape(ourWidth, 2, sampleWidth+4, sampleHeight+4);
+        ourWidth += sampleWidth + 4 + hPad;
+
+        text = new TextField("", 14);
+        add(text);
+        text.reshape(ourWidth,0,100,30);
+        ourWidth += 100 + hPad;
+
+        choser = new Choice();
+        int active = 0;
+        for (int i = 0; i < colorNames.length; i++) {
+            choser.addItem(colorNames[i]);
+        }
+        add(choser);
+        choser.reshape(ourWidth,0,100,30);
+        ourWidth += 100 + hPad;
+
+        resize(ourWidth,40);
+    }
+
+    public void setValue(Object o) {
+        Color c = (Color)o;
+        changeColor(c);
+    }
+
+    public Dimension preferredSize() {
+        return new Dimension(ourWidth, 40);
+    }
+
+    public boolean keyUp(Event e, int key) {
+        if (e.target == text) {
+            try {
+                setAsText(text.getText());
+            } catch (IllegalArgumentException ex) {
+                // Quietly ignore.
+            }
+        }
+        return (false);
+    }
+
+    public void setAsText(String s) throws java.lang.IllegalArgumentException {
+        if (s == null) {
+            changeColor(null);
+            return;
+        }
+        int c1 = s.indexOf(',');
+        int c2 = s.indexOf(',', c1+1);
+        if (c1 < 0 || c2 < 0) {
+            // Invalid string.
+            throw new IllegalArgumentException(s);
+        }
+        try {
+            int r = Integer.parseInt(s.substring(0,c1));
+            int g = Integer.parseInt(s.substring(c1+1, c2));
+            int b = Integer.parseInt(s.substring(c2+1));
+            Color c = new Color(r,g,b);
+            changeColor(c);
+        } catch (Exception ex) {
+            throw new IllegalArgumentException(s);
+        }
+
+    }
+
+    public boolean action(Event e, Object arg) {
+        if (e.target == choser) {
+            changeColor(colors[choser.getSelectedIndex()]);
+        }
+        return false;
+    }
+
+    public String getJavaInitializationString() {
+        return (this.color != null)
+                ? "new java.awt.Color(" + this.color.getRGB() + ",true)"
+                : "null";
+    }
+
+
+    private void changeColor(Color c) {
+
+        if (c == null) {
+            this.color = null;
+            this.text.setText("");
+            return;
+        }
+
+        color = c;
+
+        text.setText("" + c.getRed() + "," + c.getGreen() + "," + c.getBlue());
+
+        int active = 0;
+        for (int i = 0; i < colorNames.length; i++) {
+            if (color.equals(colors[i])) {
+                active = i;
+            }
+        }
+        choser.select(active);
+
+        sample.setBackground(color);
+        sample.repaint();
+
+        support.firePropertyChange("", null, null);
+    }
+
+    public Object getValue() {
+        return color;
+    }
+
+    public boolean isPaintable() {
+        return true;
+    }
+
+    public void paintValue(java.awt.Graphics gfx, java.awt.Rectangle box) {
+        Color oldColor = gfx.getColor();
+        gfx.setColor(Color.black);
+        gfx.drawRect(box.x, box.y, box.width-3, box.height-3);
+        gfx.setColor(color);
+        gfx.fillRect(box.x+1, box.y+1, box.width-4, box.height-4);
+        gfx.setColor(oldColor);
+    }
+
+    public String getAsText() {
+        return (this.color != null)
+                ? this.color.getRed() + "," + this.color.getGreen() + "," + this.color.getBlue()
+                : null;
+    }
+
+    public String[] getTags() {
+        return null;
+    }
+
+    public java.awt.Component getCustomEditor() {
+        return this;
+    }
+
+    public boolean supportsCustomEditor() {
+        return true;
+    }
+
+    public void addPropertyChangeListener(PropertyChangeListener l) {
+        support.addPropertyChangeListener(l);
+    }
+
+    public void removePropertyChangeListener(PropertyChangeListener l) {
+        support.removePropertyChangeListener(l);
+    }
+
+
+    private String colorNames[] = { " ", "white", "lightGray", "gray", "darkGray",
+                        "black", "red", "pink", "orange",
+                        "yellow", "green", "magenta", "cyan",
+                        "blue"};
+    private Color colors[] = { null, Color.white, Color.lightGray, Color.gray, Color.darkGray,
+                        Color.black, Color.red, Color.pink, Color.orange,
+                        Color.yellow, Color.green, Color.magenta, Color.cyan,
+                        Color.blue};
+
+    private Canvas sample;
+    private int sampleHeight = 20;
+    private int sampleWidth = 40;
+    private int hPad = 5;
+    private int ourWidth;
+
+    private Color color;
+    private TextField text;
+    private Choice choser;
+
+    private PropertyChangeSupport support = new PropertyChangeSupport(this);
+}
diff -r 507eee662587 -r 5f709891901c src/share/classes/com/sun/beans/editors/DoubleEditor.java
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/src/share/classes/com/sun/beans/editors/DoubleEditor.java	Tue Aug 28 12:00:26 2012 -0700
@@ -0,0 +1,41 @@
+/*
+ * Copyright (c) 1996, 2012, Oracle and/or its affiliates. All rights reserved.
+ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+ *
+ * This code is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU General Public License version 2 only, as
+ * published by the Free Software Foundation.  Oracle designates this
+ * particular file as subject to the "Classpath" exception as provided
+ * by Oracle in the LICENSE file that accompanied this code.
+ *
+ * This code is distributed in the hope that it will be useful, but WITHOUT
+ * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
+ * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
+ * version 2 for more details (a copy is included in the LICENSE file that
+ * accompanied this code).
+ *
+ * You should have received a copy of the GNU General Public License version
+ * 2 along with this work; if not, write to the Free Software Foundation,
+ * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
+ *
+ * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
+ * or visit www.oracle.com if you need additional information or have any
+ * questions.
+ */
+
+package com.sun.beans.editors;
+
+/**
+ * Property editor for a java builtin "double" type.
+ *



More information about the distro-pkg-dev mailing list