public Component getTableCellRendererComponent(JTable table,
Object value, boolean isSelected, boolean hasFocus,
int row, int column) {
IRadarPlaneObject tempValue = (IRadarPlaneObject) value;
if (tempValue != null) {
if(tempValue.equals(flightList.getSelectedPlane())){
this.setBackground(new Color(100, 120, 200, 130));
} else {
this.setBackground(tempValue.getPlaneColor(flightList.getFunction()));
}
planeControllers.setText(tempValue.getActiveController());
planeName.setText(tempValue.getFlightNumber());
planeAlt.setText(tempValue.getAltitude()+"");
planeSpeed.setText(tempValue.getSpeed()+"");
planeState.setText(tempValue.getPlaneState());
planeSquawk.setText(tempValue.getSquawk());
}
return this;
}