protected void updateFocusCell(ViewerCell focusCell, ColumnViewerEditorActivationEvent event) { // Update the focus cell when we activated the editor with these 2 // events if (event.eventType == ColumnViewerEditorActivationEvent.PROGRAMMATIC || event.eventType == ColumnViewerEditorActivationEvent.TRAVERSAL) { List l = getViewer().getSelectionFromWidget(); if (!l.contains(focusCell.getElement())) { getViewer().setSelection( new StructuredSelection(focusCell.getElement()),true); } // Set the focus cell after the selection is updated because else // the cell is not scrolled into view if (focusCellManager != null) { focusCellManager.setFocusCell(focusCell); } } } }
@Override protected void updateFocusCell(ViewerCell focusCell, ColumnViewerEditorActivationEvent event) { // Update the focus cell when we activated the editor with these 2 // events if (event.eventType == ColumnViewerEditorActivationEvent.PROGRAMMATIC || event.eventType == ColumnViewerEditorActivationEvent.TRAVERSAL) { List l = getViewer().getSelectionFromWidget(); if (!l.contains(focusCell.getElement())) { getViewer().setSelection( new StructuredSelection(focusCell.getElement()), true); } // Set the focus cell after the selection is updated because else // the cell is not scrolled into view if (focusCellManager != null) { focusCellManager.setFocusCell(focusCell); } } } }
@Override protected void updateFocusCell(ViewerCell focusCell, ColumnViewerEditorActivationEvent event) { // Update the focus cell when we activated the editor with these 2 // events if (event.eventType == ColumnViewerEditorActivationEvent.PROGRAMMATIC || event.eventType == ColumnViewerEditorActivationEvent.TRAVERSAL) { List l = getViewer().getSelectionFromWidget(); if (!l.contains(focusCell.getElement())) { getViewer().setSelection( new StructuredSelection(focusCell.getElement()), true); } // Set the focus cell after the selection is updated because else // the cell is not scrolled into view if (focusCellManager != null) { focusCellManager.setFocusCell(focusCell); } } } }