hg: macosx-port/macosx-port/jdk: MACOSX_PORT-36: Toolkit.getScreenInsets() returns empty insets

Sergey Bylokhov sergey.bylokhov at oracle.com
Thu Jul 28 07:57:44 PDT 2011


Hi Mike,

Thanks for review the changes!
>
> There is a problem with this change set: you did not CFRetain() the screen pointer before bubbling it up to Java, and you also need to CFRelease() it when you are done. Otherwise, you will crash if the screen geometry is changing while this code is running.
>
> It may be worth wrapping the NSScreen in it's own Java subclass of CFRetainedResource that will handle these details for you. As is, the thread safety is correct.
>
> Should I file a bug on this?
Yes, it'll be good.
>
>
> Mike Swingler
> Java Engineering
> Apple Inc.
>


-- 
Best regards, Sergey.



More information about the macosx-port-dev mailing list