Browse Source

Pull request #2694: CHART-15808 抽出createUISpinner

Merge in DESIGN/design from ~ZHENG/c-design:release/10.0 to release/10.0

* commit '9ab2402ba2f7eff5bc1fc0f40a5cd635bf094859':
  CHART-15808 抽出createUISpinner
feature/big-screen
zheng 4 years ago
parent
commit
8b07f114f2
  1. 17
      designer-base/src/main/java/com/fr/design/gui/frpane/UINumberDragPane.java

17
designer-base/src/main/java/com/fr/design/gui/frpane/UINumberDragPane.java

@ -1,17 +1,16 @@
package com.fr.design.gui.frpane;
import java.awt.BorderLayout;
import java.awt.Dimension;
import javax.swing.event.ChangeEvent;
import javax.swing.event.ChangeListener;
import com.fr.design.beans.BasicBeanPane;
import com.fr.design.event.GlobalNameListener;
import com.fr.design.event.GlobalNameObserver;
import com.fr.design.gui.ispinner.UISpinner;
import com.fr.design.gui.style.NumberDragBar;
import javax.swing.event.ChangeEvent;
import javax.swing.event.ChangeListener;
import java.awt.BorderLayout;
import java.awt.Dimension;
public class UINumberDragPane extends BasicBeanPane<Double> implements GlobalNameObserver {
private static final long serialVersionUID = -8681716725163358249L;
@ -35,7 +34,7 @@ public class UINumberDragPane extends BasicBeanPane<Double> implements GlobalNam
public UINumberDragPane(double minValue, double maxValue, double dierta) {
dragBar = new NumberDragBar((int) minValue, (int) maxValue);
spinner = new UISpinner(minValue, maxValue, dierta, minValue);
spinner = createUISpinner(minValue, maxValue, dierta);
spinner.setGlobalName(com.fr.design.i18n.Toolkit.i18nText("Fine-Design_Basic_StyleAlignment_Text_Rotation"));
this.setLayout(new BorderLayout(4, 0));
this.add(spinner, BorderLayout.EAST);
@ -66,6 +65,10 @@ public class UINumberDragPane extends BasicBeanPane<Double> implements GlobalNam
});
}
protected UISpinner createUISpinner(double minValue, double maxValue, double dierta) {
return new UISpinner(minValue, maxValue, dierta, minValue);
}
/**
* 添加事件
* @param l 事件

Loading…
Cancel
Save