FileDocCategorySizeDatePackage
DoneItem.javaAPI DocAzureus 3.0.3.42149Mon Feb 19 14:24:06 GMT 2007org.gudy.azureus2.ui.swt.views.tableitems.mytorrents

DoneItem

public class DoneItem extends org.gudy.azureus2.ui.swt.views.table.utils.CoreTableColumn implements TableCellRefreshListener
% Done column in My Torrents
author
Olivier
author
TuxPaper (2004/Apr/17: modified to TableCellAdapter)

Fields Summary
Constructors Summary
public DoneItem(String sTableID)
Default Constructor

    super("done", ALIGN_TRAIL, POSITION_INVISIBLE, 55, sTableID);
    setRefreshInterval(INTERVAL_LIVE);
    if (sTableID.equals(TableManager.TABLE_MYTORRENTS_INCOMPLETE))
      setPosition(POSITION_LAST);
    else
      setPosition(POSITION_INVISIBLE);
    setMinWidthAuto(true);
  
Methods Summary
public voidrefresh(TableCell cell)

    DownloadManager dm = (DownloadManager)cell.getDataSource();
    int value = (dm == null) ? 0 : dm.getStats().getCompleted();
    if (!cell.setSortValue(value) && cell.isValid())
      return;
    cell.setText(DisplayFormatters.formatPercentFromThousands(value));