JIDE: JideTabbedPane: fixed hover background of close button on selected tab

This commit is contained in:
Karl Tauber
2021-03-27 18:46:37 +01:00
parent 8e49904f8d
commit 6e990a7e31

View File

@@ -584,12 +584,15 @@ public class FlatJideTabbedPaneUI
if( !scrollableTabLayoutEnabled() || !isShowCloseButton() || !isShowCloseButtonOnTab() )
return;
Color background = _tabPane.getBackground();
for( int i = 0; i < _closeButtons.length; i++ ) {
JButton closeButton = _closeButtons[i];
if( closeButton.getWidth() == 0 || closeButton.getHeight() == 0 )
continue; // not visible
closeButton.setBounds( getTabCloseBounds( i ) );
closeButton.setBackground( background );
}
}