org.eclipse.xtext.ui.search
Class XtextEObjectSearchDialog
java.lang.Object
org.eclipse.jface.window.Window
org.eclipse.jface.dialogs.Dialog
org.eclipse.jface.dialogs.TrayDialog
org.eclipse.ui.dialogs.SelectionDialog
org.eclipse.ui.dialogs.ListDialog
org.eclipse.xtext.ui.search.XtextEObjectSearchDialog
- All Implemented Interfaces:
- org.eclipse.jface.window.IShellProvider
public class XtextEObjectSearchDialog
- extends org.eclipse.ui.dialogs.ListDialog
- Author:
- Jan Koehnlein - Initial contribution and API, Knut Wannheden
Nested classes/interfaces inherited from class org.eclipse.jface.window.Window |
org.eclipse.jface.window.Window.IExceptionHandler |
Fields inherited from class org.eclipse.jface.dialogs.Dialog |
blockedHandler, buttonBar, DIALOG_DEFAULT_BOUNDS, DIALOG_PERSISTLOCATION, DIALOG_PERSISTSIZE, dialogArea, DLG_IMG_ERROR, DLG_IMG_HELP, DLG_IMG_INFO, DLG_IMG_MESSAGE_ERROR, DLG_IMG_MESSAGE_INFO, DLG_IMG_MESSAGE_WARNING, DLG_IMG_QUESTION, DLG_IMG_WARNING, ELLIPSIS |
Fields inherited from class org.eclipse.jface.window.Window |
CANCEL, OK |
Methods inherited from class org.eclipse.ui.dialogs.ListDialog |
createButtonsForButtonBar, getHeightInChars, getTableViewer, getWidthInChars, okPressed, setAddCancelButton, setContentProvider, setHeightInChars, setInput, setLabelProvider, setWidthInChars |
Methods inherited from class org.eclipse.ui.dialogs.SelectionDialog |
configureShell, getDialogBoundsSettings, getDialogBoundsStrategy, getInitialElementSelections, getInitialSelections, getMessage, getOkButton, getResult, isResizable, setDialogBoundsSettings, setInitialElementSelections, setInitialSelections, setMessage, setResult, setSelectionResult, setTitle |
Methods inherited from class org.eclipse.jface.dialogs.TrayDialog |
close, closeTray, createButtonBar, createHelpControl, getLayout, getTray, isDialogHelpAvailable, isHelpAvailable, openTray, setDialogHelpAvailable, setHelpAvailable |
Methods inherited from class org.eclipse.jface.dialogs.Dialog |
applyDialogFont, buttonPressed, cancelPressed, convertHeightInCharsToPixels, convertHeightInCharsToPixels, convertHorizontalDLUsToPixels, convertHorizontalDLUsToPixels, convertVerticalDLUsToPixels, convertVerticalDLUsToPixels, convertWidthInCharsToPixels, convertWidthInCharsToPixels, create, createButton, createContents, dialogFontIsDefault, getBlockedHandler, getButton, getButtonBar, getCancelButton, getDialogArea, getImage, getInitialLocation, getInitialSize, getOKButton, initializeBounds, initializeDialogUnits, setBlockedHandler, setButtonLayoutData, setButtonLayoutFormData, shortenText |
Methods inherited from class org.eclipse.jface.window.Window |
canHandleShellCloseEvent, constrainShellSize, createShell, getConstrainedShellBounds, getContents, getDefaultImage, getDefaultImages, getDefaultOrientation, getParentShell, getReturnCode, getShell, getShellListener, getShellStyle, getWindowManager, handleFontChange, handleShellCloseEvent, setBlockOnOpen, setDefaultImage, setDefaultImages, setDefaultModalParent, setDefaultOrientation, setExceptionHandler, setParentShell, setReturnCode, setShellStyle, setWindowManager |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
searchControl
protected org.eclipse.swt.widgets.Text searchControl
typeSearchControl
protected org.eclipse.swt.widgets.Text typeSearchControl
- Since:
- 2.0
XtextEObjectSearchDialog
public XtextEObjectSearchDialog(org.eclipse.swt.widgets.Shell parent,
IXtextEObjectSearch searchEngine,
org.eclipse.jface.viewers.ILabelProvider labelProvider)
XtextEObjectSearchDialog
public XtextEObjectSearchDialog(org.eclipse.swt.widgets.Shell parent,
IXtextEObjectSearch searchEngine,
org.eclipse.jface.viewers.ILabelProvider labelProvider,
boolean enableStyledLabels)
getSearchEngine
protected IXtextEObjectSearch getSearchEngine()
- Since:
- 2.0
setInitialPattern
public void setInitialPattern(java.lang.String text)
- Since:
- 2.0
getInitialPattern
protected java.lang.String getInitialPattern()
- Since:
- 2.0
open
public int open()
- Overrides:
open
in class org.eclipse.jface.window.Window
getTableStyle
protected int getTableStyle()
- Overrides:
getTableStyle
in class org.eclipse.ui.dialogs.ListDialog
createDialogArea
protected org.eclipse.swt.widgets.Control createDialogArea(org.eclipse.swt.widgets.Composite container)
- Overrides:
createDialogArea
in class org.eclipse.ui.dialogs.ListDialog
createMessageArea
protected org.eclipse.swt.widgets.Label createMessageArea(org.eclipse.swt.widgets.Composite composite)
- Overrides:
createMessageArea
in class org.eclipse.ui.dialogs.SelectionDialog
applyFilter
protected void applyFilter()
- Called when the dialog is initially opened and whenever the input text changes. Applies the search filter as
specified by
searchControl
and typeSearchControl
using getSearchEngine()
and updates
the result using startSizeCalculation(Iterable)
.
- Since:
- 2.0
updateMatches
public void updateMatches(java.util.Collection<IEObjectDescription> matches,
boolean isFinished)
startSizeCalculation
protected void startSizeCalculation(java.lang.Iterable<IEObjectDescription> matches)
- Called by
applyFilter()
and is responsible for calling updateMatches(Collection, boolean)
with
an appropriately sorted list of matches.
- Since:
- 2.0