|
|
@ -277,11 +277,11 @@ public class UIColorPickerPane extends BasicPane implements UIObserver { |
|
|
|
*/ |
|
|
|
*/ |
|
|
|
public Dimension getPreferredSize() { |
|
|
|
public Dimension getPreferredSize() { |
|
|
|
if (designTypeButtonGroup.getSelectedIndex() == 0) { |
|
|
|
if (designTypeButtonGroup.getSelectedIndex() == 0) { |
|
|
|
return new Dimension(colorGroup.getPreferredSize().width + textGroup.getPreferredSize().width, upControlPane.getPreferredSize().height + getBoundY()); |
|
|
|
return new Dimension(colorGroup.getPreferredSize().width + textGroup.getPreferredSize().width, upControlPane.getPreferredSize().height + getPreferredMarginY()); |
|
|
|
} else { |
|
|
|
} else { |
|
|
|
int extra = stagePanel == null ? 0 : stagePanel.getPreferredSize().height + getBoundY(); |
|
|
|
int extra = stagePanel == null ? 0 : stagePanel.getPreferredSize().height + getPreferredMarginY(); |
|
|
|
return new Dimension(colorGroup.getPreferredSize().width + textGroup.getPreferredSize().width, |
|
|
|
return new Dimension(colorGroup.getPreferredSize().width + textGroup.getPreferredSize().width, |
|
|
|
extra + textGroup.getPreferredSize().height + upControlPane.getPreferredSize().height + OFF_HEIGHT + getBoundY()); |
|
|
|
extra + textGroup.getPreferredSize().height + upControlPane.getPreferredSize().height + OFF_HEIGHT + getPreferredMarginY()); |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
@ -662,6 +662,10 @@ public class UIColorPickerPane extends BasicPane implements UIObserver { |
|
|
|
return UPCONTROLPANE_WIDTH; |
|
|
|
return UPCONTROLPANE_WIDTH; |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
protected int getPreferredMarginY() { |
|
|
|
|
|
|
|
return MARGIN_TOP; |
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
/** |
|
|
|
/** |
|
|
|
*刷新颜色选取器 |
|
|
|
*刷新颜色选取器 |
|
|
|
* @param colorArray 颜色值 |
|
|
|
* @param colorArray 颜色值 |
|
|
|