Iconifying the frame programmatically by calling frame.setExtendedState(ICONIFIED) and then restoring it with a subsequent call to setExtendedState(NORMAL) removes the focus from the initial component on the frame. In my app, I have added a button to the frame and I am calling the above methods when the button is clicked. When the frame gets restored, the button no longer has the focus and window is also not activated.
This is a regression in Mustang, introduced somewhere in-between b11-b20. This is reproducible only on XToolkit and works fine on Win32. I reproduced it with SolSparc10-JDS and SuSE10. This works fine on Tiger-fcs on the specified platforms with XToolkit.
I have attached a sample test. Run the test. A frame would appear with a button. Click on the button and wait for sometime. Frame would iconify and restore. When the frame comes back, check if button has the focus. If not, the bug is reproduced.