<AWT Dev> Review request for CR-7179050 : [macosx] Make LWAWT be able to run on AppKit thread
petr.pchelko at oracle.com
Tue Jan 15 06:54:05 PST 2013
Hello, AWT team.
Please review a fix for the issue: [macosx] Make LWAWT be able to run on AppKit thread
The fix is available at:
A lot of simple refactoring is done here:
1. The JNFRunLoop calls are changed to ThreadUtilities calls which do the thread check before calling JNFRunloop.
2. AWT_ASSERT_NOT_APPKIT_THREAD calls are deleted where it is safe. I did not touch printing code and Drag and Drop code as in these parts the situation is much more complicated, and it would be better to investigate them separately.
3. AWT_ASSERT_APPKIT_THREAD calls immediately following the performOnMainThread are removed because it is obvious that we are running on Appkit thread.
4. AWT_ASSERT_ANY_THREAD - this was a very surprising assertion which does nothing. Probably it was originally designed to mark methods which could be called from any thread, however now it occurs in the code only occasionally, so it only confusing. It is removed
5. The CPlatformWindow method nativeSetNSWindowSecurityWarnongPosition was private, never called and all it did was throwing an Unsupported operation exception. It is deleted.
6. A lot of code in ThreadUtilities.m was used only in CocoaComponent compatibility mode. We do not support this mode any more, so the code could be deleted. It is safe, because all the removed code was used only if the sCocoaComponentCompatibility flag was set to YES. However it is set to NO in the beginning of the file and it is an only place where this flag is used in openjdk.
With best regards. Petr.
-------------- next part --------------
An HTML attachment was scrubbed...
More information about the awt-dev