FileDocCategorySizeDatePackage
TrackListRenderer.javaAPI Docmp4parser 1.0-RC-171082Wed Dec 19 20:10:21 GMT 2012com.coremedia.iso.gui

TrackListRenderer

public class TrackListRenderer extends DefaultListCellRenderer

Fields Summary
Constructors Summary
Methods Summary
public java.awt.ComponentgetListCellRendererComponent(javax.swing.JList list, java.lang.Object value, int index, boolean isSelected, boolean cellHasFocus)

        final long trackId;
        if (value instanceof TrackBox) {
            TrackBox trackBox = ((TrackBox) value);
            trackId = trackBox.getTrackHeaderBox().getTrackId();
        } else {
            TrackFragmentBox traf = ((TrackFragmentBox) value);
            trackId = traf.getTrackFragmentHeaderBox().getTrackId();
        }
        value = "Track " + trackId;
        super.getListCellRendererComponent(list, value, index, isSelected, cellHasFocus);
        return this;