Browse Source

dev->master

master
xiaohu 9 years ago
parent
commit
5ebadf7e29
  1. 10
      designer_base/src/com/fr/design/dialog/BasicScrollPane.java
  2. 4
      designer_base/src/com/fr/design/editor/editor/ColumnSelectedEditor.java
  3. 10
      designer_base/src/com/fr/design/gui/ibutton/UIButtonGroup.java
  4. 7
      designer_base/src/com/fr/design/gui/ibutton/UITabGroup.java

10
designer_base/src/com/fr/design/dialog/BasicScrollPane.java

@ -153,8 +153,9 @@ public abstract class BasicScrollPane<T> extends BasicBeanPane<T>{
scrollBar.setEnabled(false);
scrollBar.setVisible(false);
} else {
scrollBar.setEnabled(true);
scrollBar.setVisible(true);
boolean show = isShowScrollBar();
scrollBar.setEnabled(show);
scrollBar.setVisible(show);
}
maxheight = getHeight() - DET_HEIGHT;
if ((MAXVALUE - scrollBar.getVisibleAmount()) == 0) {
@ -179,8 +180,13 @@ public abstract class BasicScrollPane<T> extends BasicBeanPane<T>{
}
leftcontentPane.validate();
}
}
protected boolean isShowScrollBar() {
return true;
}
@Override
public T updateBean() {
return null;

4
designer_base/src/com/fr/design/editor/editor/ColumnSelectedEditor.java

@ -13,6 +13,7 @@ import com.fr.stable.StringUtils;
import java.awt.*;
import java.awt.event.ItemEvent;
import java.awt.event.ItemListener;
import java.util.List;
import java.util.regex.Pattern;
/**
@ -35,6 +36,9 @@ public class ColumnSelectedEditor extends Editor<SimpleDSColumn> {
@Override
public void itemStateChanged(ItemEvent e) {
//这边需要重新初始化columnNames, 否则nameList长度和columnNames长度不同导致出錯。
List<String> nameList = tableDataComboBox.getSelectedItem().calculateColumnNameList();
columnNames = new String[nameList.size()];
columnNames = tableDataComboBox.getSelectedItem().calculateColumnNameList().toArray(columnNames);
columnNameComboBox.removeAllItems();
for (int i = 0; i < columnNames.length; i++) {

10
designer_base/src/com/fr/design/gui/ibutton/UIButtonGroup.java

@ -1,12 +1,6 @@
package com.fr.design.gui.ibutton;
import java.awt.BorderLayout;
import java.awt.Graphics;
import java.awt.Graphics2D;
import java.awt.GridLayout;
import java.awt.Insets;
import java.awt.RenderingHints;
import java.awt.Shape;
import java.awt.*;
import java.awt.event.ActionListener;
import java.awt.event.MouseAdapter;
import java.awt.event.MouseEvent;
@ -174,7 +168,7 @@ public class UIButtonGroup<T> extends JPanel implements GlobalNameObserver {
return BorderFactory.createEmptyBorder(1, 1, 1, 1);
}
protected GridLayout getGridLayout(int number) {
protected LayoutManager getGridLayout(int number) {
return new GridLayout(0, number, 1, 0);
}

7
designer_base/src/com/fr/design/gui/ibutton/UITabGroup.java

@ -1,9 +1,6 @@
package com.fr.design.gui.ibutton;
import java.awt.Graphics;
import java.awt.Graphics2D;
import java.awt.GridLayout;
import java.awt.RenderingHints;
import java.awt.*;
import javax.swing.BorderFactory;
import javax.swing.Icon;
@ -38,7 +35,7 @@ public class UITabGroup extends UIButtonGroup<Integer> {
}
@Override
protected GridLayout getGridLayout(int number) {
protected LayoutManager getGridLayout(int number) {
if (number < BUTTON_NUMBER || isOneLineTab) {
return super.getGridLayout(number);
} else if (number == BUTTON_NUMBER || number == SEVEN_NUMBER) {

Loading…
Cancel
Save