RFR: 8273324: IllegalArgumentException: fromIndex(0) > toIndex(-1) after clear and select TableCell [v2]

Jose Pereda jpereda at openjdk.java.net
Tue Sep 7 10:02:39 UTC 2021


On Tue, 7 Sep 2021 09:42:43 GMT, Ambarish Rapte <arapte at openjdk.org> wrote:

>> Michael Strauß has updated the pull request incrementally with one additional commit since the last revision:
>> 
>>   added test
>
> The exception can be observed in one other similar scenario.
> 1. Run the program attached to [JDK-8273324](https://bugs.openjdk.java.net/browse/JDK-8273324).
> 2. Click on a
> 3. Shift + Click on d
> 4. Click on d
> -> The same exception can be observed.

@arapte yes, you are right, I can reproduce it too after the proposed fix is applied. 

For this case, `insertionPoint = 2`, so probably we need:


-if (insertionPoint == 0) {
+if (insertionPoint >= 0) {
```                                
?

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

PR: https://git.openjdk.java.net/jfx/pull/617


More information about the openjfx-dev mailing list