Buggy code:
public static final int CARET_BEGINNING = 1 ; public static final int FULL_SELECTION = 2 ; private Text pattern ; private TableViewer list ; private FilteredItemsSelectionDialog . DetailsContentViewer details ; private ILabelProvider detailsLabelProvider ; private FilteredItemsSelectionDialog . ItemsListLabelProvider itemsListLabelProvider ; private MenuManager menuManager ; private boolean multi ; private ToolBar toolBar ; private ToolItem toolItem ; private Label progressLabel ; private FilteredItemsSelectionDialog . ToggleStatusLineAction toggleStatusLineAction ; private FilteredItemsSelectionDialog . RemoveHistoryItemAction removeHistoryItemAction ; private ActionContributionItem removeHistoryActionContributionItem ; private IStatus status ; private FilteredItemsSelectionDialog . RefreshCacheJob refreshCacheJob ; private FilteredItemsSelectionDialog . RefreshProgressMessageJob refreshProgressMessageJob = new FilteredItemsSelectionDialog . RefreshProgressMessageJob ( ) ; private Object [ ] currentSelection ; private FilteredItemsSelectionDialog . ContentProvider contentProvider ; private FilteredItemsSelectionDialog . FilterHistoryJob filterHistoryJob ; private FilteredItemsSelectionDialog . FilterJob filterJob ; private FilteredItemsSelectionDialog . ItemsFilter filter ; private List lastCompletedResult ; private FilteredItemsSelectionDialog . ItemsFilter lastCompletedFilter ; private String initialPatternText ; private int selectionMode ; private FilteredItemsSelectionDialog . ItemsListSeparator itemsListSeparator ; private static final String EMPTY_STRING = "" ; private boolean refreshWithLastSelection = false ; private IHandlerActivation showViewHandler ; public FilteredItemsSelectionDialog ( Shell shell , boolean multi ) { } public FilteredItemsSelectionDialog ( Shell shell ) { } protected void addListFilter ( ViewerFilter filter ) { } public void setListLabelProvider ( ILabelProvider listLabelProvider ) { } private ILabelDecorator getListSelectionLabelDecorator ( ) { } public void setListSelectionLabelDecorator ( ILabelDecorator listSelectionLabelDecorator ) { } private FilteredItemsSelectionDialog . ItemsListLabelProvider getItemsListLabelProvider ( ) { } public void setDetailsLabelProvider ( ILabelProvider detailsLabelProvider ) { } private ILabelProvider getDetailsLabelProvider ( ) { } public void create ( ) { } protected void restoreDialog ( IDialogSettings settings ) { } public boolean close ( ) { } protected void storeDialog ( IDialogSettings settings ) { } private Label createHeader ( Composite parent ) { } private Label createLabels ( Composite parent ) { } private void createViewMenu ( Composite parent ) { } protected void fillViewMenu ( IMenuManager menuManager ) { } private void showViewMenu ( ) { } private void createPopupMenu ( ) { } protected abstract Control createExtendedContentArea ( Composite parent ) { } protected Control createDialogArea ( Composite parent ) { } protected void handleDoubleClick ( ) { } private void refreshDetails ( ) { } protected void handleSelected ( StructuredSelection selection ) { IStatus status = new Status ( IStatus . OK , PlatformUI . PLUGIN_ID , IStatus . OK , FilteredItemsSelectionDialog . EMPTY_STRING , null ) ; Object [ ] lastSelection = currentSelection ; currentSelection = selection . toArray ( ) ; if ( ( selection . size ( ) ) == 0 ) { status = new Status ( IStatus . ERROR , PlatformUI . PLUGIN_ID , IStatus . ERROR , FilteredItemsSelectionDialog . EMPTY_STRING , null ) ; if ( ( lastSelection != null ) && ( ( getListSelectionLabelDecorator ( ) ) != null ) ) { list . update ( lastSelection , null ) ; } currentSelection = null ; } else { status = new Status ( IStatus . ERROR , PlatformUI . PLUGIN_ID , IStatus . ERROR , FilteredItemsSelectionDialog . EMPTY_STRING , null ) ; List items = selection . toList ( ) ; Object item = null ; IStatus tempStatus = null ; for ( Iterator it = items . iterator ( ) ; it . hasNext ( ) ; ) { Object o = it . next ( ) ; if ( o instanceof FilteredItemsSelectionDialog . ItemsListSeparator ) { continue ; } item = o ; tempStatus = validateItem ( item ) ; if ( tempStatus . isOK ( ) ) { status = new Status ( IStatus . OK , PlatformUI . PLUGIN_ID , IStatus . OK , FilteredItemsSelectionDialog . EMPTY_STRING , null ) ; } else { status = tempStatus ; break ; } } if ( ( lastSelection != null ) && ( ( getListSelectionLabelDecorator ( ) ) != null ) ) { list . update ( lastSelection , null ) ; } if ( ( getListSelectionLabelDecorator ( ) ) != null ) { <START_BUG> list . update ( lastSelection , null ) ; <END_BUG> } } refreshDetails ( ) ; updateStatus ( status ) ; } protected IDialogSettings getDialogBoundsSettings ( ) { } protected abstract IDialogSettings getDialogSettings ( ) { } public void refresh ( ) { } public void updateProgressLabel ( ) { } public void reloadCache ( boolean checkDuplicates , IProgressMonitor monitor ) { } public void scheduleRefresh ( ) { } public void scheduleProgressMessageRefresh ( ) { } protected void computeResult ( ) { } protected void updateStatus ( IStatus status ) { } protected void okPressed ( ) { } public void setInitialPattern ( String text ) { } public void setInitialPattern ( String text , int selectionMode ) { } protected String getInitialPattern ( ) { } protected StructuredSelection getSelectedItems ( ) { } protected abstract IStatus validateItem ( Object item ) { } protected abstract FilteredItemsSelectionDialog . ItemsFilter createFilter ( ) { } protected void applyFilter ( ) { } protected abstract Comparator getItemsComparator ( ) { } protected abstract void fillContentProvider ( FilteredItemsSelectionDialog . AbstractContentProvider contentProvider , FilteredItemsSelectionDialog . ItemsFilter itemsFilter , IProgressMonitor progressMonitor ) throws CoreException { } private void removeSelectedItems ( List items ) { } protected Object removeHistoryItem ( Object item ) { } protected void accessedHistoryItem ( Object item ) { } private Comparator getHistoryComparator ( ) { } protected FilteredItemsSelectionDialog . SelectionHistory getSelectionHistory ( ) { } protected void setSelectionHistory ( FilteredItemsSelectionDialog . SelectionHistory selectionHistory ) { } public boolean isHistoryElement ( Object item ) { } public boolean isDuplicateElement ( Object item ) { } public void setSeparatorLabel ( String separatorLabel ) { } public abstract String getElementName ( Object item ) { } private class ToggleStatusLineAction extends Action { public ToggleStatusLineAction ( ) { } public void run ( ) { } } private class RefreshJob extends UIJob { public RefreshJob ( ) { } public IStatus runInUIThread ( IProgressMonitor monitor ) { } }

Fix:
list . update ( currentSelection , null ) ;