JDK-6200795 : PIT: Regression testcase Button/DisabledButtonPress/DisabledButtonPress.html fails
  • Type: Bug
  • Component: client-libs
  • Sub-Component: java.awt
  • Affected Version: 6
  • Priority: P2
  • Status: Closed
  • Resolution: Fixed
  • OS: windows,windows_xp
  • CPU: generic,x86
  • Submitted: 2004-11-26
  • Updated: 2011-01-19
  • Resolved: 2005-02-12
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 6
6 b24Fixed
Related Reports
Duplicate :  
Description
The regression testcase Button/DisabledButtonPress/DisabledButtonPress.html fails on Windows platform against PIT build for mustang b15. It passes with mustang b13.

jtr file attached.


Comments
SUGGESTED FIX ------- awt_Component.cpp ------- *** /tmp/sccs.3NaGM3 Fri Dec 3 18:16:30 2004 --- awt_Component.cpp Fri Dec 3 18:09:39 2004 *************** *** 5610,5620 **** --- 5610,5622 ---- // and only then truncate to 32 bits. UINT disabledLevel = static_cast<UINT> (reinterpret_cast<ULONG_PTR>(::GetProp(GetHWnd(), ModalDisableProp))); BOOL bState = bEnable ? (disabledLevel == 0) : FALSE; + sm_suppressFocusAndActivation = TRUE; ::EnableWindow(GetHWnd(), bState); + sm_suppressFocusAndActivation = FALSE; CriticalSection::Lock l(GetLock()); VerifyState(); } /* Initialization of MouseWheel support on Windows 95 */ ###@###.### 2004-12-07 15:24:02 GMT
07-12-2004

EVALUATION The error is: "Test failed. A Button doesn't have a focus." I believe that this could be fixed by focus bug-fix. ###@###.### 2004-11-29 09:54:04 GMT See the evaluation for 6200345. This problem is similar. SetEnabled() is called on native level via InvokeFunction (invoked on Toolkit thread). Earlier we called it directly that was not correct but in the same time it saved us from some native messages (due to asynchronous processing). Now we have that messages and should skip them somehow. ###@###.### 2004-11-30 18:49:26 GMT There is AwtComponent::sm_suppressFocusAndActivation field destined to have an ability to suppress native focus-related messages. We can use this field in this case when disabling/enabling a component allowing "auto focus transfer" mechanizm (that initiated on Java side) to work swimmingly. ###@###.### 2004-12-03 15:25:35 GMT
29-11-2004