[kaffe] CVS kaffe (robilad): Resynced with GNU Classpath: awt fixlets

Kaffe CVS cvs-commits at kaffe.org
Wed Feb 23 12:42:47 PST 2005


PatchSet 5595 
Date: 2005/02/23 20:36:32
Author: robilad
Branch: HEAD
Tag: (none) 
Log:
Resynced with GNU Classpath: awt fixlets

2005-02-23  Dalibor Topic  <robilad at kaffe.org>

        Resynced with GNU Classpath.

        2005-02-21  Michael Koch  <konqueror at gmx.de>

        * java/awt/Checkbox.java
        (next_checkbox_number): New static variable.
        (generateName): New method.
        (getUniqueLong): Likewise.
        * java/awt/Window.java
        (next_window_number): New static variable.
        (generateName): New method.
        (getUniqueLong): Likewise.

Members: 
	ChangeLog:1.3640->1.3641 
	libraries/javalib/java/awt/Checkbox.java:1.7->1.8 
	libraries/javalib/java/awt/Window.java:1.30->1.31 

Index: kaffe/ChangeLog
diff -u kaffe/ChangeLog:1.3640 kaffe/ChangeLog:1.3641
--- kaffe/ChangeLog:1.3640	Wed Feb 23 19:37:20 2005
+++ kaffe/ChangeLog	Wed Feb 23 20:36:32 2005
@@ -2,6 +2,21 @@
 
 	Resynced with GNU Classpath.
 
+	2005-02-21  Michael Koch  <konqueror at gmx.de>
+
+        * java/awt/Checkbox.java
+        (next_checkbox_number): New static variable.
+        (generateName): New method.
+        (getUniqueLong): Likewise.
+        * java/awt/Window.java
+        (next_window_number): New static variable.
+        (generateName): New method.
+        (getUniqueLong): Likewise.
+
+2005-02-23  Dalibor Topic  <robilad at kaffe.org>
+
+	Resynced with GNU Classpath.
+
 	2005-02-21  Mark Wielaard  <mark at klomp.org>
 
         * java/util/jar/JarFile.java (verifyHashes): Check whether ZipEntry
Index: kaffe/libraries/javalib/java/awt/Checkbox.java
diff -u kaffe/libraries/javalib/java/awt/Checkbox.java:1.7 kaffe/libraries/javalib/java/awt/Checkbox.java:1.8
--- kaffe/libraries/javalib/java/awt/Checkbox.java:1.7	Sat Jan 22 19:20:51 2005
+++ kaffe/libraries/javalib/java/awt/Checkbox.java	Wed Feb 23 20:36:35 2005
@@ -1,5 +1,5 @@
 /* Checkbox.java -- An AWT checkbox widget
-   Copyright (C) 1999, 2000, 2001, 2002 Free Software Foundation, Inc.
+   Copyright (C) 1999, 2000, 2001, 2002, 2005  Free Software Foundation, Inc.
 
 This file is part of GNU Classpath.
 
@@ -95,6 +95,11 @@
 // The list of listeners for this object.
 private transient ItemListener item_listeners;
 
+  /*
+   * The number used to generate the name returned by getName.
+   */
+  private static transient long next_checkbox_number;
+
 /**
  * This class provides accessibility support for the
  * checkbox.
@@ -106,7 +111,6 @@
   extends AccessibleAWTComponent
   implements ItemListener, AccessibleAction, AccessibleValue
 {
-
   /**
    * Serialization constant to match JDK 1.5
    */
@@ -627,4 +631,18 @@
   return accessibleContext;
 }
 
-} // class Checkbox 
+  /**
+   * Generate a unique name for this checkbox.
+   *
+   * @return A unique name for this checkbox.
+   */
+  String generateName()
+  {
+    return "checkbox" + getUniqueLong();
+  }
+
+  private static synchronized long getUniqueLong()
+  {
+    return next_checkbox_number++;
+  }
+}
Index: kaffe/libraries/javalib/java/awt/Window.java
diff -u kaffe/libraries/javalib/java/awt/Window.java:1.30 kaffe/libraries/javalib/java/awt/Window.java:1.31
--- kaffe/libraries/javalib/java/awt/Window.java:1.30	Fri Feb 18 15:13:40 2005
+++ kaffe/libraries/javalib/java/awt/Window.java	Wed Feb 23 20:36:35 2005
@@ -92,6 +92,11 @@
 
   private transient Component windowFocusOwner;
   
+  /*
+   * The number used to generate the name returned by getName.
+   */
+  private static transient long next_window_number;
+
   protected class AccessibleAWTWindow extends AccessibleAWTContainer
   {
     public AccessibleRole getAccessibleRole()
@@ -944,5 +949,20 @@
           new ComponentEvent(this, ComponentEvent.COMPONENT_MOVED);
         getToolkit().getSystemEventQueue().postEvent(ce);
       }
+  }
+
+  /**
+   * Generate a unique name for this window.
+   *
+   * @return A unique name for this window.
+   */
+  String generateName()
+  {
+    return "win" + getUniqueLong();
+  }
+
+  private static synchronized long getUniqueLong()
+  {
+    return next_window_number++;
   }
 }




More information about the kaffe mailing list