1 7 package org.gjt.jclasslib.browser.detail.elementvalues; 8 9 import org.gjt.jclasslib.browser.BrowserServices; 10 import org.gjt.jclasslib.browser.BrowserTreeNode; 11 import org.gjt.jclasslib.browser.detail.FixedListDetailPane; 12 import org.gjt.jclasslib.structures.elementvalues.ElementValue; 13 import org.gjt.jclasslib.util.ExtendedJLabel; 14 15 import javax.swing.tree.TreePath ; 16 17 18 25 public class GenericElementValueDetailPane extends FixedListDetailPane { 26 27 private ExtendedJLabel lblTag; 28 private ExtendedJLabel lblTagVerbose; 29 30 public GenericElementValueDetailPane(BrowserServices services) { 31 super(services); 32 } 33 34 protected void setupLabels() { 35 addDetailPaneEntry(normalLabel("Tag:"), 36 lblTag = highlightLabel(), 37 lblTagVerbose = highlightLabel()); 38 } 39 40 public void show(TreePath treePath) { 41 ElementValue ceve = (ElementValue) 42 ((BrowserTreeNode)treePath.getLastPathComponent()).getElement(); 43 44 lblTag.setText(String.valueOf((char)ceve.getTag())); 45 lblTagVerbose.setText("<" + ElementValue.getTagDescription(ceve.getTag()) + ">"); 46 47 super.show(treePath); 48 } 49 } 50 | Popular Tags |