1 4 package com.tc.admin.common; 5 6 import org.dijon.AbstractTableCellRenderer; 7 import org.dijon.Container; 8 import org.dijon.Label; 9 10 import com.tc.admin.AdminClient; 11 import com.tc.admin.AdminClientContext; 12 13 import javax.swing.JComponent ; 14 import javax.swing.border.LineBorder ; 15 16 20 21 public abstract class StatusRenderer extends AbstractTableCellRenderer { 22 protected Container m_statusRenderer; 23 protected Label m_label; 24 protected Label m_indicator; 25 26 public StatusRenderer() { 27 super(); 28 29 AdminClientContext cntx = AdminClient.getContext(); 30 31 m_statusRenderer = (Container)cntx.topRes.resolve("StatusRenderer"); 32 m_label = (Label)m_statusRenderer.findComponent("StatusLabel"); 33 m_indicator = (Label)m_statusRenderer.findComponent("StatusIndicator"); 34 35 m_label.setForeground(null); 36 m_indicator.setOpaque(true); 37 m_indicator.setBorder(LineBorder.createBlackLineBorder()); 38 } 39 40 public JComponent getComponent() { 41 return m_statusRenderer; 42 } 43 } 44 | Popular Tags |