When I do multi-platform testing on Windows it gets annoying that Eclipse shows errors in the project because of the com.apple.eawt code that I have in a special Mac customi
You might be able to use the approach taken in OSXAdapter, the "dynamic implementation [of which] will only be triggered on platforms that actually support the Apple APIs (e.g. Java 1.4 or later on Mac OS X), avoiding any compatibility concerns." A sample application and the adapter itself are available, as mentioned in this article.