From 8fcd901660310a2f9c12c1c66281f81fb8affc93 Mon Sep 17 00:00:00 2001 From: MoMeak Date: Tue, 19 Sep 2017 15:12:55 +0800 Subject: [PATCH] PMD --- designer/src/com/fr/design/expand/SortExpandAttrPane.java | 2 +- .../src/com/fr/design/gui/ibutton/UIButtonGroup.java | 4 ++++ 2 files changed, 5 insertions(+), 1 deletion(-) diff --git a/designer/src/com/fr/design/expand/SortExpandAttrPane.java b/designer/src/com/fr/design/expand/SortExpandAttrPane.java index 284135bddd..11260c74b4 100644 --- a/designer/src/com/fr/design/expand/SortExpandAttrPane.java +++ b/designer/src/com/fr/design/expand/SortExpandAttrPane.java @@ -30,7 +30,7 @@ public class SortExpandAttrPane extends JPanel { {BaseUtils.readIcon("/com/fr/design/images/expand/des.png"), BaseUtils.readIcon("/com/fr/design/images/expand/des_selected.png")} }; String[] nameArray = { Inter.getLocText("Sort-Original"), Inter.getLocText("Sort-Ascending"), Inter.getLocText("Sort-Descending") }; - sort_type_pane = new UIButtonGroup(iconArray, null); + sort_type_pane = new UIButtonGroup(iconArray); sort_type_pane.setAllToolTips(nameArray); sort_type_pane.setGlobalName(Inter.getLocText("ExpandD-Sort_After_Expand")); this.add(sort_type_pane, BorderLayout.NORTH); diff --git a/designer_base/src/com/fr/design/gui/ibutton/UIButtonGroup.java b/designer_base/src/com/fr/design/gui/ibutton/UIButtonGroup.java index 4133e109cd..a8ad8f0956 100644 --- a/designer_base/src/com/fr/design/gui/ibutton/UIButtonGroup.java +++ b/designer_base/src/com/fr/design/gui/ibutton/UIButtonGroup.java @@ -44,6 +44,10 @@ public class UIButtonGroup extends JPanel implements GlobalNameObserver { this(iconArray, null); } + public UIButtonGroup(Icon[][] iconArray) { + this(iconArray, null); + } + public UIButtonGroup(Icon[] iconArray, T[] objects) { if (!ArrayUtils.isEmpty(objects) && iconArray.length == objects.length) { this.objectList = Arrays.asList(objects);