This is the mail archive of the
java-patches@gcc.gnu.org
mailing list for the Java project.
[PATCH] java.awt.*
- From: Michael Koch <konqueror at gmx dot de>
- To: java-patches at gcc dot gnu dot org
- Date: Thu, 13 Feb 2003 16:17:51 +0100
- Subject: [PATCH] java.awt.*
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1
Hi list,
Here another patch with some small changes for java.awt.
Please review and comment.
Michael
- --
Homepage: http://www.worldforge.org/
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.2.1 (GNU/Linux)
iD8DBQE+S7cfWSOgCCdjSDsRAmgLAKCf+TmOlDSA1PYvAOkDTey+tKWIdQCfeuwQ
HFbFxAx34BTJQ+PLBcynG2M=
=DwlN
-----END PGP SIGNATURE-----
Index: ChangeLog
===================================================================
RCS file: /cvs/gcc/gcc/libjava/ChangeLog,v
retrieving revision 1.1694
diff -u -r1.1694 ChangeLog
--- ChangeLog 13 Feb 2003 11:37:09 -0000 1.1694
+++ ChangeLog 13 Feb 2003 11:40:34 -0000
@@ -1,5 +1,31 @@
2003-02-13 Michael Koch <konqueror@gmx.de>
+ * java/awt/Label.java
+ (Label): Don't implement Serializable directly.
+ (addNotify): Fixed typo in documentation.
+ * java/awt/List.java
+ (List): Don't implement Serializable directly.
+ * java/awt/PopupMenu.java
+ (PopupMenu): Don't implement Serializable directly.
+ * java/awt/ScrollPane.java
+ (ScrollPane): Don't implement Serializable directly.
+ * java/awt/Scrollbar.java
+ (Scrollbar): Don't implement Serializable directly.
+ * java/awt/TextArea.java
+ (preferredSize): Fixed method arguments.
+ * java/awt/TextField.java
+ (TextField): Don't implement Serializable directly.
+ * java/awt/color/ICC_ColorSpace.java
+ (fromCIOXYZ): Documentation added.
+ (getMinValue): Documentation added.
+ (getMaxValue): Documentation added.
+ * java/awt/datatransfer/DataFlavor.java
+ (isMimeTypeEqual): May not be final.
+ (clone): Throws CloneNotSupportedException.
+ (getReaderForText): Don't throws UnsupportedEncodingException.
+
+2003-02-13 Michael Koch <konqueror@gmx.de>
+
* java/nio/ByteBuffer.java
(endian): New member variable.
(get): New methods.
Index: java/awt/Label.java
===================================================================
RCS file: /cvs/gcc/gcc/libjava/java/awt/Label.java,v
retrieving revision 1.10
diff -u -r1.10 Label.java
--- java/awt/Label.java 14 Jan 2003 21:21:31 -0000 1.10
+++ java/awt/Label.java 13 Feb 2003 11:40:34 -0000
@@ -40,7 +40,6 @@
import java.awt.peer.LabelPeer;
import java.awt.peer.ComponentPeer;
-import java.io.Serializable;
import javax.accessibility.Accessible;
/**
@@ -50,7 +49,7 @@
* @author Aaron M. Renn (arenn@urbanophile.com)
* @author Tom Tromey <tromey@cygnus.com>
*/
-public class Label extends Component implements Serializable, Accessible
+public class Label extends Component implements Accessible
{
/*
@@ -225,7 +224,7 @@
/*************************************************************************/
/**
- * Notifies this lable that it has been added to a container, causing
+ * Notifies this label that it has been added to a container, causing
* the peer to be created. This method is called internally by the AWT
* system.
*/
Index: java/awt/List.java
===================================================================
RCS file: /cvs/gcc/gcc/libjava/java/awt/List.java,v
retrieving revision 1.10
diff -u -r1.10 List.java
--- java/awt/List.java 14 Jan 2003 21:21:32 -0000 1.10
+++ java/awt/List.java 13 Feb 2003 11:40:34 -0000
@@ -54,7 +54,7 @@
* @author Aaron M. Renn (arenn@urbanophile.com)
*/
public class List extends Component
- implements ItemSelectable, Serializable, Accessible
+ implements ItemSelectable, Accessible
{
/*
Index: java/awt/PopupMenu.java
===================================================================
RCS file: /cvs/gcc/gcc/libjava/java/awt/PopupMenu.java,v
retrieving revision 1.5
diff -u -r1.5 PopupMenu.java
--- java/awt/PopupMenu.java 2 Jan 2003 00:14:22 -0000 1.5
+++ java/awt/PopupMenu.java 13 Feb 2003 11:40:34 -0000
@@ -47,7 +47,7 @@
*
* @author Aaron M. Renn (arenn@urbanophile.com)
*/
-public class PopupMenu extends Menu implements java.io.Serializable
+public class PopupMenu extends Menu
{
/*
Index: java/awt/ScrollPane.java
===================================================================
RCS file: /cvs/gcc/gcc/libjava/java/awt/ScrollPane.java,v
retrieving revision 1.7
diff -u -r1.7 ScrollPane.java
--- java/awt/ScrollPane.java 14 Jan 2003 21:21:32 -0000 1.7
+++ java/awt/ScrollPane.java 13 Feb 2003 11:40:34 -0000
@@ -41,7 +41,6 @@
import java.awt.peer.ScrollPanePeer;
import java.awt.peer.ContainerPeer;
import java.awt.peer.ComponentPeer;
-import java.io.Serializable;
import javax.accessibility.Accessible;
/**
@@ -50,7 +49,7 @@
*
* @author Aaron M. Renn (arenn@urbanophile.com)
*/
-public class ScrollPane extends Container implements Accessible, Serializable
+public class ScrollPane extends Container implements Accessible
{
/*
Index: java/awt/Scrollbar.java
===================================================================
RCS file: /cvs/gcc/gcc/libjava/java/awt/Scrollbar.java,v
retrieving revision 1.10
diff -u -r1.10 Scrollbar.java
--- java/awt/Scrollbar.java 14 Jan 2003 21:21:32 -0000 1.10
+++ java/awt/Scrollbar.java 13 Feb 2003 11:40:34 -0000
@@ -42,7 +42,6 @@
import java.awt.peer.ComponentPeer;
import java.awt.event.AdjustmentListener;
import java.awt.event.AdjustmentEvent;
-import java.io.Serializable;
import javax.accessibility.Accessible;
/**
@@ -52,8 +51,7 @@
* @author Tom Tromey <tromey@cygnus.com>
*/
public class Scrollbar extends Component implements Accessible,
- Adjustable,
- Serializable
+ Adjustable
{
// FIXME: Serialization readObject/writeObject
Index: java/awt/TextArea.java
===================================================================
RCS file: /cvs/gcc/gcc/libjava/java/awt/TextArea.java,v
retrieving revision 1.5
diff -u -r1.5 TextArea.java
--- java/awt/TextArea.java 2 Jan 2003 00:14:22 -0000 1.5
+++ java/awt/TextArea.java 13 Feb 2003 11:40:34 -0000
@@ -404,7 +404,7 @@
* <code>getPreferredSize(int)</code>.
*/
public Dimension
-preferredSize(int columns)
+preferredSize(int rows, int columns)
{
return(getPreferredSize(rows, columns));
}
Index: java/awt/TextField.java
===================================================================
RCS file: /cvs/gcc/gcc/libjava/java/awt/TextField.java,v
retrieving revision 1.4
diff -u -r1.4 TextField.java
--- java/awt/TextField.java 2 Jan 2003 00:14:22 -0000 1.4
+++ java/awt/TextField.java 13 Feb 2003 11:40:34 -0000
@@ -49,7 +49,7 @@
*
* @author Aaron M. Renn (arenn@urbanophile.com)
*/
-public class TextField extends TextComponent implements java.io.Serializable
+public class TextField extends TextComponent
{
/*
Index: java/awt/color/ICC_ColorSpace.java
===================================================================
RCS file: /cvs/gcc/gcc/libjava/java/awt/color/ICC_ColorSpace.java,v
retrieving revision 1.7
diff -u -r1.7 ICC_ColorSpace.java
--- java/awt/color/ICC_ColorSpace.java 14 Jan 2003 21:21:33 -0000 1.7
+++ java/awt/color/ICC_ColorSpace.java 13 Feb 2003 11:40:34 -0000
@@ -143,6 +143,13 @@
throw new UnsupportedOperationException();
}
+ /**
+ * Transforms a color value assumed to be in the CS_CIEXYZ conversion color
+ * space into this ColorSpace.
+ *
+ * @exception ArrayIndexOutOfBoundsException If array length is not at
+ * least 3.
+ */
public float[] fromCIEXYZ(float[] colorvalue)
{
// FIXME: Not implemented
@@ -150,6 +157,12 @@
}
/**
+ * Returns the minimum normalized color component value for the specified
+ * component.
+ *
+ * @exception IllegalArgumentException If component is less than 0 or greater
+ * than numComponents - 1.
+ *
* @since 1.4
*/
public float getMinValue(int idx)
@@ -162,6 +175,12 @@
}
/**
+ * Returns the maximum normalized color component value for the specified
+ * component.
+ *
+ * @exception IllegalArgumentException If component is less than 0 or greater
+ * than numComponents - 1.
+ *
* @since 1.4
*/
public float getMaxValue(int idx)
Index: java/awt/datatransfer/DataFlavor.java
===================================================================
RCS file: /cvs/gcc/gcc/libjava/java/awt/datatransfer/DataFlavor.java,v
retrieving revision 1.4
diff -u -r1.4 DataFlavor.java
--- java/awt/datatransfer/DataFlavor.java 2 Jan 2003 00:14:23 -0000 1.4
+++ java/awt/datatransfer/DataFlavor.java 13 Feb 2003 11:40:35 -0000
@@ -508,7 +508,7 @@
*
* @exception NullPointerException If mimeType is null.
*/
-public final boolean
+public boolean
isMimeTypeEqual(String mimeType)
{
// FIXME: Need to handle default attributes and parameters
@@ -660,8 +660,7 @@
* the Cloneable interface. Subclasses that override the clone method can also
* throw this exception to indicate that an instance cannot be cloned.
*/
-public Object
-clone()
+public Object clone () throws CloneNotSupportedException
{
try
{
@@ -975,10 +974,8 @@
* @exception UnsupportedEncodingException if the "charset" isn't supported
* on this platform.
*/
-public Reader
-getReaderForText(Transferable transferable) throws UnsupportedFlavorException,
- IOException,
- UnsupportedEncodingException
+public Reader getReaderForText(Transferable transferable)
+ throws UnsupportedFlavorException, IOException
{
if (!transferable.isDataFlavorSupported(this))
throw new UnsupportedFlavorException(this);