diff --git a/libjava/ChangeLog b/libjava/ChangeLog index e0d7f94f2f4..a93836263a8 100644 --- a/libjava/ChangeLog +++ b/libjava/ChangeLog @@ -1,3 +1,18 @@ +2004-05-03 Mark Wielaard + + * 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. + 2004-05-03 Mark Wielaard * gnu/java/awt/peer/gtk/GtkTextAreaPeer.java (minimumSize): Removed diff --git a/libjava/gnu/java/security/der/DERReader.java b/libjava/gnu/java/security/der/DERReader.java index 3020b8b2d1a..3915b071165 100644 --- a/libjava/gnu/java/security/der/DERReader.java +++ b/libjava/gnu/java/security/der/DERReader.java @@ -335,7 +335,7 @@ public class DERReader implements DER 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 @@ public class DERReader implements DER 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))); } } diff --git a/libjava/java/awt/TextComponent.java b/libjava/java/awt/TextComponent.java index 2b7317d8519..0a410a44b9f 100644 --- a/libjava/java/awt/TextComponent.java +++ b/libjava/java/awt/TextComponent.java @@ -233,11 +233,11 @@ setSelectionEnd(int selectionEnd) * 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; diff --git a/libjava/java/net/URL.java b/libjava/java/net/URL.java index 729d96fa878..623f6601770 100644 --- a/libjava/java/net/URL.java +++ b/libjava/java/net/URL.java @@ -743,12 +743,11 @@ public final class URL implements Serializable 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. } diff --git a/libjava/java/util/Arrays.java b/libjava/java/util/Arrays.java index 080b4b9cbf9..cc32d153900 100644 --- a/libjava/java/util/Arrays.java +++ b/libjava/java/util/Arrays.java @@ -2400,7 +2400,7 @@ public class Arrays { 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 @@ public class Arrays { int i = a.length; while (--i >= 0) - if (this.equals(o, a[i])) + if (ArrayList.equals(o, a[i])) return i; return -1; } diff --git a/libjava/java/util/zip/ZipEntry.java b/libjava/java/util/zip/ZipEntry.java index e2262812b9f..3f7f6435529 100644 --- a/libjava/java/util/zip/ZipEntry.java +++ b/libjava/java/util/zip/ZipEntry.java @@ -169,12 +169,12 @@ public class ZipEntry implements ZipConstants, Cloneable 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; diff --git a/libjava/javax/swing/plaf/basic/BasicArrowButton.java b/libjava/javax/swing/plaf/basic/BasicArrowButton.java index e778c5bffa3..cb2c99baf58 100644 --- a/libjava/javax/swing/plaf/basic/BasicArrowButton.java +++ b/libjava/javax/swing/plaf/basic/BasicArrowButton.java @@ -223,7 +223,7 @@ public class BasicArrowButton extends JButton implements SwingConstants setIcon(new arrowIcon(arrow)); else ((arrowIcon) getIcon()).setArrow(arrow); - this.direction = direction; + this.direction = dir; } /** diff --git a/libjava/javax/swing/table/DefaultTableCellRenderer.java b/libjava/javax/swing/table/DefaultTableCellRenderer.java index 6bd0ff57f59..563d9e60af2 100644 --- a/libjava/javax/swing/table/DefaultTableCellRenderer.java +++ b/libjava/javax/swing/table/DefaultTableCellRenderer.java @@ -54,7 +54,7 @@ public class DefaultTableCellRenderer extends JLabel { 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 class DefaultTableCellRenderer extends JLabel public DefaultTableCellRenderer() { super(); - this.noFocusBorder = new EmptyBorder(0, 0, 0, 0); } /**