added missing since 1.3

This commit is contained in:
Karl Tauber
2021-07-02 10:21:55 +02:00
parent 294b8bb789
commit 731c8962c9
3 changed files with 9 additions and 0 deletions

View File

@@ -607,6 +607,9 @@ public class FlatComboBoxUI
return parentParent != null && !comboBox.getBackground().equals( parentParent.getBackground() );
}
/**
* @since 1.3
*/
public static boolean isPermanentFocusOwner( JComboBox<?> comboBox ) {
if( comboBox.isEditable() ) {
Component editorComponent = comboBox.getEditor().getEditorComponent();

View File

@@ -332,6 +332,9 @@ public class FlatScrollPaneUI
paint( g, c );
}
/**
* @since 1.3
*/
public static boolean isPermanentFocusOwner( JScrollPane scrollPane ) {
JViewport viewport = scrollPane.getViewport();
Component view = (viewport != null) ? viewport.getView() : null;

View File

@@ -226,6 +226,9 @@ public class FlatSpinnerUI
: null;
}
/**
* @since 1.3
*/
public static boolean isPermanentFocusOwner( JSpinner spinner ) {
if( FlatUIUtils.isPermanentFocusOwner( spinner ) )
return true;