Buggy code:
public class TableItem extends Item { Table parent ; Image [ ] images ; String [ ] strings ; Color [ ] cellBackground ; Color [ ] cellForeground ; Font [ ] cellFont ; int rowHandle ; boolean checked ; boolean grayed ; boolean cached ; Color background ; Color foreground ; Font font ; public TableItem ( Table parent , int style ) { } public TableItem ( Table parent , int style , int index ) { } TableItem ( Table parent , int style , int index , int handle ) { } double computeWidth ( int columnIndex ) { } protected void checkSubclass ( ) { } void columnAdded ( int index ) { } void columnRemoved ( int index ) { } void createHandle ( ) { } void clear ( ) { } void deregister ( ) { } void destroyWidget ( ) { } int findRowPresenter ( int current , int rowPresenterType ) { } int findPart ( int column , String partName ) { } public Color getBackground ( ) { } public Color getBackground ( int index ) { } public Rectangle getBounds ( ) { } public Rectangle getBounds ( int index ) { } public boolean getChecked ( ) { } public Font getFont ( ) { } public Font getFont ( int index ) { } public Color getForeground ( ) { } public Color getForeground ( int index ) { } public boolean getGrayed ( ) { } public Image getImage ( ) { } public Image getImage ( int index ) { } public Rectangle getImageBounds ( int index ) { } public int getImageIndent ( ) { } String getNameText ( ) { } public Table getParent ( ) { } public Rectangle getTextBounds ( int index ) { } public String getText ( ) { } public String getText ( int index ) { } Control getWidgetControl ( ) { } void register ( ) { } void releaseHandle ( ) { } void releaseWidget ( ) { } public void setBackground ( Color color ) { } public void setBackground ( int index , Color color ) { } public void setChecked ( boolean checked ) { } public void setFont ( Font font ) { } public void setFont ( int index , Font font ) { } public void setForeground ( Color color ) { } public void setForeground ( int index , Color color ) { } public void setGrayed ( boolean grayed ) { } public void setImage ( Image [ ] images ) { } public void setImage ( int index , Image image ) { } public void setImage ( Image image ) { } public void setImageIndent ( int indent ) { } public void setText ( String [ ] strings ) { } public void setText ( int index , String string ) { } public void setText ( String string ) { } void updateBackground ( int index ) { <START_BUG> int panel = findPart ( index , STACKPANEL_PART_NAME ) ; <END_BUG> if ( panel != 0 ) { if ( ( ( cellBackground ) != null ) && ( ( cellBackground [ index ] ) != null ) ) { int brush = OS . gcnew_SolidColorBrush ( cellBackground [ index ] . handle ) ; int current = OS . Panel_Background ( panel ) ; if ( ! ( OS . Object_Equals ( brush , current ) ) ) OS . Panel_Background ( panel , brush ) ; OS . GCHandle_Free ( current ) ; OS . GCHandle_Free ( brush ) ; } else { int property = OS . Panel_BackgroundProperty ( ) ; OS . DependencyObject_ClearValue ( panel , property ) ; OS . GCHandle_Free ( property ) ; } OS . GCHandle_Free ( panel ) ; } } void updateCheck ( ) { } void updateFont ( int index ) { } void updateForeground ( int index ) { } void updateImage ( int index ) { } void updateText ( int index ) { } }

Fix:
int panel = findPart ( index , DOCKPANEL_PART_NAME ) ;