Review request for 7142780: [macosx] Font2DTest demo throws NPE (original) (raw)

Alexander Zuev alexander.zuev at oracle.com
Mon Feb 6 05:02:00 PST 2012


Looks fine to me.

On 2/6/12 12:07, Andrew Brygin wrote:

Hello,

please take a look to a fix for CR 7142780: http://cr.openjdk.java.net/~bae/7142780/webrev/ The Font2DTest creates a bogus image in order to get a blank cursor (FontPanel.java, lines 495 - 498). This image can not be loaded and triggers an error when MediaTracker tries to prepare the image. As soon as the error is detected, the conversion of toolkit image to CImage is aborted, and the CImage.Creator.createFromImage returns null. So, CCustomCursor.getImageData need to be modified in order to be able to handle a null result of the createFormImage. However, in order to avoid numerous calls to createFromImage in case of faulty image, we can check the status of image loading in the constructor, and set a flag to indicate whether given image can be used as a cursor. Thanks, Andrew



More information about the macosx-port-dev mailing list