Browse Source

Pull request #2664: MOBILE-29857【RN】设计器上圆点指示器选中填充色设置后没有生效

Merge in DESIGN/design from ~HANS/design:release/10.0 to release/10.0

* commit 'd8576dcefca8b06713c0cdb375c6113fb0e9a43a':
  MOBILE-29857【RN】设计器上圆点指示器选中填充色设置后没有生效
feature/big-screen
wei 4 years ago
parent
commit
d34bdbe947
  1. 31
      designer-form/src/main/java/com/fr/design/widget/ui/designer/mobile/component/MobileTabCommonSettingPane.java

31
designer-form/src/main/java/com/fr/design/widget/ui/designer/mobile/component/MobileTabCommonSettingPane.java

@ -35,6 +35,7 @@ public class MobileTabCommonSettingPane extends BasicPane {
private ModeButtonGroup<Integer> buttonGroup;
private NewColorSelectBox initDotColorBox;
private NewColorSelectBox selectDotColorBox;
private boolean isPopulate;
public MobileTabCommonSettingPane(boolean isTopComponent) {
initComponent(isTopComponent);
@ -89,23 +90,27 @@ public class MobileTabCommonSettingPane extends BasicPane {
initDotColorBox = new NewColorSelectBox(0){
@Override
protected void iniListener() {
}
@Override
public void mouseClicked(MouseEvent e) {
super.mouseClicked(e);
this.attributeChange();
this.addSelectChangeListener(new ChangeListener() {
@Override
public void stateChanged(ChangeEvent e) {
if (!isPopulate) {
attributeChange();
}
}
});
}
};
selectDotColorBox = new NewColorSelectBox(0){
@Override
protected void iniListener() {
}
@Override
public void mouseClicked(MouseEvent e) {
super.mouseClicked(e);
this.attributeChange();
this.addSelectChangeListener(new ChangeListener() {
@Override
public void stateChanged(ChangeEvent e) {
if (!isPopulate) {
attributeChange();
}
}
});
}
};
JPanel initDotColorPane = TableLayoutHelper.createGapTableLayoutPane(new Component[][]{new Component[]{initColorLabel, initDotColorBox}}, TableLayoutHelper.FILL_LASTCOLUMN, IntervalConstants.INTERVAL_L1, LayoutConstants.VGAP_MEDIUM);
@ -189,7 +194,9 @@ public class MobileTabCommonSettingPane extends BasicPane {
color = defaultColor;
}
if (color != colorBox.getSelectObject()) {
isPopulate = true;
colorBox.setSelectObject(color);
isPopulate = false;
}
}

Loading…
Cancel
Save