On Mon, 5 Oct 2026 22:29:55 GMT, Andy Goryachev <[email protected]> wrote:

>> John Hendrikx has updated the pull request incrementally with one additional 
>> commit since the last revision:
>> 
>>   Add implNote about known snapshot issue
>
> modules/javafx.graphics/src/main/java/com/sun/javafx/util/FXCleaner.java line 
> 13:
> 
>> 11:  * Usage example:
>> 12:  * <pre>
>> 13:  *     FXCleaner.register(resource, () -> resource.dispose());
> 
> bad example: the lambda creates a strong reference to `resource`, so the 
> cleaner action will never run.

Added a better example.

> modules/javafx.graphics/src/main/java/com/sun/prism/sw/SWDrawingContext.java 
> line 1241:
> 
>> 1239:         // Ensure it's a Prism image
>> 1240:         if (!(platformImage instanceof com.sun.prism.Image 
>> prismImage)) {
>> 1241:             throw new IllegalArgumentException("PlatformImage must be 
>> a Prism Image");
> 
> a failed image (progress=1.0, platformImage=null) will throw here, but public 
> `drawImage()` specifies not such failure.  should we check isError() and 
> ignore?

Apparently even checking `isError` is not good enough, so I did the `null` 
check on the resulting platform image like `GraphicsContext` does.

-------------

PR Review Comment: https://git.openjdk.org/jfx/pull/1969#discussion_r4216425778
PR Review Comment: https://git.openjdk.org/jfx/pull/1969#discussion_r4216421605

Reply via email to