Class ColumnDateSizer

All Implemented Interfaces:
TableCellRefreshListener, TableCellToolTipListener, TableColumn, TableColumnExtraInfoListener, TableColumnCore, Comparator<TableRowCore>
Direct Known Subclasses:
BadAvailTimeItem, ColumnActivityDate, ColumnSubscriptionLastChecked, ColumnSubscriptionNewestDate, ColumnSubscriptionNextUpdate, DateAddedItem, DateAddedItem, DateCompletedItem, DateFileCompletedItem, DateLastActiveItem, DateLastQueuedItem, DateLastXferItem, FileCreationItem, FileModifiedItem, LastScrapeTimeItem, LastUpdateItem, ShareRatioProgressItem, TagAddedToDateItem, TorrentCreateDateItem

public abstract class ColumnDateSizer extends CoreTableColumnSWT implements TableCellRefreshListener, TableCellToolTipListener
  • Field Details

    • PADDING

      private static int PADDING
    • configDateFormatListener

      private ParameterListener configDateFormatListener
    • curFormat

      int curFormat
    • maxWidthUsed

      int[] maxWidthUsed
    • maxWidthDate

      Date[] maxWidthDate
    • showTime

      private boolean showTime
    • multiline

      private boolean multiline
    • tableFormatOverride

      private String tableFormatOverride
    • cdf

    • sortInvalidToBottom

      private boolean sortInvalidToBottom
    • sortChanging

      private int sortChanging
    • recalculatingWidths

      private boolean recalculatingWidths
  • Constructor Details

    • ColumnDateSizer

      public ColumnDateSizer(String sName, int iAlignment, int iPosition, int iWidth, String sTableID)
    • ColumnDateSizer

      public ColumnDateSizer(Class forDataSourceType, String columnID, int width, String tableID)
  • Method Details

    • init

      private void init()
    • remove

      public void remove()
      Specified by:
      remove in interface TableColumn
      Overrides:
      remove in class TableColumnImpl
    • postConfigLoad

      public void postConfigLoad()
      Description copied from interface: TableColumn
      implement this method if you want to be notified when the stored column configuration such as user data or GUI-adjustable properties have been loaded
      Specified by:
      postConfigLoad in interface TableColumn
      Overrides:
      postConfigLoad in class TableColumnImpl
    • refresh

      public final void refresh(TableCell cell)
      Description copied from interface: TableCellRefreshListener
      Triggered based on refresh interval specified in TableColumn.getRefreshInterval()
      Specified by:
      refresh in interface TableCellRefreshListener
      Parameters:
      cell - TableCell that the refresh trigger is for
    • refresh

      public void refresh(TableCell cell, long timestamp)
    • refresh

      public void refresh(TableCell cell, long timestamp, String prefix)
    • refresh

      public void refresh(TableCell cell, long timestamp, long sort_order, String prefix)
    • setWidthPX

      public void setWidthPX(int width)
      Specified by:
      setWidthPX in interface TableColumn
      Overrides:
      setWidthPX in class TableColumnImpl
    • recalcWidth

      private void recalcWidth(Date date, String prefix)
    • calcWidth

      private int calcWidth(Date date, String format, String prefix)
    • getShowTime

      public boolean getShowTime()
    • setShowTime

      public void setShowTime(boolean showTime)
    • isMultiline

      public boolean isMultiline()
      Returns:
      the multiline
    • setMultiline

      public void setMultiline(boolean multiline)
      Parameters:
      multiline - the multiline to set
    • cellHover

      public void cellHover(TableCell cell)
      Description copied from interface: TableCellToolTipListener
      triggered when a cell's tooltip is about to be displayed.
      Specified by:
      cellHover in interface TableCellToolTipListener
      Parameters:
      cell - TableCell which the tooltip will be displayed for
    • cellHoverComplete

      public void cellHoverComplete(TableCell cell)
      Description copied from interface: TableCellToolTipListener
      triggered when a cell's tooltip is about to be removed.
      Specified by:
      cellHoverComplete in interface TableCellToolTipListener
      Parameters:
      cell - TableCell which the tooltip will be removed
    • setSortInvalidToBottom

      public void setSortInvalidToBottom(boolean b)
    • setSortValue

      private boolean setSortValue(TableCell cell, long value)
    • setSortAscending

      public void setSortAscending(boolean bAscending)
      Specified by:
      setSortAscending in interface TableColumnCore
      Overrides:
      setSortAscending in class TableColumnImpl
      Parameters:
      bAscending - The bAscending to set.