On Fri, 14 May 2021 16:29:19 GMT, Kevin Rushforth <k...@openjdk.org> wrote:

>> true to both questions.
>> The reason for this change is that this is now doing the same as what is 
>> done in `monocle.TouchState` and `monocle.TouchInput`. 
>> TBH, I would prefer a different approach, where no fallback is passed, and 
>> the `if` block is only executed when `recalculateCache` is set to `true`. 
>> The only case where this `getWindow` method is invoked, is from `MouseInput` 
>> and it is only used to detect if the "old" window is different from the 
>> current window. Hence, it all seems a bit overkill to me, but for some 
>> reason, I thought keeping things consistent (mouseState versus TouchState) 
>> would make sense.
>> If you are ok with it, I can simply rewrite this without looking at the 
>> TouchState case?
>
> Either is fine with me. As long as this fixes your problem, go ahead with the 
> fix. Or if you prefer, go ahead and rewrite it.

I'll keep it like this for now, and I created a follow-up issue (JDK-8267175) 
for dealing with touch/mouse/key state/input handling in general in monocle.

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

PR: https://git.openjdk.java.net/jfx/pull/502

Reply via email to