|
|
@ -9,6 +9,7 @@ import com.fr.design.gui.ibutton.UIColorButton; |
|
|
|
import com.fr.design.gui.ibutton.UIToggleButton; |
|
|
|
import com.fr.design.gui.ibutton.UIToggleButton; |
|
|
|
import com.fr.design.gui.icombobox.UIComboBox; |
|
|
|
import com.fr.design.gui.icombobox.UIComboBox; |
|
|
|
import com.fr.design.gui.ilable.UILabel; |
|
|
|
import com.fr.design.gui.ilable.UILabel; |
|
|
|
|
|
|
|
import com.fr.design.gui.iscrollbar.UIScrollBar; |
|
|
|
import com.fr.design.gui.ispinner.UISpinner; |
|
|
|
import com.fr.design.gui.ispinner.UISpinner; |
|
|
|
import com.fr.design.i18n.Toolkit; |
|
|
|
import com.fr.design.i18n.Toolkit; |
|
|
|
import com.fr.design.layout.FRGUIPaneFactory; |
|
|
|
import com.fr.design.layout.FRGUIPaneFactory; |
|
|
@ -23,6 +24,7 @@ import com.fr.form.ui.mobile.radiogroup.ImageMobileStyle; |
|
|
|
import com.fr.general.FRFont; |
|
|
|
import com.fr.general.FRFont; |
|
|
|
|
|
|
|
|
|
|
|
import javax.swing.*; |
|
|
|
import javax.swing.*; |
|
|
|
|
|
|
|
import javax.swing.border.EmptyBorder; |
|
|
|
import javax.swing.event.ChangeEvent; |
|
|
|
import javax.swing.event.ChangeEvent; |
|
|
|
import javax.swing.event.ChangeListener; |
|
|
|
import javax.swing.event.ChangeListener; |
|
|
|
import java.awt.*; |
|
|
|
import java.awt.*; |
|
|
@ -83,6 +85,14 @@ public class ImageCustomDefinePane extends MobileStyleCustomDefinePane { |
|
|
|
protected JPanel createContentPane() { |
|
|
|
protected JPanel createContentPane() { |
|
|
|
return scrollPanel; |
|
|
|
return scrollPanel; |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
@Override |
|
|
|
|
|
|
|
protected void setLeftContentPaneBounds(Container parent, UIScrollBar scrollBar, int beginY, int maxheight) { |
|
|
|
|
|
|
|
int width = parent.getWidth(); |
|
|
|
|
|
|
|
int height = parent.getHeight(); |
|
|
|
|
|
|
|
leftcontentPane.setBounds(0, -beginY, width - scrollBar.getWidth() + getOverWidth(), leftcontentPane.getPreferredSize().height); |
|
|
|
|
|
|
|
scrollBar.setBounds(width - scrollBar.getWidth(), 0, scrollBar.getWidth(), height); |
|
|
|
|
|
|
|
} |
|
|
|
}; |
|
|
|
}; |
|
|
|
this.add(basicScrollPane); |
|
|
|
this.add(basicScrollPane); |
|
|
|
} |
|
|
|
} |
|
|
@ -157,9 +167,10 @@ public class ImageCustomDefinePane extends MobileStyleCustomDefinePane { |
|
|
|
private void initButtonAlignPane() { |
|
|
|
private void initButtonAlignPane() { |
|
|
|
UILabel buttonAlignLabel = DesignerUtils.createConfigLabel(Toolkit.i18nText("Fine-Plugin-RadioGroup_Alignment")); |
|
|
|
UILabel buttonAlignLabel = DesignerUtils.createConfigLabel(Toolkit.i18nText("Fine-Plugin-RadioGroup_Alignment")); |
|
|
|
buttonAlignCombo = new UIComboBox(new String[]{ |
|
|
|
buttonAlignCombo = new UIComboBox(new String[]{ |
|
|
|
Toolkit.i18nText("Fine-Plugin-RadioGroup_Alignment_Split"), |
|
|
|
|
|
|
|
Toolkit.i18nText("Fine-Plugin-RadioGroup_Alignment_Nature"), |
|
|
|
Toolkit.i18nText("Fine-Plugin-RadioGroup_Alignment_Nature"), |
|
|
|
|
|
|
|
Toolkit.i18nText("Fine-Plugin-RadioGroup_Alignment_Split"), |
|
|
|
}); |
|
|
|
}); |
|
|
|
|
|
|
|
buttonAlignCombo.setSelectedIndex(1); |
|
|
|
buttonAlignCombo.setPreferredSize(new Dimension(DesignerUtils.LARGE_COMBO_WIDTH, 20)); |
|
|
|
buttonAlignCombo.setPreferredSize(new Dimension(DesignerUtils.LARGE_COMBO_WIDTH, 20)); |
|
|
|
buttonAlignPane = TableLayoutHelper.createGapTableLayoutPane(new Component[][]{new Component[]{buttonAlignLabel, buttonAlignCombo}}, TableLayoutHelper.FILL_LASTCOLUMN, IntervalConstants.INTERVAL_L1, LayoutConstants.VGAP_SMALL); |
|
|
|
buttonAlignPane = TableLayoutHelper.createGapTableLayoutPane(new Component[][]{new Component[]{buttonAlignLabel, buttonAlignCombo}}, TableLayoutHelper.FILL_LASTCOLUMN, IntervalConstants.INTERVAL_L1, LayoutConstants.VGAP_SMALL); |
|
|
|
} |
|
|
|
} |
|
|
@ -271,18 +282,22 @@ public class ImageCustomDefinePane extends MobileStyleCustomDefinePane { |
|
|
|
|
|
|
|
|
|
|
|
UILabel initialLabel = DesignerUtils.createConfigLabel(Toolkit.i18nText("Fine-Plugin-RadioGroup_Icon_Init")); |
|
|
|
UILabel initialLabel = DesignerUtils.createConfigLabel(Toolkit.i18nText("Fine-Plugin-RadioGroup_Icon_Init")); |
|
|
|
UILabel selectedLabel = DesignerUtils.createConfigLabel(Toolkit.i18nText("Fine-Plugin-RadioGroup_Icon_Select")); |
|
|
|
UILabel selectedLabel = DesignerUtils.createConfigLabel(Toolkit.i18nText("Fine-Plugin-RadioGroup_Icon_Select")); |
|
|
|
|
|
|
|
initialLabel.setVerticalAlignment(SwingConstants.TOP); |
|
|
|
|
|
|
|
initialLabel.setBorder(new EmptyBorder(5, 0, 0, 0)); |
|
|
|
|
|
|
|
selectedLabel.setVerticalAlignment(SwingConstants.TOP); |
|
|
|
|
|
|
|
selectedLabel.setBorder(new EmptyBorder(5, 0, 0, 0)); |
|
|
|
initInitialIconConfigPane(); |
|
|
|
initInitialIconConfigPane(); |
|
|
|
initSelectedIconConfigPane(); |
|
|
|
initSelectedIconConfigPane(); |
|
|
|
JPanel container = FRGUIPaneFactory.createVerticalFlowLayout_Pane(true, FlowLayout.LEADING, 0, 5); |
|
|
|
JPanel container = FRGUIPaneFactory.createVerticalFlowLayout_Pane(true, FlowLayout.LEADING, 0, 5); |
|
|
|
|
|
|
|
|
|
|
|
JPanel initialPane = FRGUIPaneFactory.createNormalFlowInnerContainer_S_Pane(); |
|
|
|
JPanel initialPane = FRGUIPaneFactory.createBorderLayout_S_Pane(); |
|
|
|
initialPane.add(initialLabel); |
|
|
|
initialPane.add(initialLabel, BorderLayout.WEST); |
|
|
|
initialPane.add(initialIconConfigPane); |
|
|
|
initialPane.add(initialIconConfigPane, BorderLayout.CENTER); |
|
|
|
container.add(initialPane); |
|
|
|
container.add(initialPane); |
|
|
|
|
|
|
|
|
|
|
|
JPanel selectedPane = FRGUIPaneFactory.createNormalFlowInnerContainer_S_Pane(); |
|
|
|
JPanel selectedPane = FRGUIPaneFactory.createBorderLayout_S_Pane(); |
|
|
|
selectedPane.add(selectedLabel); |
|
|
|
selectedPane.add(selectedLabel, BorderLayout.WEST); |
|
|
|
selectedPane.add(selectedIconConfigPane); |
|
|
|
selectedPane.add(selectedIconConfigPane, BorderLayout.CENTER); |
|
|
|
container.add(selectedPane); |
|
|
|
container.add(selectedPane); |
|
|
|
|
|
|
|
|
|
|
|
centerPane.add(container); |
|
|
|
centerPane.add(container); |
|
|
|