mirror of
https://github.com/JFormDesigner/FlatLaf.git
synced 2025-12-06 14:00:55 +03:00
TabbedPane: fixed ArrayIndexOutOfBoundsException in case of using "card" tab type and using a custom tab selection model that returns -1 for selected tab (issue #875)
This commit is contained in:
@@ -1685,7 +1685,7 @@ debug*/
|
|||||||
w - (ci.left / 100f) - (ci.right / 100f), h - (ci.top / 100f) - (ci.bottom / 100f) ), false );
|
w - (ci.left / 100f) - (ci.right / 100f), h - (ci.top / 100f) - (ci.bottom / 100f) ), false );
|
||||||
|
|
||||||
// add gap for selected tab to path
|
// add gap for selected tab to path
|
||||||
if( getTabType() == TAB_TYPE_CARD ) {
|
if( getTabType() == TAB_TYPE_CARD && selectedIndex >= 0 ) {
|
||||||
float csh = scale( (float) contentSeparatorHeight );
|
float csh = scale( (float) contentSeparatorHeight );
|
||||||
|
|
||||||
Rectangle tabRect = getTabBounds( tabPane, selectedIndex );
|
Rectangle tabRect = getTabBounds( tabPane, selectedIndex );
|
||||||
|
|||||||
Reference in New Issue
Block a user