public TablePanel()

in src/org/pushingpixels/lightbeam/panels/TablePanel.java [248:290]


	public TablePanel(ComponentsFactory factory) {
		this.table = factory.createTable(new MyTableModel(1000));
		this.table.setDefaultRenderer(Color.class, new MyColorTableRenderer());
		this.table.setDefaultRenderer(Float.class, new MyFloatTableRenderer());

		// this.table.setDefaultRenderer(Object.class, new NullTableRenderer());
		// this.table.setDefaultRenderer(Icon.class, new NullTableRenderer());
		// this.table.setDefaultRenderer(ImageIcon.class, new NullTableRenderer(
		// ));
		// this.table.setDefaultRenderer(Number.class, new NullTableRenderer());
		// this.table.setDefaultRenderer(Float.class, new NullTableRenderer());
		// this.table.setDefaultRenderer(Double.class, new NullTableRenderer());
		// this.table.setDefaultRenderer(Date.class, new NullTableRenderer());
		// this.table.setDefaultRenderer(Boolean.class, new NullTableRenderer())
		// ;

		JScrollPane tableScrollpane = new JScrollPane(this.table);
		tableScrollpane.setName("Main table in table panel");

		JComboBox combo = new JComboBox(new Object[] { "aa", "bb", "cc" });
		combo.setBorder(null);
		this.table.getColumnModel().getColumn(1).setCellEditor(
				new DefaultCellEditor(combo));

		this.table
				.setSelectionMode(ListSelectionModel.MULTIPLE_INTERVAL_SELECTION);
		// We allow row selection as the default
		this.table.setCellSelectionEnabled(true);
		this.table.setRowSelectionAllowed(true);
		this.table.setColumnSelectionAllowed(false);

		this.table.setShowGrid(false);
		this.table.setDragEnabled(false);
		this.table
				.setTableHeader(new JTableHeader(this.table.getColumnModel()));

		this.setLayout(new BorderLayout());
		this.add(tableScrollpane, BorderLayout.CENTER);

		final JLabel instructional = new JLabel("Every odd row is editable");
		this.add(instructional, BorderLayout.NORTH);

	}