JDK-7097771 : setEnabled does not work for components in disabled containers.
  • Type: Bug
  • Component: client-libs
  • Sub-Component: java.awt
  • Affected Version: 8
  • Priority: P3
  • Status: Resolved
  • Resolution: Fixed
  • OS: linux
  • CPU: generic
  • Submitted: 2011-10-04
  • Updated: 2013-07-10
  • Resolved: 2012-04-24
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 8
8 b36Fixed
Related Reports
Relates :  
Description
Tested on jdk 8 ubuntu 11.04
Testcase attached.

How to reproduce:
1 javac DisabledComponent.java
2 java DisabledComponent
Expected behavior:
List should be disabled(it works on windows)
Actual behavior:
List is enabled and is receiving events.

The problem exists in XComponentPeer.setEnable() it does not check container status.

Comments
SUGGESTED FIX http://hg.openjdk.java.net/jdk8/awt/jdk/rev/33c604bf074f
10-04-2012

EVALUATION We should check container status before we set status of the component. This check was done during initialization before, it was moved to setEnabled() method.
10-04-2012