Browse Source

Merge branch 'release/10.0' of ssh://code.fineres.com:7999/~zheng/C-design into release/10.0

zheng-1641779399395
shine 3 years ago
parent
commit
8c767ba1c6
  1. 2
      designer-base/src/main/java/com/fr/design/actions/community/BugAction.java
  2. 2
      designer-base/src/main/java/com/fr/design/actions/community/NeedAction.java
  3. 17
      designer-base/src/main/java/com/fr/design/actions/community/StudyPlanAction.java
  4. 4
      designer-base/src/main/java/com/fr/design/gui/controlpane/UIListGroupControlPane.java
  5. 2
      designer-base/src/main/java/com/fr/design/mainframe/toolbar/ToolBarMenuDock.java
  6. BIN
      designer-base/src/main/resources/com/fr/design/images/bbs/studyPlan.png
  7. 1
      designer-base/src/main/resources/com/fr/design/images/bbs/studyPlan_normal.svg
  8. 33
      designer-form/src/main/java/com/fr/design/mainframe/ArrangementType.java
  9. 1
      designer-form/src/main/java/com/fr/design/mainframe/JForm.java
  10. 81
      designer-form/src/main/java/com/fr/design/mainframe/MultiSelectionArrangement.java
  11. 14
      designer-form/src/main/java/com/fr/design/mainframe/widget/arrangement/buttons/AbstractMultiSelectionArrangementButton.java
  12. 15
      designer-form/src/main/java/com/fr/design/mainframe/widget/arrangement/buttons/BottomAlignButton.java
  13. 15
      designer-form/src/main/java/com/fr/design/mainframe/widget/arrangement/buttons/HorizontalCenterButton.java
  14. 15
      designer-form/src/main/java/com/fr/design/mainframe/widget/arrangement/buttons/HorizontalDistributionButton.java
  15. 15
      designer-form/src/main/java/com/fr/design/mainframe/widget/arrangement/buttons/LeftAlignButton.java
  16. 4
      designer-form/src/main/java/com/fr/design/mainframe/widget/arrangement/buttons/MultiSelectionArrangementButton.java
  17. 15
      designer-form/src/main/java/com/fr/design/mainframe/widget/arrangement/buttons/RightAlignButton.java
  18. 15
      designer-form/src/main/java/com/fr/design/mainframe/widget/arrangement/buttons/TopAlignButton.java
  19. 13
      designer-form/src/main/java/com/fr/design/mainframe/widget/arrangement/buttons/VerticalCenterButton.java
  20. 13
      designer-form/src/main/java/com/fr/design/mainframe/widget/arrangement/buttons/VerticalDistributionButton.java
  21. 5
      designer-form/src/main/java/com/fr/design/mainframe/widget/ui/FormMultiWidgetCardPane.java
  22. 1
      designer-realize/src/main/java/com/fr/start/preload/ImagePreLoader.java

2
designer-base/src/main/java/com/fr/design/actions/community/BugAction.java

