Styling: clear field oldStyleValues on UI delegate uninstall

This commit is contained in:
Karl Tauber
2021-06-21 21:06:39 +02:00
parent 0c51dfe19c
commit 82192bef91
15 changed files with 31 additions and 0 deletions

View File

@@ -220,6 +220,8 @@ public class FlatButtonUI
protected void uninstallDefaults( AbstractButton b ) {
super.uninstallDefaults( b );
oldStyleValues = null;
MigLayoutVisualPadding.uninstall( b );
defaults_initialized = false;
}

View File

@@ -86,6 +86,7 @@ public class FlatCheckBoxMenuItemUI
super.uninstallDefaults();
renderer = null;
oldStyleValues = null;
}
protected FlatMenuItemRenderer createRenderer() {

View File

@@ -118,6 +118,8 @@ public class FlatEditorPaneUI
oldDisabledBackground = null;
oldInactiveBackground = null;
oldStyleValues = null;
getComponent().putClientProperty( JEditorPane.HONOR_DISPLAY_PROPERTIES, oldHonorDisplayProperties );
}

View File

@@ -86,6 +86,7 @@ public class FlatMenuItemUI
super.uninstallDefaults();
renderer = null;
oldStyleValues = null;
}
protected FlatMenuItemRenderer createRenderer() {

View File

@@ -109,6 +109,7 @@ public class FlatMenuUI
hoverBackground = null;
renderer = null;
oldStyleValues = null;
}
protected FlatMenuItemRenderer createRenderer() {

View File

@@ -140,6 +140,8 @@ public class FlatPasswordFieldUI
oldDisabledBackground = null;
oldInactiveBackground = null;
oldStyleValues = null;
MigLayoutVisualPadding.uninstall( getComponent() );
}

View File

@@ -90,6 +90,13 @@ public class FlatProgressBarUI
verticalSize = UIManager.getDimension( "ProgressBar.verticalSize" );
}
@Override
protected void uninstallDefaults() {
super.uninstallDefaults();
oldStyleValues = null;
}
@Override
protected void installListeners() {
super.installListeners();

View File

@@ -86,6 +86,7 @@ public class FlatRadioButtonMenuItemUI
super.uninstallDefaults();
renderer = null;
oldStyleValues = null;
}
protected FlatMenuItemRenderer createRenderer() {

View File

@@ -117,6 +117,8 @@ public class FlatRadioButtonUI
protected void uninstallDefaults( AbstractButton b ) {
super.uninstallDefaults( b );
oldStyleValues = null;
MigLayoutVisualPadding.uninstall( b );
defaults_initialized = false;
}

View File

@@ -179,6 +179,8 @@ public class FlatScrollBarUI
buttonDisabledArrowColor = null;
hoverButtonBackground = null;
pressedButtonBackground = null;
oldStyleValues = null;
}
@Override

View File

@@ -99,7 +99,9 @@ public class FlatSeparatorUI
@Override
protected void uninstallDefaults( JSeparator s ) {
super.uninstallDefaults( s );
defaults_initialized = false;
oldStyleValues = null;
}
@Override

View File

@@ -110,6 +110,8 @@ public class FlatSplitPaneUI
oneTouchArrowColor = null;
oneTouchHoverArrowColor = null;
oneTouchPressedArrowColor = null;
oldStyleValues = null;
}
@Override

View File

@@ -107,6 +107,8 @@ public class FlatTextAreaUI
oldDisabledBackground = null;
oldInactiveBackground = null;
oldStyleValues = null;
}
@Override

View File

@@ -135,6 +135,8 @@ public class FlatTextFieldUI
oldDisabledBackground = null;
oldInactiveBackground = null;
oldStyleValues = null;
MigLayoutVisualPadding.uninstall( getComponent() );
}

View File

@@ -114,6 +114,8 @@ public class FlatTextPaneUI
oldDisabledBackground = null;
oldInactiveBackground = null;
oldStyleValues = null;
getComponent().putClientProperty( JEditorPane.HONOR_DISPLAY_PROPERTIES, oldHonorDisplayProperties );
}