RFR: 8361283: [Accessibility, macOS, VoiceOver] VoiceOver announced Tab items of JTabbedPane as RadioButton on macOS [v2]

Abhishek Kumar abhiscxk at openjdk.org
Mon Jul 7 04:25:31 UTC 2025


On Fri, 4 Jul 2025 13:55:26 GMT, Artem Semenov <asemenov at openjdk.org> wrote:

>> Abhishek Kumar has updated the pull request incrementally with one additional commit since the last revision:
>> 
>>   Add test
>
> src/java.desktop/macosx/native/libawt_lwawt/awt/a11y/CommonComponentAccessibility.m line 865:
> 
>> 863:     NSString *value = nil;
>> 864: 
>> 865:     if ([[self javaRole] isEqualToString:@"pagetab"]) {
> 
> Мне кажется было бы лучше просто переопределить:
> 
> - (NSString *)accessibilityRoleDescription
> 
> В ```src/java.desktop/macosx/native/libawt_lwawt/awt/a11y/TabButtonAccessibility.m```
> 
> 
> It seems it would be better to simply override:
> 
> - (NSString *)accessibilityRoleDescription
> 
> in ```src/java.desktop/macosx/native/libawt_lwawt/awt/a11y/TabButtonAccessibility.m```

I thought of overriding this method but the changes are very minimal.
Even if this method is overridden in `TabButtonAccessibility.m` and the value returned is `nil` then we need to either fallback to parent's class method or need to copy the entire implementation in `TabButtonAccessibility`.

So, I think this should be ok to cater the changes here.

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

PR Review Comment: https://git.openjdk.org/jdk/pull/26096#discussion_r2188932862


More information about the client-libs-dev mailing list