Browse Source

MenuItem: Uninstall before the menuItem gets set to null.

pull/245/head
weisj 3 years ago
parent
commit
f7a5aabd67
No known key found for this signature in database
GPG Key ID: 31124CB75461DA2A
  1. 2
      core/src/main/java/com/github/weisj/darklaf/ui/menu/DarkMenuItemUIBase.java
  2. 2
      core/src/main/java/com/github/weisj/darklaf/ui/menu/DarkMenuUI.java

2
core/src/main/java/com/github/weisj/darklaf/ui/menu/DarkMenuItemUIBase.java

@ -65,8 +65,8 @@ public class DarkMenuItemUIBase extends BasicMenuItemUI implements MenuItemUI {
@Override
public void uninstallUI(JComponent c) {
super.uninstallUI(c);
MenuItemLayoutHelper.clearUsedParentClientProperties(menuItem);
super.uninstallUI(c);
}
@Override

2
core/src/main/java/com/github/weisj/darklaf/ui/menu/DarkMenuUI.java

@ -53,8 +53,8 @@ public class DarkMenuUI extends BasicMenuUI implements MenuItemUI {
@Override
public void uninstallUI(JComponent c) {
super.uninstallUI(c);
MenuItemLayoutHelper.clearUsedParentClientProperties(menuItem);
super.uninstallUI(c);
}
@Override

Loading…
Cancel
Save