@ -17,7 +17,7 @@ public class BugAction extends AbstractDesignerSSO {
@Override
public String getJumpUrl() {
return CloudCenter.getInstance().acquireUrlByKind("bbs.bugs", "http://bbs.fanruan.com/forum-156-1.html");
return CloudCenter.getInstance().acquireUrlByKind("bbs.bugs", "https://service.fanruan.com/PF/FR/feedback");
}
public static final MenuKeySet BUG = new MenuKeySet() {

2
designer-base/src/main/java/com/fr/design/actions/community/NeedAction.java

@ -18,7 +18,7 @@ public class NeedAction extends AbstractDesignerSSO {
@Override
public String getJumpUrl() {
return CloudCenter.getInstance().acquireUrlByKind("bbs.needs", "http://bbs.fanruan.com/forum-56-1.html");
return CloudCenter.getInstance().acquireUrlByKind("bbs.needs", "https://service.fanruan.com/PF/FR/feedback");
}
public static final MenuKeySet NEED = new MenuKeySet() {

17
designer-base/src/main/java/com/fr/design/actions/community/StudyPlanAction.java

@ -0,0 +1,17 @@
package com.fr.design.actions.community;
import com.fr.design.i18n.Toolkit;
import com.fr.design.login.AbstractDesignerSSO;
import com.fr.general.CloudCenter;
public class StudyPlanAction extends AbstractDesignerSSO {
public StudyPlanAction() {
this.setName(Toolkit.i18nText("Fine-Design_Study_Plan"));
this.setSmallIcon("/com/fr/design/images/bbs/studyPlan");
}
@Override
public String getJumpUrl() {
return CloudCenter.getInstance().acquireUrlByKind("bbs.studyPlan", "https://edu.fanruan.com/studypath/finereport");
}
}

4
designer-base/src/main/java/com/fr/design/gui/controlpane/UIListGroupControlPane.java

@ -125,7 +125,9 @@ public abstract class UIListGroupControlPane extends UIControlPane implements Li
for (int i = 0, size = widget.getListenerSize(); i < size; i++) {
Listener listener = widget.getListener(i);
if (!listener.isDefault()) {
nameObjectList.add(i, new NameObject(switchLang(listener.getEventName()) + (i + 1), listener));
String eventName = switchLang(listener.getEventName()) + (nameObjectList.size() + 1);
NameObject nameObject = new NameObject(eventName, listener);
nameObjectList.add(nameObject);
}
}
populate(getHelper().processCatalog(nameObjectList));

2
designer-base/src/main/java/com/fr/design/mainframe/toolbar/ToolBarMenuDock.java

@ -17,6 +17,7 @@ import com.fr.design.actions.community.FacebookFansAction;
import com.fr.design.actions.community.NeedAction;
import com.fr.design.actions.community.QuestionAction;
import com.fr.design.actions.community.SignAction;
import com.fr.design.actions.community.StudyPlanAction;
import com.fr.design.actions.community.TechSolutionAction;
import com.fr.design.actions.community.TechSupportAction;
import com.fr.design.actions.community.TemplateStoreAction;
@ -597,6 +598,7 @@ public abstract class ToolBarMenuDock {
shortCuts.add(new TutorialAction());
}
}, SupportLocaleImpl.TUTORIAL_COMMUNITY);
shortCuts.add(new StudyPlanAction());
shortCuts.add(new QuestionAction());
shortCuts.add(new TechSolutionAction());

BIN
designer-base/src/main/resources/com/fr/design/images/bbs/studyPlan.png

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.1 KiB

1
designer-base/src/main/resources/com/fr/design/images/bbs/studyPlan_normal.svg

@ -0,0 +1 @@
<svg id="图层_1" data-name="图层 1" xmlns="http://www.w3.org/2000/svg" viewBox="0 0 16 16"><title>l</title><path d="M8.77.94A7.13,7.13,0,0,0,3.27,2.8,7.2,7.2,0,0,0,8.14,15.3a7.11,7.11,0,0,0,3.23-.77l-.54-1a6,6,0,1,1,2.34-2.08.59.59,0,0,0,1,.65A7.2,7.2,0,0,0,8.77.94Z"/><path d="M6.35,8.54h3.73a1.66,1.66,0,0,0,0-3.31H6.79a1.08,1.08,0,0,0-2.06.47A1.08,1.08,0,0,0,5.81,6.78a1.1,1.1,0,0,0,1-.61h3.29a.72.72,0,0,1,0,1.43H6.35a1.82,1.82,0,0,0,0,3.63H9.73a.87.87,0,0,0,.69.35.86.86,0,1,0-.73-1.29H6.35a.88.88,0,0,1,0-1.75ZM6.19,5.71a.38.38,0,1,1-.38-.38A.38.38,0,0,1,6.19,5.71ZM10.42,11a.28.28,0,0,1-.27-.28.27.27,0,0,1,.54,0A.28.28,0,0,1,10.42,11Z"/></svg>

After

Width:  |  Height:  |  Size: 655 B

33
designer-form/src/main/java/com/fr/design/mainframe/ArrangementType.java

@ -0,0 +1,33 @@
package com.fr.design.mainframe;
public enum ArrangementType {
LEFT_ALIGN(0),
RIGHT_ALIGN(1),
TOP_ALIGN(2),
BOTTOM_ALIGN(3),
HORIZONTAL_CENTER_ALIGN(4),
VERTICAL_CENTER_ALIGN(5),
HORIZONTAL_AUTO_DISTRIBUTION(6),
HORIZONTAL_MANUAL_DISTRIBUTION(7),
VERTICAL_AUTO_DISTRIBUTION(8),
VERTICAL_MANUAL_DISTRIBUTION(9);
private int type;
ArrangementType(int type) {
this.type = type;
}
public int getType() {
return this.type;
}
public static ArrangementType parse(int type) {
for (ArrangementType arrangementType : ArrangementType.values()) {
if (arrangementType.getType() == type) {
return arrangementType;
}
}
return LEFT_ALIGN;
}
}

1
designer-form/src/main/java/com/fr/design/mainframe/JForm.java

@ -16,6 +16,7 @@ import com.fr.design.actions.core.WorkBookSupportable;
import com.fr.design.actions.file.export.EmbeddedFormExportExportAction;
import com.fr.design.base.mode.DesignModeContext;
import com.fr.design.cell.FloatElementsProvider;
import com.fr.design.constants.TableDataConstants;
import com.fr.design.data.datapane.TableDataTreePane;
import com.fr.design.designer.TargetComponent;
import com.fr.design.designer.beans.actions.CopyAction;

81
designer-form/src/main/java/com/fr/design/mainframe/MultiSelectionArrangement.java

@ -15,67 +15,103 @@ import java.util.Comparator;
import java.util.List;
public class MultiSelectionArrangement {
private static final int DEFAULT_GAP = 10;
private FormDesigner designer;
private XLayoutContainer parent; // 当前选中的那些组件所在父容器
private List<XCreator> selectedCreators;
private Rectangle rec;
public MultiSelectionArrangement(FormDesigner designer) {
this.designer = designer;
update();
}
public void leftAlign() {
public void doArrangement(ArrangementType type) {
doArrangement(type, DEFAULT_GAP);
}
public void doArrangement(ArrangementType type, int gap) {
updatePosition();
switch (type) {
case RIGHT_ALIGN:
rightAlign();
break;
case TOP_ALIGN:
topAlign();
break;
case BOTTOM_ALIGN:
bottomAlign();
break;
case HORIZONTAL_CENTER_ALIGN:
horizontalCenterAlign();
break;
case VERTICAL_CENTER_ALIGN:
verticalCenterAlign();
break;
case HORIZONTAL_AUTO_DISTRIBUTION:
horizontalAutoDistribution();
break;
case HORIZONTAL_MANUAL_DISTRIBUTION:
horizontalManualDistribution(gap);
break;
case VERTICAL_AUTO_DISTRIBUTION:
verticalAutoDistribution();
break;
case VERTICAL_MANUAL_DISTRIBUTION:
verticalManualDistribution(gap);
break;
case LEFT_ALIGN:
default:
leftAlign();
break;
}
updateModel();
}
private void leftAlign() {
for (XCreator creator : selectedCreators) {
creator.setLocation(rec.x, creator.getY());
}
update();
}
public void rightAlign() {
private void rightAlign() {
for (XCreator creator : selectedCreators) {
creator.setLocation(rec.x + rec.width - creator.getWidth(), creator.getY());
}
update();
}
public void topAlign() {
private void topAlign() {
for (XCreator creator : selectedCreators) {
creator.setLocation(creator.getX(), rec.y);
}
update();
}
public void bottomAlign() {
private void bottomAlign() {
for (XCreator creator : selectedCreators) {
creator.setLocation(creator.getX(), rec.y + rec.height - creator.getHeight());
}
update();
}
public void horizontalCenterAlign() {
private void horizontalCenterAlign() {
for (XCreator creator : selectedCreators) {
creator.setLocation(rec.x + rec.width / 2 - creator.getWidth() / 2, creator.getY());
}
update();
}
public void verticalCenterAlign() {
private void verticalCenterAlign() {
for (XCreator creator : selectedCreators) {
creator.setLocation(creator.getX(), rec.y + rec.height / 2 - creator.getHeight() / 2);
}
update();
}
// 水平分布,自动,间距由selectedCreators和border共同计算而来
public void horizontalAutoDistribution() {
private void horizontalAutoDistribution() {
sortHorizontal();
int[] gaps = calculateHorizontalGaps();
horizontalDistribution(gaps);
}
// 水平分布,手动,传入一个间距,排列selectedCreators
public void horizontalManualDistribution(int gap) {
private void horizontalManualDistribution(int gap) {
sortHorizontal();
reSizeRecByHorizontal(gap);
horizontalDistribution(fillGaps(gap, selectedCreators.size() - 1));
@ -87,7 +123,6 @@ public class MultiSelectionArrangement {
XCreator preCreator = selectedCreators.get(i - 1);
creator.setLocation(preCreator.getX() + preCreator.getWidth() + gaps[i - 1], creator.getY());
}
update();
}
private void reSizeRecByHorizontal(int gap) {
@ -145,13 +180,13 @@ public class MultiSelectionArrangement {
return calculateIntegerGaps(distanceBetweenHeadAndTailCreators - sum, gapCount);
}
public void verticalAutoDistribution() {
private void verticalAutoDistribution() {
sortVertical();
int[] gaps = calculateVerticalGaps();
verticalDistribution(gaps);
}
public void verticalManualDistribution(int gap) {
private void verticalManualDistribution(int gap) {
sortVertical();
reSizeRecByVertical(gap);
verticalDistribution(fillGaps(gap, selectedCreators.size() - 1));
@ -163,7 +198,6 @@ public class MultiSelectionArrangement {
XCreator preCreator = selectedCreators.get(i - 1);
creator.setLocation(creator.getX(), preCreator.getY() + preCreator.getHeight() + gaps[i - 1]);
}
update();
}
private void reSizeRecByVertical(int gap) {
@ -252,12 +286,15 @@ public class MultiSelectionArrangement {
return gaps;
}
private void update() {
private void updatePosition() {
FormSelection selection = designer.getSelectionModel().getSelection();
this.selectedCreators = Arrays.asList(selection.getSelectedCreators());
this.rec = selection.getSelctionBounds();
this.parent = getParent(selection.getSelectedCreator());
}
private void updateModel() {
FormSelection selection = designer.getSelectionModel().getSelection();
XLayoutContainer parent = getParent(selection.getSelectedCreator());
if (parent != null) {
// 这里要修改修改engine里面的对象才能成功保存,光修改设计器对象没用
WLayout wabs = parent.toData();

14
designer-form/src/main/java/com/fr/design/mainframe/widget/arrangement/buttons/AbstractMultiSelectionArrangementButton.java

@ -5,6 +5,9 @@ import com.fr.design.event.UIObserverListener;
import com.fr.design.gui.ibutton.UIButton;
import com.fr.design.mainframe.MultiSelectionArrangement;
import java.awt.event.ActionEvent;
import java.awt.event.ActionListener;
public abstract class AbstractMultiSelectionArrangementButton extends UIButton implements MultiSelectionArrangementButton, UIObserver {
private static final long serialVersionUID = -2114423583742242771L;
protected MultiSelectionArrangement arrangement;
@ -29,4 +32,15 @@ public abstract class AbstractMultiSelectionArrangementButton extends UIButton i
public boolean shouldResponseChangeListener() {
return true;
}
@Override
public ActionListener getActionListener() {
return new ActionListener() {
@Override
public void actionPerformed(ActionEvent e) {
arrangement.doArrangement(getArrangementType());
uiObserverListener.doChange();
}
};
}
}

15
designer-form/src/main/java/com/fr/design/mainframe/widget/arrangement/buttons/BottomAlignButton.java

@ -1,14 +1,15 @@
package com.fr.design.mainframe.widget.arrangement.buttons;
import com.fr.design.i18n.Toolkit;
import com.fr.design.mainframe.ArrangementType;
import com.fr.design.mainframe.MultiSelectionArrangement;
import com.fr.general.IOUtils;
import javax.swing.Icon;
import java.awt.event.ActionEvent;
import java.awt.event.ActionListener;
public class BottomAlignButton extends AbstractMultiSelectionArrangementButton {
private static final long serialVersionUID = 2397455240682353024L;
public BottomAlignButton(MultiSelectionArrangement arrangement) {
super(arrangement);
}
@ -24,13 +25,7 @@ public class BottomAlignButton extends AbstractMultiSelectionArrangementButton {
}
@Override
public ActionListener getActionListener() {
return new ActionListener() {
@Override
public void actionPerformed(ActionEvent e) {
arrangement.bottomAlign();
uiObserverListener.doChange();
}
};
public ArrangementType getArrangementType() {
return ArrangementType.BOTTOM_ALIGN;
}
}

15
designer-form/src/main/java/com/fr/design/mainframe/widget/arrangement/buttons/HorizontalCenterButton.java

@ -1,14 +1,15 @@
package com.fr.design.mainframe.widget.arrangement.buttons;
import com.fr.design.i18n.Toolkit;
import com.fr.design.mainframe.ArrangementType;
import com.fr.design.mainframe.MultiSelectionArrangement;
import com.fr.general.IOUtils;
import javax.swing.Icon;
import java.awt.event.ActionEvent;
import java.awt.event.ActionListener;
public class HorizontalCenterButton extends AbstractMultiSelectionArrangementButton {
private static final long serialVersionUID = 6290178236460051049L;
public HorizontalCenterButton(MultiSelectionArrangement arrangement) {
super(arrangement);
}
@ -24,13 +25,7 @@ public class HorizontalCenterButton extends AbstractMultiSelectionArrangementBut
}
@Override
public ActionListener getActionListener() {
return new ActionListener() {
@Override
public void actionPerformed(ActionEvent e) {
arrangement.horizontalCenterAlign();
uiObserverListener.doChange();
}
};
public ArrangementType getArrangementType() {
return ArrangementType.HORIZONTAL_CENTER_ALIGN;
}
}

15
designer-form/src/main/java/com/fr/design/mainframe/widget/arrangement/buttons/HorizontalDistributionButton.java

@ -1,14 +1,15 @@
package com.fr.design.mainframe.widget.arrangement.buttons;
import com.fr.design.i18n.Toolkit;
import com.fr.design.mainframe.ArrangementType;
import com.fr.design.mainframe.MultiSelectionArrangement;
import com.fr.general.IOUtils;
import javax.swing.Icon;
import java.awt.event.ActionEvent;
import java.awt.event.ActionListener;
public class HorizontalDistributionButton extends AbstractMultiSelectionArrangementButton {
private static final long serialVersionUID = 5052092252720664954L;
public HorizontalDistributionButton(MultiSelectionArrangement arrangement) {
super(arrangement);
}
@ -24,13 +25,7 @@ public class HorizontalDistributionButton extends AbstractMultiSelectionArrangem
}
@Override
public ActionListener getActionListener() {
return new ActionListener() {
@Override
public void actionPerformed(ActionEvent e) {
arrangement.horizontalAutoDistribution();
uiObserverListener.doChange();
}
};
public ArrangementType getArrangementType() {
return ArrangementType.HORIZONTAL_AUTO_DISTRIBUTION;
}
}

15
designer-form/src/main/java/com/fr/design/mainframe/widget/arrangement/buttons/LeftAlignButton.java

@ -1,14 +1,15 @@
package com.fr.design.mainframe.widget.arrangement.buttons;
import com.fr.design.i18n.Toolkit;
import com.fr.design.mainframe.ArrangementType;
import com.fr.design.mainframe.MultiSelectionArrangement;
import com.fr.general.IOUtils;
import javax.swing.Icon;
import java.awt.event.ActionEvent;
import java.awt.event.ActionListener;
public class LeftAlignButton extends AbstractMultiSelectionArrangementButton {
private static final long serialVersionUID = -8177637788632733710L;
public LeftAlignButton(MultiSelectionArrangement arrangement) {
super(arrangement);
}
@ -24,13 +25,7 @@ public class LeftAlignButton extends AbstractMultiSelectionArrangementButton {
}
@Override
public ActionListener getActionListener() {
return new ActionListener() {
@Override
public void actionPerformed(ActionEvent e) {
arrangement.leftAlign();
uiObserverListener.doChange();
}
};
public ArrangementType getArrangementType() {
return ArrangementType.LEFT_ALIGN;
}
}

4
designer-form/src/main/java/com/fr/design/mainframe/widget/arrangement/buttons/MultiSelectionArrangementButton.java

@ -1,5 +1,7 @@
package com.fr.design.mainframe.widget.arrangement.buttons;
import com.fr.design.mainframe.ArrangementType;
import javax.swing.Icon;
import java.awt.event.ActionListener;
@ -9,4 +11,6 @@ public interface MultiSelectionArrangementButton {
String getTipText();
ActionListener getActionListener();
ArrangementType getArrangementType();
}

15
designer-form/src/main/java/com/fr/design/mainframe/widget/arrangement/buttons/RightAlignButton.java

@ -1,14 +1,15 @@
package com.fr.design.mainframe.widget.arrangement.buttons;
import com.fr.design.i18n.Toolkit;
import com.fr.design.mainframe.ArrangementType;
import com.fr.design.mainframe.MultiSelectionArrangement;
import com.fr.general.IOUtils;
import javax.swing.Icon;
import java.awt.event.ActionEvent;
import java.awt.event.ActionListener;
public class RightAlignButton extends AbstractMultiSelectionArrangementButton {
private static final long serialVersionUID = -8698936349956288409L;
public RightAlignButton(MultiSelectionArrangement arrangement) {
super(arrangement);
}
@ -24,13 +25,7 @@ public class RightAlignButton extends AbstractMultiSelectionArrangementButton {
}
@Override
public ActionListener getActionListener() {
return new ActionListener() {
@Override
public void actionPerformed(ActionEvent e) {
arrangement.rightAlign();
uiObserverListener.doChange();
}
};
public ArrangementType getArrangementType() {
return ArrangementType.RIGHT_ALIGN;
}
}

15
designer-form/src/main/java/com/fr/design/mainframe/widget/arrangement/buttons/TopAlignButton.java

@ -1,14 +1,15 @@
package com.fr.design.mainframe.widget.arrangement.buttons;
import com.fr.design.i18n.Toolkit;
import com.fr.design.mainframe.ArrangementType;
import com.fr.design.mainframe.MultiSelectionArrangement;
import com.fr.general.IOUtils;
import javax.swing.Icon;
import java.awt.event.ActionEvent;
import java.awt.event.ActionListener;
public class TopAlignButton extends AbstractMultiSelectionArrangementButton {
private static final long serialVersionUID = 2896267783075870924L;
public TopAlignButton(MultiSelectionArrangement arrangement) {
super(arrangement);
}
@ -24,13 +25,7 @@ public class TopAlignButton extends AbstractMultiSelectionArrangementButton {
}
@Override
public ActionListener getActionListener() {
return new ActionListener() {
@Override
public void actionPerformed(ActionEvent e) {
arrangement.topAlign();
uiObserverListener.doChange();
}
};
public ArrangementType getArrangementType() {
return ArrangementType.TOP_ALIGN;
}
}

13
designer-form/src/main/java/com/fr/design/mainframe/widget/arrangement/buttons/VerticalCenterButton.java

@ -1,12 +1,11 @@
package com.fr.design.mainframe.widget.arrangement.buttons;
import com.fr.design.i18n.Toolkit;
import com.fr.design.mainframe.ArrangementType;
import com.fr.design.mainframe.MultiSelectionArrangement;
import com.fr.general.IOUtils;
import javax.swing.Icon;
import java.awt.event.ActionEvent;
import java.awt.event.ActionListener;
public class VerticalCenterButton extends AbstractMultiSelectionArrangementButton {
public VerticalCenterButton(MultiSelectionArrangement arrangement) {
@ -24,13 +23,7 @@ public class VerticalCenterButton extends AbstractMultiSelectionArrangementButto
}
@Override
public ActionListener getActionListener() {
return new ActionListener() {
@Override
public void actionPerformed(ActionEvent e) {
arrangement.verticalCenterAlign();
uiObserverListener.doChange();
}
};
public ArrangementType getArrangementType() {
return ArrangementType.VERTICAL_CENTER_ALIGN;
}
}

13
designer-form/src/main/java/com/fr/design/mainframe/widget/arrangement/buttons/VerticalDistributionButton.java

@ -1,12 +1,11 @@
package com.fr.design.mainframe.widget.arrangement.buttons;
import com.fr.design.i18n.Toolkit;
import com.fr.design.mainframe.ArrangementType;
import com.fr.design.mainframe.MultiSelectionArrangement;
import com.fr.general.IOUtils;
import javax.swing.Icon;
import java.awt.event.ActionEvent;
import java.awt.event.ActionListener;
public class VerticalDistributionButton extends AbstractMultiSelectionArrangementButton {
public VerticalDistributionButton(MultiSelectionArrangement arrangement) {
@ -24,13 +23,7 @@ public class VerticalDistributionButton extends AbstractMultiSelectionArrangemen
}
@Override
public ActionListener getActionListener() {
return new ActionListener() {
@Override
public void actionPerformed(ActionEvent e) {
arrangement.verticalAutoDistribution();
uiObserverListener.doChange();
}
};
public ArrangementType getArrangementType() {
return ArrangementType.VERTICAL_AUTO_DISTRIBUTION;
}
}

5
designer-form/src/main/java/com/fr/design/mainframe/widget/ui/FormMultiWidgetCardPane.java

@ -9,6 +9,7 @@ import com.fr.design.gui.itextfield.UITextField;
import com.fr.design.i18n.Toolkit;
import com.fr.design.layout.TableLayout;
import com.fr.design.layout.TableLayoutHelper;
import com.fr.design.mainframe.ArrangementType;
import com.fr.design.mainframe.FormDesigner;
import com.fr.design.mainframe.MultiSelectionArrangement;
import com.fr.design.mainframe.widget.arrangement.buttons.BottomAlignButton;
@ -186,9 +187,9 @@ public class FormMultiWidgetCardPane extends FormWidgetCardPane {
int gap = (int) Math.floor(Float.parseFloat(text));
numberField.setValue(gap);
if (isVertical) {
arrangement.verticalManualDistribution(gap);
arrangement.doArrangement(ArrangementType.VERTICAL_MANUAL_DISTRIBUTION, gap);
} else {
arrangement.horizontalManualDistribution(gap);
arrangement.doArrangement(ArrangementType.HORIZONTAL_MANUAL_DISTRIBUTION, gap);
}
attributeChanged();
}

1
designer-realize/src/main/java/com/fr/start/preload/ImagePreLoader.java

@ -175,6 +175,7 @@ public class ImagePreLoader {
"/com/fr/design/images/bbs/center_normal.svg",
"/com/fr/design/images/bbs/sign_normal.svg",
"/com/fr/design/images/bbs/facebook_normal.svg",
"/com/fr/design/images/bbs/studyPlan_normal.svg",
"/com/fr/design/images/update/update_new_normal.svg",
"com/fr/design/images/signature.png",
"com/fr/design/images/m_file/switch.png",

Loading…
Cancel
Save