Return-Path: Delivered-To: apmail-harmony-commits-archive@www.apache.org Received: (qmail 99696 invoked from network); 18 Dec 2006 15:30:44 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (140.211.11.2) by minotaur.apache.org with SMTP; 18 Dec 2006 15:30:44 -0000 Received: (qmail 43544 invoked by uid 500); 18 Dec 2006 15:30:51 -0000 Delivered-To: apmail-harmony-commits-archive@harmony.apache.org Received: (qmail 43527 invoked by uid 500); 18 Dec 2006 15:30:51 -0000 Mailing-List: contact commits-help@harmony.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@harmony.apache.org Delivered-To: mailing list commits@harmony.apache.org Received: (qmail 43508 invoked by uid 99); 18 Dec 2006 15:30:51 -0000 Received: from herse.apache.org (HELO herse.apache.org) (140.211.11.133) by apache.org (qpsmtpd/0.29) with ESMTP; Mon, 18 Dec 2006 07:30:51 -0800 X-ASF-Spam-Status: No, hits=0.0 required=10.0 tests= X-Spam-Check-By: apache.org Received: from [140.211.11.4] (HELO brutus.apache.org) (140.211.11.4) by apache.org (qpsmtpd/0.29) with ESMTP; Mon, 18 Dec 2006 07:30:42 -0800 Received: from brutus (localhost [127.0.0.1]) by brutus.apache.org (Postfix) with ESMTP id 8B86F71428E for ; Mon, 18 Dec 2006 07:30:22 -0800 (PST) Message-ID: <17465220.1166455822568.JavaMail.jira@brutus> Date: Mon, 18 Dec 2006 07:30:22 -0800 (PST) From: "Andrey Pavlenko (JIRA)" To: commits@harmony.apache.org Subject: [jira] Updated: (HARMONY-2493) [classlib][awt] java.awt.KeyboardFocusManager.getDefaultFocusTraversalKeys() returns null instead of correct object In-Reply-To: <19420815.1165411222461.JavaMail.jira@brutus> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit X-Virus-Checked: Checked by ClamAV on apache.org [ http://issues.apache.org/jira/browse/HARMONY-2493?page=all ] Andrey Pavlenko updated HARMONY-2493: ------------------------------------- Attachment: DefaultKeyboardFocusManager.patch > [classlib][awt] java.awt.KeyboardFocusManager.getDefaultFocusTraversalKeys() returns null instead of correct object > ------------------------------------------------------------------------------------------------------------------- > > Key: HARMONY-2493 > URL: http://issues.apache.org/jira/browse/HARMONY-2493 > Project: Harmony > Issue Type: Bug > Components: Classlib > Reporter: Pavel Dolgov > Priority: Minor > Attachments: DefaultKeyboardFocusManager.patch, KeyboardFocusManager.patch, KeyboardFocusManagerTest.patch, PerfTest.java > > > Test case: > -------------- > import java.awt.AWTEvent; > import java.awt.Component; > import java.awt.Container; > import java.awt.event.KeyEvent; > import java.util.Set; > import junit.framework.TestCase; > public class TheTest extends TestCase { > public static void main(String args[]) { > junit.textui.TestRunner.run(TheTest.class); > } > public void testcase1() { > KeyboardFocusManagerImpl obj = new KeyboardFocusManagerImpl(); > Set keys = obj.getDefaultFocusTraversalKeys(1); > assertNotNull(keys); > assertTrue(keys.size() > 0); > } > class KeyboardFocusManagerImpl extends java.awt.KeyboardFocusManager { > public KeyboardFocusManagerImpl() { > super(); > } > public boolean dispatchEvent(AWTEvent arg0) { > return false; > } > public boolean dispatchKeyEvent(KeyEvent arg0) { > return false; > } > public boolean postProcessKeyEvent(KeyEvent arg0) { > return false; > } > public void processKeyEvent(Component arg0, KeyEvent arg1) { > } > protected void enqueueKeyEvents(long arg0, Component arg1) { > } > protected void dequeueKeyEvents(long arg0, Component arg1) { > } > protected void discardKeyEvents(Component arg0) { > } > public void focusNextComponent(Component arg0) { > } > public void focusPreviousComponent(Component arg0) { > } > public void upFocusCycle(Component arg0) { > } > public void downFocusCycle(Container arg0) { > } > } > } > RI output: > ------------- > . > Time: 0,991 > OK (1 test) > Harmony output: > -------------- > .F > Time: 0.361 > There was 1 failure: > 1) testcase1(TheTest)junit.framework.AssertionFailedError > at TheTest.testcase1(TheTest.java:17) > at java.lang.reflect.VMReflection.invokeMethod(Native Method) > at TheTest.main(TheTest.java:12) > FAILURES!!! > Tests run: 1, Failures: 1, Errors: 0 -- This message is automatically generated by JIRA. - If you think it was sent incorrectly contact one of the administrators: http://issues.apache.org/jira/secure/Administrators.jspa - For more information on JIRA, see: http://www.atlassian.com/software/jira