RFR: 8364146: JList getScrollableUnitIncrement return 0
Abhishek Kumar
abhiscxk at openjdk.org
Fri Aug 1 06:47:54 UTC 2025
On Mon, 28 Jul 2025 09:14:48 GMT, Prasanta Sadhukhan <psadhukhan at openjdk.org> wrote:
> It seems JList.getScrollableUnitIncrement can sometime return 0 instead of positive number which is not specified in the javadoc which can lead to confusion. Clarified javadoc as to when it can return 0.
src/java.desktop/share/classes/javax/swing/JList.java line 2512:
> 2510: * @return the "unit" increment for scrolling in the specified direction;
> 2511: * which is usually positive. But it can return 0
> 2512: * if {@code visibleRect} points to that row
should it be `the` or `that` ?
Suggestion:
* if {@code visibleRect} points to the row
Requires a CSR too ?
-------------
PR Review Comment: https://git.openjdk.org/jdk/pull/26500#discussion_r2247118982
More information about the client-libs-dev
mailing list