Hi,

Am 10.10.2005 schrieb "Mark Wielaard" <[EMAIL PROTECTED]>:

>hi,
>
>On Mon, 2005-10-10 at 12:35 +0000, Roman Kennke wrote:
>> 2005-10-10  Roman Kennke  <[EMAIL PROTECTED]>
>> 
>>         * javax/swing/JComponent.java
>>         (paintChildren): Skip children if their clip _doesn't_ hit the
>>         current clip.
>> [...]
>>      if (g.hitClip(bounds.x, bounds.y, bounds.width, bounds.height))
>>        continue;
>
>So this should be !g.hitClip(). That is what you committed, so CVS is
>OK.

Here comes the correct patch.

2005-10-10  Roman Kennke  <[EMAIL PROTECTED]>

        * javax/swing/JComponent.java
        (paintChildren): Skip children if their clip _doesn't_ hit the
        current clip.
        (setVisible): Do nothing if the actual value didn't change.

/Roman
Index: javax/swing/JComponent.java
===================================================================
RCS file: /cvsroot/classpath/classpath/javax/swing/JComponent.java,v
retrieving revision 1.66
retrieving revision 1.67
diff -u -r1.66 -r1.67
--- javax/swing/JComponent.java	10 Oct 2005 08:53:27 -0000	1.66
+++ javax/swing/JComponent.java	10 Oct 2005 12:22:37 -0000	1.67
@@ -1534,8 +1534,9 @@
         if (oldClip == null)
           oldClip = bounds;
 
-        if (g.hitClip(bounds.x, bounds.y, bounds.width, bounds.height))
+        if (!g.hitClip(bounds.x, bounds.y, bounds.width, bounds.height))
           continue;
+
         boolean translated = false;
         try
           {
@@ -2333,6 +2334,10 @@
    */
   public void setVisible(boolean v)
   {
+    // No need to do anything if the actual value doesn't change.
+    if (isVisible() == v)
+      return;
+
     super.setVisible(v);
     Container parent = getParent();
     if (parent != null)
_______________________________________________
Classpath-patches mailing list
[email protected]
http://lists.gnu.org/mailman/listinfo/classpath-patches

Reply via email to