On Thu, 22 Jun 2023 18:44:00 GMT, Sergey Bylokhov <[email protected]> wrote:

>> Only pass value changed event to the native accessibility peer when the 
>> value is actually changed. While at fixing it for RadioButton also fixing it 
>> for checkbox and toggle button so there is no need to re-visit this file 
>> later.
>> Also updating the copyright year.
>
> src/java.desktop/macosx/classes/sun/lwawt/macosx/CAccessible.java line 185:
> 
>> 183:                     // Do send check box state changes to native side
>> 184:                     if (thisRole == AccessibleRole.CHECK_BOX) {
>> 185:                         if (newValue != null && 
>> !newValue.equals(oldValue)) {
> 
> Is it possible to have "newValue == null" and the "oldValue != null"? Do we 
> need to update the native in this case?

No. Null value is not a correct value to be set for these types of control so 
if null is passed then it is not a real value update event.

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

PR Review Comment: https://git.openjdk.org/jdk/pull/14605#discussion_r1238908558

Reply via email to