RFR: 8333919: [macOS] dragViewOffsetX/dragViewOffsetY are ignored for the dragView image [v4]

Andy Goryachev angorya at openjdk.org
Mon Aug 12 23:09:57 UTC 2024


On Mon, 12 Aug 2024 22:38:32 GMT, Kevin Rushforth <kcr at openjdk.org> wrote:

>> modules/javafx.graphics/src/main/native-glass/mac/GlassViewDelegate.m line 1053:
>> 
>>> 1051:                 float imageH = [image size].height;
>>> 1052: 
>>> 1053:                 if (offset.x < 0.0f) {
>> 
>> I am puzzled a bit: a NaN input seem to produce NaN offsets, yet the testing shows that it behaves as if 0 offsets (possibly in the native code)?
>> 
>> Should the ifs be restructured so as not to pass NaN downstream?
>
> That seems out of scope for this PR. We typically don't do any special processing to deal with NaN unless there is a problem. If needed, maybe it could be done as part of the follow-up bug [JDK-8338204](https://bugs.openjdk.org/browse/JDK-8338204).

Sounds good, especially since it seems to treat NaNs as 0's.

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

PR Review Comment: https://git.openjdk.org/jfx/pull/1532#discussion_r1714458124


More information about the openjfx-dev mailing list