r62 - trunk/faxtomail-ui-swing/src/main/java/com/franciaflex/faxtomail/ui/swing/util
Author: kmorin Date: 2014-05-12 11:05:34 +0200 (Mon, 12 May 2014) New Revision: 62 Url: http://forge.codelutin.com/projects/faxtomail/repository/revisions/62 Log: make the project build Modified: trunk/faxtomail-ui-swing/src/main/java/com/franciaflex/faxtomail/ui/swing/util/CheckBoxListCellRenderer.java Modified: trunk/faxtomail-ui-swing/src/main/java/com/franciaflex/faxtomail/ui/swing/util/CheckBoxListCellRenderer.java =================================================================== --- trunk/faxtomail-ui-swing/src/main/java/com/franciaflex/faxtomail/ui/swing/util/CheckBoxListCellRenderer.java 2014-05-12 08:51:37 UTC (rev 61) +++ trunk/faxtomail-ui-swing/src/main/java/com/franciaflex/faxtomail/ui/swing/util/CheckBoxListCellRenderer.java 2014-05-12 09:05:34 UTC (rev 62) @@ -25,25 +25,19 @@ */ import javax.swing.*; -import javax.swing.event.*; import javax.swing.border.*; import javax.swing.plaf.ComponentUI; -import javax.swing.text.JTextComponent; import java.awt.*; -import java.awt.List; import java.io.Serializable; -import java.util.*; -import com.franciaflex.faxtomail.persistence.entities.EtatAttente; import com.franciaflex.faxtomail.persistence.entities.HasLabel; import com.google.common.base.Function; import com.google.common.collect.Lists; import org.apache.commons.lang3.StringUtils; import org.apache.commons.logging.Log; import org.apache.commons.logging.LogFactory; -import sun.swing.DefaultLookup; import static org.nuiton.i18n.I18n.t; @@ -109,8 +103,8 @@ checkbox.setName("List.cellRenderer"); } - private Border getNoFocusBorder(JComponent component, ComponentUI ui) { - Border border = DefaultLookup.getBorder(component, ui, "List.cellNoFocusBorder"); + private Border getNoFocusBorder() { + Border border = UIManager.getBorder("List.cellNoFocusBorder"); if (System.getSecurityManager() != null) { if (border != null) return border; return SAFE_NO_FOCUS_BORDER; @@ -167,8 +161,8 @@ && !dropLocation.isInsert() && dropLocation.getIndex() == index) { - bg = DefaultLookup.getColor(component, ui, "List.dropCellBackground"); - fg = DefaultLookup.getColor(component, ui, "List.dropCellForeground"); + bg = UIManager.getColor("List.dropCellBackground"); + fg = UIManager.getColor("List.dropCellForeground"); isSelected = true; } @@ -190,13 +184,13 @@ Border border = null; if (cellHasFocus) { if (isSelected) { - border = DefaultLookup.getBorder(component, ui, "List.focusSelectedCellHighlightBorder"); + border = UIManager.getBorder("List.focusSelectedCellHighlightBorder"); } if (border == null) { - border = DefaultLookup.getBorder(component, ui, "List.focusCellHighlightBorder"); + border = UIManager.getBorder("List.focusCellHighlightBorder"); } } else { - border = getNoFocusBorder(component, ui); + border = getNoFocusBorder(); } component.setBorder(border);
participants (1)
-
kmorin@users.forge.codelutin.com