RFR: 8272229: BasicSplitPaneDivider:oneTouchExpandableChanged() returns leftButton and rightButton as null with GTKLookAndFeel [v3]

Jayathirth D V jdv at openjdk.java.net
Tue Oct 5 11:42:06 UTC 2021


On Tue, 5 Oct 2021 09:26:00 GMT, Prasanta Sadhukhan <psadhukhan at openjdk.org> wrote:

>> Pankaj Bansal has updated the pull request incrementally with one additional commit since the last revision:
>> 
>>   Changes according to JBS discussion
>
> src/java.desktop/share/classes/javax/swing/plaf/basic/BasicSplitPaneDivider.java line 379:
> 
>> 377:     /**
>> 378:      * Messaged when the oneTouchExpandable value of the JSplitPane the
>> 379:      * divider is contained in changes. Will create the
> 
> I guess "value of the current JSplitPane divider" makes more sense. 
> Also, I guess leftButton,rightButton wll be created not only if they are null but also when oneTouchExpandable property is set as per code..It might seem to user from current wording that left/right button will be set if they are null even if oneTouchExpandable is not set.

Messaged when XXXX is little bit confusing but since it is used at many places we can alter them may be as part of another bug.

As @prsadhuk mentioned we can update second statement as "Creates <code>leftButton</code> and <code>rightButton</code> if they are null and corresponding <code>JSplitPane</code> supports oneTouchExpandable buttons"

Its better to use "divider" instead of receiver for same reasons in third statement and update "invalidates" -> "Invalidates".

Since this just clarifies the behavior of this function and nothing is changed from compatibility side. I dont think it needs a CSR.

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

PR: https://git.openjdk.java.net/jdk/pull/5263



More information about the client-libs-dev mailing list