[prev in list] [next in list] [prev in thread] [next in thread]
List: openjdk-openjfx-dev
Subject: Re: RFR: JDK-8290310: ChangeListener events are incorrect or misleading when a nested change occurs
From: John Hendrikx <jhendrikx () openjdk ! org>
Date: 2023-07-24 22:12:53
Message-ID: ZPSIgjfg5cFC0o0YCo_Ty_PKPBV_Rm0bjTpp0-5shsQ=.bb821157-aaba-4223-8bc0-9f897cbdf57c () github ! com
[Download RAW message or body]
On Mon, 24 Jul 2023 19:56:06 GMT, Michael Strauß <mstrauss@openjdk.org> wrote:
> > John Hendrikx has updated the pull request incrementally with one additional \
> > commit since the last revision:
> > Fix generic warnings
>
> modules/javafx.base/src/main/java/com/sun/javafx/binding/ListenerManager.java line \
> 143:
> > 141: */
> > 142: public void fireValueChanged(I instance, T oldValue) {
> > 143: Object data = getData(instance);
>
> The `data` value could be passed into this method, which would save a (potentially \
> not devirtualized) method call.
Thanks, I'll look into that, it might speed up the 1 listener cases a bit. The same \
applies to OldValueCachingListenerManager#getValue I think. I know it isn't possible \
for the add/remove calls, as the data may change if they're nested, but for \
`fireValueChanged` I never really checked after going to this strategy.
-------------
PR Review Comment: https://git.openjdk.org/jfx/pull/1081#discussion_r1272805838
[prev in list] [next in list] [prev in thread] [next in thread]
Configure |
About |
News |
Add a list |
Sponsored by KoreLogic