jET
1.0alpha4


org.jet.tracks
Class TrackPalette

java.lang.Object
  |
  +--javax.swing.table.AbstractTableModel
        |
        +--org.jet.tracks.TrackPalette
All Implemented Interfaces:
Palette, java.io.Serializable, javax.swing.table.TableModel

public class TrackPalette
extends javax.swing.table.AbstractTableModel
implements Palette

This palette enables scenery developer to choose one of variety of tracks. The palette imeplements table model, so buttons are in column and rows.

See Also:
Serialized Form

Field Summary
 
Fields inherited from class javax.swing.table.AbstractTableModel
listenerList
 
Constructor Summary
TrackPalette(Jet jet)
           
 
Method Summary
protected  javax.swing.JToggleButton createStandaloneButton(java.lang.String text, java.lang.String tt)
           
protected  javax.swing.JToggleButton getButton(int x, int y)
           
 java.lang.Class getColumnClass(int col)
           
 int getColumnCount()
           
 int getColumnWidth()
          Zwraca szerokość pojedynczej kolumny dla tabeli.
 int getRowCount()
           
 int getRowHeight()
          Zwraca wysokość pojedynczego wiersza tabeli.
 java.lang.Object getValueAt(int row, int col)
           
 boolean isCellEditable(int row, int col)
           
protected  void putButton(int x, int y, javax.swing.JToggleButton button)
           
 
Methods inherited from class javax.swing.table.AbstractTableModel
addTableModelListener, findColumn, fireTableCellUpdated, fireTableChanged, fireTableDataChanged, fireTableRowsDeleted, fireTableRowsInserted, fireTableRowsUpdated, fireTableStructureChanged, getColumnName, getListeners, getTableModelListeners, removeTableModelListener, setValueAt
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface javax.swing.table.TableModel
addTableModelListener, getColumnName, removeTableModelListener, setValueAt
 

Constructor Detail

TrackPalette

public TrackPalette(Jet jet)
Method Detail

putButton

protected void putButton(int x,
                         int y,
                         javax.swing.JToggleButton button)

getButton

protected javax.swing.JToggleButton getButton(int x,
                                              int y)

getColumnCount

public int getColumnCount()
Specified by:
getColumnCount in interface javax.swing.table.TableModel

getRowCount

public int getRowCount()
Specified by:
getRowCount in interface javax.swing.table.TableModel

getValueAt

public java.lang.Object getValueAt(int row,
                                   int col)
Specified by:
getValueAt in interface javax.swing.table.TableModel

isCellEditable

public boolean isCellEditable(int row,
                              int col)
Specified by:
isCellEditable in interface javax.swing.table.TableModel
Overrides:
isCellEditable in class javax.swing.table.AbstractTableModel

getColumnClass

public java.lang.Class getColumnClass(int col)
Specified by:
getColumnClass in interface javax.swing.table.TableModel
Overrides:
getColumnClass in class javax.swing.table.AbstractTableModel

getColumnWidth

public int getColumnWidth()
Zwraca szerokość pojedynczej kolumny dla tabeli.

Specified by:
getColumnWidth in interface Palette
Returns:
Column width;

getRowHeight

public int getRowHeight()
Zwraca wysokość pojedynczego wiersza tabeli.

Specified by:
getRowHeight in interface Palette
Returns:
Row height.

createStandaloneButton

protected javax.swing.JToggleButton createStandaloneButton(java.lang.String text,
                                                           java.lang.String tt)

jET
1.0alpha4