On Wed, 5 Oct 2022 11:11:46 GMT, Jeanette Winzenburg <faste...@openjdk.org> wrote:
>> this makes no sense! thank you for pointing it out. >> perhaps we really *ought to* create a better >> LambdaMultiplePropertyChangeListenerHandler implementation. > > well, it _does_ make sense for listeners registered on properties of the > control itself (they don't change and are un/registered once) - and that was > it was designed for :) What it can't handle (and was not designed for) are > dynamic multiple un/registration of listeners. btw: the executeOnce pattern is appropriate only if it's guaranteed that the value changes once from null to not-null (not back again) .. which is not the case for the value of a control's scene property - it can change in both directions or not at all (which might be the reason for having added a second listener ;) ------------- PR: https://git.openjdk.org/jfx/pull/906