JDK-6553302 : Non-focusable AWT Choice doesn't allow user to change selection
  • Type: Bug
  • Component: client-libs
  • Sub-Component: java.awt
  • Affected Version: 7
  • Priority: P3
  • Status: Closed
  • Resolution: Duplicate
  • OS: windows_xp
  • CPU: x86
  • Submitted: 2007-05-03
  • Updated: 2011-01-19
  • Resolved: 2007-06-28
The Version table provides details related to the release that this issue/RFE will be addressed.

Unresolved : Release in which this issue/RFE will be addressed.
Resolved: Release in which this issue/RFE has been resolved.
Fixed : Release in which this issue/RFE has been fixed. The release containing this fix may be available for download as an Early Access Release or a General Availability Release.

To download the current JDK release, click here.
JDK 7
7Resolved
Related Reports
Duplicate :  
Description
Run the following testcase.

The test displayes a frame with non-focusable choice inside. Click on the choice by mouse and the pop-up will appear. Click on any item of the pop-up to change the selection of the choice but the selection will be the same as before the click. It looks like user don't have any way to change the selection.

Additional information.

>java -version
java version "1.7.0-ea"
Java(TM) SE Runtime Environment (build 1.7.0-ea-b07)
Java HotSpot(TM) Client VM (build 1.7.0-ea-b07, mixed mode)

The testcase works fine on JDK7 b01. The bug is regression
of the fix for 6359035 (Apply WinXP visual styles to AWT native dialogs)
integrated into b02.

----------SOURCE CODE ---------------------

import java.awt.*;

public class Test{
	public static void main(String args[]) {
		Frame frame = new Frame();
		Choice choice = new Choice();
		choice.setFocusable(false);
	        for (int i = 0; i < 10; i++) {
	            choice.add("Choice item " + i);
	        }
		frame.add(choice);
		frame.setSize(200,200);
		frame.setVisible(true);
	}
}

----------------------------------------------