Buggy code:
public class WBrowseListItemRenderer implements EventListener , ListitemRenderer , ListitemRendererExt { protected ArrayList < TableValueChangeListener > m_listeners = new ArrayList < TableValueChangeListener > ( ) ; private Set < ListItem > m_selectedItems = new HashSet < ListItem > ( ) ; private ArrayList < WTableColumn > m_tableColumns = new ArrayList < WTableColumn > ( ) ; private ArrayList < ListHeader > m_headers = new ArrayList < ListHeader > ( ) ; private Listbox listBox ; private EventListener cellListener ; private WBrowseListbox wbListBox ; private Object [ ] currentValues ; private Map < String , Map < Object , String > > lookupCache = null ; private static final int MAX_TEXT_LENGTH = 60 ; public WBrowseListItemRenderer ( WBrowseListbox p_wbListBox ) { } public WBrowseListItemRenderer ( List < ? extends String > columnNames , WBrowseListbox p_wbListBox ) { } private WTableColumn getColumn ( int columnIndex ) { } public void render ( Listitem item , Object data ) throws Exception { } private Component getDisplayComponent ( Object value , GridField gridField ) { } private Component createReadonlyCheckbox ( Object value ) { } private String getDisplayText ( Object value , GridField gridField ) { } private void setLabelText ( String text , Label label ) { } private void render ( ListItem item , Object data ) { } private Listcell getCellComponent ( WBrowseListbox table , Object field , int rowIndex , int columnIndex ) { } public void updateColumn ( int index , String header ) { } public void addColumn ( String header ) { } public int getNoColumns ( ) { } public void setRO ( int colIndex , Boolean readOnly ) { } private Component getListHeaderComponent ( Object headerValue , int headerIndex , Class < ? > classType ) { } public void setListHeader ( int index , ListHeader header ) { } protected Comparator < Object > getColumnComparator ( boolean ascending , final int columnIndex ) { } public static class ColumnComparator implements Comparator < Object > { private int columnIndex ; private MSort sort ; public ColumnComparator ( boolean ascending , int columnIndex ) { } public int compare ( Object o1 , Object o2 ) { } public int getColumnIndex ( ) { } } public void renderListHead ( ListHead head ) { } public void onEvent ( Event event ) throws Exception { int col = - 1 ; int row = - 1 ; Object value = null ; TableValueChangeEvent vcEvent = null ; WTableColumn tableColumn ; Component source = event . getTarget ( ) ; if ( isWithinListCell ( source ) ) { row = getRowPosition ( source ) ; col = getColumnPosition ( source ) ; tableColumn = m_tableColumns . get ( col ) ; if ( source instanceof Checkbox ) { value = Boolean . valueOf ( ( ( Checkbox ) ( source ) ) . isChecked ( ) ) ; } else if ( source instanceof Decimalbox ) { value = ( ( Decimalbox ) ( source ) ) . getValue ( ) ; } else if ( source instanceof Datebox ) { value = ( ( Datebox ) ( source ) ) . getValue ( ) ; } else if ( source instanceof Textbox ) { value = ( ( Textbox ) ( source ) ) . getValue ( ) ; } if ( value != null ) { vcEvent = new TableValueChangeEvent ( source , tableColumn . getHeaderValue ( ) . toString ( ) , row , col , value , value ) ; fireTableValueChange ( vcEvent ) ; } <START_BUG> } else <END_BUG> if ( ( ( event . getTarget ( ) ) instanceof WBrowseListbox ) && ( ON_SELECT . equals ( event . getName ( ) ) ) ) { WBrowseListbox table = ( ( WBrowseListbox ) ( event . getTarget ( ) ) ) ; if ( table . isCheckmark ( ) ) { int cnt = table . getRowCount ( ) ; if ( ( cnt == 0 ) || ( ! ( ( table . getValueAt ( 0 , 0 ) ) instanceof IDColumn ) ) ) return ; tableColumn = m_tableColumns . get ( 0 ) ; for ( int i = 0 ; i < cnt ; i ++ ) { IDColumn idcolumn = ( ( IDColumn ) ( table . getValueAt ( i , 0 ) ) ) ; Listitem item = table . getItemAtIndex ( i ) ; value = item . isSelected ( ) ; Boolean old = idcolumn . isSelected ( ) ; if ( ! ( old . equals ( value ) ) ) { vcEvent = new TableValueChangeEvent ( source , tableColumn . getHeaderValue ( ) . toString ( ) , i , 0 , old , value ) ; fireTableValueChange ( vcEvent ) ; } } } } return ; } private boolean isWithinListCell ( Component source ) { } protected int getRowPosition ( Component source ) { } private Listcell findListcell ( Component source ) { } protected int getColumnPosition ( Component source ) { } public void clearColumns ( ) { } public void clearSelection ( ) { } public void addTableValueChangeListener ( TableValueChangeListener listener ) { } public void removeTableValueChangeListener ( TableValueChangeListener listener ) { } private void fireTableValueChange ( TableValueChangeEvent event ) { } public int getControls ( ) { } public Listcell newListcell ( Listitem item ) { } public Listitem newListitem ( Listbox listbox ) { } public void setColumnHeader ( int index , String header ) { } public void setColumnClass ( int index , Class < ? > classType ) { } class CellListener implements EventListener { public CellListener ( ) { } public void onEvent ( Event event ) throws Exception { if ( ( ( listBox ) != null ) && ( ON_DOUBLE_CLICK . equals ( event . getName ( ) ) ) ) { Event evt = new Event ( Events . ON_DOUBLE_CLICK , listBox ) ;

Fix:
}