From 2af35bcb35a7c37d6e50aa1321d80708e5d7fc79 Mon Sep 17 00:00:00 2001 From: "yaoh.wu" Date: Sun, 4 Nov 2018 23:05:43 +0800 Subject: [PATCH] =?UTF-8?q?=E6=97=A0=E4=BB=BB=E5=8A=A1=EF=BC=8Cfindbugs?= =?UTF-8?q?=E4=BF=AE=E5=A4=8D?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../src/main/java/com/fr/design/file/TemplateTreePane.java | 2 -- .../fr/design/gui/itree/filetree/FileNodeComparator.java | 6 ++++-- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/designer-base/src/main/java/com/fr/design/file/TemplateTreePane.java b/designer-base/src/main/java/com/fr/design/file/TemplateTreePane.java index 61d071e00a..7f2fcd2cfe 100644 --- a/designer-base/src/main/java/com/fr/design/file/TemplateTreePane.java +++ b/designer-base/src/main/java/com/fr/design/file/TemplateTreePane.java @@ -303,8 +303,6 @@ public class TemplateTreePane extends JPanel implements FileOperations { private boolean deleteNodes(Collection nodes) { - boolean isLocal = WorkContext.getCurrent().isLocal(); - boolean success = true; for (ExpandMutableTreeNode treeNode : nodes) { Object node = treeNode.getUserObject(); diff --git a/designer-base/src/main/java/com/fr/design/gui/itree/filetree/FileNodeComparator.java b/designer-base/src/main/java/com/fr/design/gui/itree/filetree/FileNodeComparator.java index f963d80d14..9c9533bd4a 100644 --- a/designer-base/src/main/java/com/fr/design/gui/itree/filetree/FileNodeComparator.java +++ b/designer-base/src/main/java/com/fr/design/gui/itree/filetree/FileNodeComparator.java @@ -3,13 +3,15 @@ package com.fr.design.gui.itree.filetree; import com.fr.base.FRContext; import com.fr.file.filetree.FileNode; +import java.io.Serializable; +import java.util.Arrays; import java.util.Comparator; /** * FileTreeNode compare... * Directory is in the first. and normal file the in the last. */ -public class FileNodeComparator implements Comparator { +public class FileNodeComparator implements Comparator, Serializable { /** * 正序还是倒序 */ @@ -46,7 +48,7 @@ public class FileNodeComparator implements Comparator { public FileNodeComparator(boolean reverse, String[] types) { this.isReverse = reverse; - this.supportTypes = types; + this.supportTypes = Arrays.copyOf(types, types.length); } /**