This is the mail archive of the
java-patches@gcc.gnu.org
mailing list for the Java project.
Patch: more merges
- From: Michael Koch <konqueror at gmx dot de>
- To: java-patches at gcc dot gnu dot org
- Date: Mon, 3 May 2004 22:25:20 +0200
- Subject: Patch: more merges
Hi list,
I just commited the attached patch to merge another patch from Mark
Wielaard in from GNU classpath to trunk.
Michael
2004-05-03 Mark Wielaard <mark@klomp.org>
* gnu/java/security/der/DERReader.java: Call static methods staticly.
* java/awt/TextComponent.java (select): Use selectionEnd parameter.
* java/net/URL.java
(set(String, String, int, String, String, String, String, String)):
Assign this.file to path or path + "?" + query.
* java/util/Arrays.java: Call static methods staticly.
* java/util/zip/ZipEntry.java: Likewise.
* javax/swing/plaf/basic/BasicArrowButton.java (setDirection): Assign
dir to this.direction.
* javax/swing/table/DefaultTableCellRenderer.java (noFocusBorder):
Assign static field only once.
(DefaultTableCellRenderer): Don't reassign noFocusBorder each time.
Index: gnu/java/security/der/DERReader.java
===================================================================
RCS file: /cvs/gcc/gcc/libjava/gnu/java/security/der/DERReader.java,v
retrieving revision 1.1
diff -u -r1.1 DERReader.java
--- gnu/java/security/der/DERReader.java 30 Apr 2003 07:23:40 -0000 1.1
+++ gnu/java/security/der/DERReader.java 3 May 2004 20:23:00 -0000
@@ -335,7 +335,7 @@
Integer.parseInt(str.substring( 6, 8)), // hour
Integer.parseInt(str.substring( 8, 10))); // minute
if (date.length() == 12);
- calendar.set(calendar.SECOND,
+ calendar.set(Calendar.SECOND,
Integer.parseInt(str.substring(10, 12)));
}
catch (NumberFormatException nfe)
@@ -362,13 +362,13 @@
case 18:
case 17:
case 16:
- calendar.set(calendar.MILLISECOND,
+ calendar.set(Calendar.MILLISECOND,
Integer.parseInt(date.substring(15)));
case 14:
- calendar.set(calendar.SECOND,
+ calendar.set(Calendar.SECOND,
Integer.parseInt(date.substring(12, 14)));
case 12:
- calendar.set(calendar.MINUTE,
+ calendar.set(Calendar.MINUTE,
Integer.parseInt(date.substring(10, 12)));
}
}
Index: java/awt/TextComponent.java
===================================================================
RCS file: /cvs/gcc/gcc/libjava/java/awt/TextComponent.java,v
retrieving revision 1.12
diff -u -r1.12 TextComponent.java
--- java/awt/TextComponent.java 3 May 2004 19:52:28 -0000 1.12
+++ java/awt/TextComponent.java 3 May 2004 20:23:00 -0000
@@ -233,11 +233,11 @@
* specified start and end positions. Illegal values for these
* positions are silently fixed.
*
- * @param startSelection The new start position for the selected text.
- * @param endSelection The new end position for the selected text.
+ * @param selectionStart The new start position for the selected text.
+ * @param selectionEnd The new end position for the selected text.
*/
public synchronized void
-select(int selectionStart, int endSelection)
+select(int selectionStart, int selectionEnd)
{
if (selectionStart < 0)
selectionStart = 0;
Index: java/net/URL.java
===================================================================
RCS file: /cvs/gcc/gcc/libjava/java/net/URL.java,v
retrieving revision 1.36
diff -u -r1.36 URL.java
--- java/net/URL.java 23 Apr 2004 07:21:46 -0000 1.36
+++ java/net/URL.java 3 May 2004 20:23:00 -0000
@@ -743,12 +743,11 @@
this.host = host;
this.userInfo = userInfo;
this.port = port;
- this.file = path;
this.authority = authority;
if (query == null)
- this.file = file;
+ this.file = path;
else
- this.file = file + "?" + query;
+ this.file = path + "?" + query;
this.ref = ref;
hashCode = hashCode(); // Used for serialization.
}
Index: java/util/Arrays.java
===================================================================
RCS file: /cvs/gcc/gcc/libjava/java/util/Arrays.java,v
retrieving revision 1.9
diff -u -r1.9 Arrays.java
--- java/util/Arrays.java 10 Sep 2003 18:11:05 -0000 1.9
+++ java/util/Arrays.java 3 May 2004 20:23:01 -0000
@@ -2400,7 +2400,7 @@
{
int size = a.length;
for (int i = 0; i < size; i++)
- if (this.equals(o, a[i]))
+ if (ArrayList.equals(o, a[i]))
return i;
return -1;
}
@@ -2409,7 +2409,7 @@
{
int i = a.length;
while (--i >= 0)
- if (this.equals(o, a[i]))
+ if (ArrayList.equals(o, a[i]))
return i;
return -1;
}
Index: java/util/zip/ZipEntry.java
===================================================================
RCS file: /cvs/gcc/gcc/libjava/java/util/zip/ZipEntry.java,v
retrieving revision 1.18
diff -u -r1.18 ZipEntry.java
--- java/util/zip/ZipEntry.java 17 Jun 2003 12:07:56 -0000 1.18
+++ java/util/zip/ZipEntry.java 3 May 2004 20:23:01 -0000
@@ -169,12 +169,12 @@
synchronized (cal)
{
cal.setTime(new Date(time*1000L));
- dostime = (cal.get(cal.YEAR) - 1980 & 0x7f) << 25
- | (cal.get(cal.MONTH) + 1) << 21
- | (cal.get(cal.DAY_OF_MONTH)) << 16
- | (cal.get(cal.HOUR_OF_DAY)) << 11
- | (cal.get(cal.MINUTE)) << 5
- | (cal.get(cal.SECOND)) >> 1;
+ dostime = (cal.get(Calendar.YEAR) - 1980 & 0x7f) << 25
+ | (cal.get(Calendar.MONTH) + 1) << 21
+ | (cal.get(Calendar.DAY_OF_MONTH)) << 16
+ | (cal.get(Calendar.HOUR_OF_DAY)) << 11
+ | (cal.get(Calendar.MINUTE)) << 5
+ | (cal.get(Calendar.SECOND)) >> 1;
}
dostime = (int) (dostime / 1000L);
this.known |= KNOWN_TIME;
Index: javax/swing/plaf/basic/BasicArrowButton.java
===================================================================
RCS file: /cvs/gcc/gcc/libjava/javax/swing/plaf/basic/BasicArrowButton.java,v
retrieving revision 1.2
diff -u -r1.2 BasicArrowButton.java
--- javax/swing/plaf/basic/BasicArrowButton.java 16 Apr 2004 18:44:38 -0000 1.2
+++ javax/swing/plaf/basic/BasicArrowButton.java 3 May 2004 20:23:01 -0000
@@ -223,7 +223,7 @@
setIcon(new arrowIcon(arrow));
else
((arrowIcon) getIcon()).setArrow(arrow);
- this.direction = direction;
+ this.direction = dir;
}
/**
Index: javax/swing/table/DefaultTableCellRenderer.java
===================================================================
RCS file: /cvs/gcc/gcc/libjava/javax/swing/table/DefaultTableCellRenderer.java,v
retrieving revision 1.4
diff -u -r1.4 DefaultTableCellRenderer.java
--- javax/swing/table/DefaultTableCellRenderer.java 22 Jan 2004 21:41:53 -0000 1.4
+++ javax/swing/table/DefaultTableCellRenderer.java 3 May 2004 20:23:01 -0000
@@ -54,7 +54,7 @@
{
static final long serialVersionUID = 7878911414715528324L;
- protected static Border noFocusBorder;
+ protected static Border noFocusBorder = new EmptyBorder(0, 0, 0, 0);
public static class UIResource extends DefaultTableCellRenderer
implements javax.swing.plaf.UIResource
@@ -70,7 +70,6 @@
public DefaultTableCellRenderer()
{
super();
- this.noFocusBorder = new EmptyBorder(0, 0, 0, 0);
}
/**