Browse Source

修正一个小错误

master
fanglei 8 years ago
parent
commit
0403b6e3cc
  1. 3
      designer_base/src/com/fr/design/gui/itable/AbstractPropertyTable.java

3
designer_base/src/com/fr/design/gui/itable/AbstractPropertyTable.java

@ -32,6 +32,7 @@ public abstract class AbstractPropertyTable extends JTable {
public static final Color PROPERTY_SELECTION_BACKGROUND = new Color(153, 204, 255); public static final Color PROPERTY_SELECTION_BACKGROUND = new Color(153, 204, 255);
// 属性表的行高 // 属性表的行高
public static final int PROPERTY_TABLE_ROW_HEIGHT = 22; public static final int PROPERTY_TABLE_ROW_HEIGHT = 22;
private static final int PROPERTY_ICON_WIDTH = 10;
public AbstractPropertyTable() { public AbstractPropertyTable() {
this.setTableProperties(); this.setTableProperties();
@ -180,7 +181,7 @@ public abstract class AbstractPropertyTable extends JTable {
int row = AbstractPropertyTable.super.rowAtPoint(e.getPoint()); int row = AbstractPropertyTable.super.rowAtPoint(e.getPoint());
if (row != -1) { if (row != -1) {
Point pIndex = getGroupIndex(row); Point pIndex = getGroupIndex(row);
if (pIndex.y == 0 && e.getClickCount() == 1 && e.getX() < 10) { if (pIndex.y == 0 && e.getClickCount() == 1 && e.getX() < PROPERTY_ICON_WIDTH) {
toggleCollapse(pIndex.x); toggleCollapse(pIndex.x);
} }
} }

Loading…
Cancel
Save