Browse Source

Merge pull request #886 in DESIGN/design from ~XIAOXIA/design:release/10.0 to release/10.0

* commit 'e3fab788d6205e43a25ad063c9f6869fda485431':
  REPORT-16570 @xiaoxia windows下模板版本管理备注显示不全
bugfix/10.0
xiaoxia 6 years ago
parent
commit
d6792651b3
  1. 1
      designer-base/src/main/java/com/fr/design/mainframe/vcs/common/VcsHelper.java
  2. 2
      designer-base/src/main/java/com/fr/design/mainframe/vcs/ui/FileVersionCellEditor.java
  3. 3
      designer-base/src/main/java/com/fr/design/mainframe/vcs/ui/FileVersionCellRender.java

1
designer-base/src/main/java/com/fr/design/mainframe/vcs/common/VcsHelper.java

@ -44,6 +44,7 @@ public class VcsHelper implements JTemplateActionListener {
public final static Icon VCS_DELETE_PNG = IOUtils.readIcon("/com/fr/design/images/vcs/icon_delete.png"); public final static Icon VCS_DELETE_PNG = IOUtils.readIcon("/com/fr/design/images/vcs/icon_delete.png");
public final static Icon VCS_USER_PNG = IOUtils.readIcon("/com/fr/design/images/vcs/icon_user@1x.png"); public final static Icon VCS_USER_PNG = IOUtils.readIcon("/com/fr/design/images/vcs/icon_user@1x.png");
public final static Icon VCS_REVERT = IOUtils.readIcon("/com/fr/design/images/vcs/icon_revert.png"); public final static Icon VCS_REVERT = IOUtils.readIcon("/com/fr/design/images/vcs/icon_revert.png");
public final static int OFFSET = 2;
private final static String VCS_DIR = "vcs"; private final static String VCS_DIR = "vcs";
public final static String VCS_CACHE_DIR = pathJoin(VCS_DIR, "cache"); public final static String VCS_CACHE_DIR = pathJoin(VCS_DIR, "cache");
private static final int MINUTE = 60 * 1000; private static final int MINUTE = 60 * 1000;

2
designer-base/src/main/java/com/fr/design/mainframe/vcs/ui/FileVersionCellEditor.java

@ -68,7 +68,7 @@ public class FileVersionCellEditor extends AbstractCellEditor implements TableCe
double height = editor.getPreferredSize().getHeight(); double height = editor.getPreferredSize().getHeight();
if (table.getRowHeight(row) != height) { if (table.getRowHeight(row) != height) {
table.setRowHeight(row, (int) height); table.setRowHeight(row, (int) height + VcsHelper.OFFSET);
} }
return editor; return editor;
} }

3
designer-base/src/main/java/com/fr/design/mainframe/vcs/ui/FileVersionCellRender.java

@ -1,5 +1,6 @@
package com.fr.design.mainframe.vcs.ui; package com.fr.design.mainframe.vcs.ui;
import com.fr.design.mainframe.vcs.common.VcsHelper;
import com.fr.report.entity.VcsEntity; import com.fr.report.entity.VcsEntity;
import javax.swing.JPanel; import javax.swing.JPanel;
@ -34,7 +35,7 @@ public class FileVersionCellRender implements TableCellRenderer {
double height = editor.getPreferredSize().getHeight(); double height = editor.getPreferredSize().getHeight();
if (table.getRowHeight(row) != height) { if (table.getRowHeight(row) != height) {
table.setRowHeight(row, (int) height); table.setRowHeight(row, (int) height + VcsHelper.OFFSET);
} }
return editor; return editor;
} }

Loading…
Cancel
Save