Browse Source

REPORT-13310 设计器来回切换模板, 非常卡

bugfix/10.0
Hades 6 years ago
parent
commit
30de22f58d
  1. 16
      designer-base/src/main/java/com/fr/design/gui/imenu/UIBasicMenuItemUI.java

16
designer-base/src/main/java/com/fr/design/gui/imenu/UIBasicMenuItemUI.java

@ -667,18 +667,10 @@ public class UIBasicMenuItemUI extends MenuItemUI {
} }
private void installFont(final String prefix, final JComponent menuItem) { private void installFont(final String prefix, final JComponent menuItem) {
Thread thread = new Thread(new Runnable() { if (menuItem == null) {
@Override return;
public void run() { }
if (menuItem == null) { LookAndFeel.installColorsAndFont(menuItem, prefix + ".background", prefix + ".foreground", prefix + ".font");
return;
}
LookAndFeel.installColorsAndFont(menuItem, prefix + ".background", prefix + ".foreground", prefix + ".font");
}
});
thread.setName("UIBasicMenuItemUI");
thread.setDaemon(true);
thread.start();
} }
protected Dimension getPreferredMenuItemSize(JComponent c, Icon checkIcon, protected Dimension getPreferredMenuItemSize(JComponent c, Icon checkIcon,

Loading…
Cancel
Save