classpath-patches
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[cp-patches] FYI: fix for Component.requestFocus


From: Anthony Balkissoon
Subject: [cp-patches] FYI: fix for Component.requestFocus
Date: Fri, 28 Oct 2005 12:12:44 -0400

This patch makes us pass
gnu/testlet/java/awt/Component/requestFocus.java.  requestFocus was
throwing a NPE unexpectedly.  When looking for our top-level ancestor,
we should start with ourselves if we are Containers, and if not, then
start with getParent().  Before we were just starting with getParent().

Also, if we find no top-level ancestor, we should just return (this is a
standard != null check before continuing).

2005-10-28  Anthony Balkissoon  <address@hidden>

        * java/awt/Component.java:
        (requestFocus): If this component is a Container, start here, not at
        its parent when looking for the top-level ancestor.  If no top-level
        ancestor is found (parent == null), return.

--Tony

Attachment: ComponentRequestFocusFix.diff
Description: Text Data


reply via email to

[Prev in Thread] Current Thread [Next in Thread]