Browse Source

Pull request #6543: REPORT-61788 创建组件时,弹窗出来的非常慢

Merge in DESIGN/design from ~STARRYI/design:feature/x to feature/x

* commit 'e8e61428e07b0ed71ea07b847a1b61e9e774833d':
  REPORT-61788 创建组件时,弹窗出来的非常慢
feature/x
starryi 3 years ago
parent
commit
aa75c9046d
  1. 11
      designer-realize/src/main/java/com/fr/design/share/ui/generate/ShareMainPane.java

11
designer-realize/src/main/java/com/fr/design/share/ui/generate/ShareMainPane.java

@ -8,6 +8,7 @@ import com.fr.design.dialog.FineJOptionPane;
import com.fr.design.extra.LoginWebBridge;
import com.fr.design.gui.ibutton.UIButton;
import com.fr.design.gui.icheckbox.UICheckBox;
import com.fr.design.gui.icombobox.LazyComboBox;
import com.fr.design.gui.icombobox.UIComboBox;
import com.fr.design.gui.icombocheckbox.UIComboCheckBox;
import com.fr.design.gui.icontainer.UIScrollPane;
@ -50,6 +51,7 @@ import com.fr.stable.collections.combination.Pair;
import com.fr.stable.pinyin.PinyinHelper;
import java.awt.TextField;
import java.util.Collections;
import java.util.HashMap;
import org.jetbrains.annotations.NotNull;
@ -299,8 +301,13 @@ public class ShareMainPane extends JPanel {
return styleComboBox.getSelectedItem() != null;
}
};
this.styleComboBox = ShareUIUtils.wrapUI(placeHolderUI, new UIComboBox());
this.styleComboBox.refreshBoxItems(StyleTheme.getStyleThemeTypeInfo());
this.styleComboBox = ShareUIUtils.wrapUI(placeHolderUI, new LazyComboBox() {
@Override
public Object[] load() {
List<StyleThemeBean> themeBeanList = StyleTheme.getStyleThemeTypeInfo();
return themeBeanList.toArray();
}
});
styleComboBox.setPreferredSize(new Dimension(COMBO_WIDTH, COMBO_HEIGHT));
pane.add(styleComboBox);
return pane;

Loading…
Cancel
Save