|
org.eclipse.rse.ui.open
Class SystemQuickOpenDialog
java.lang.Object
org.eclipse.jface.window.Window
org.eclipse.jface.dialogs.Dialog
org.eclipse.rse.ui.open.SystemQuickOpenDialog
-
All Implemented Interfaces:
-
IRunnableContext,
IShellProvider,
ISystemQuickOpenPageContainer
-
public class SystemQuickOpenDialog
- extends
Dialog
- implements
ISystemQuickOpenPageContainer,
IRunnableContext
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.jface.dialogs.
Dialog
|
applyDialogFont,
buttonPressed,
close,
convertHeightInCharsToPixels,
convertHeightInCharsToPixels,
convertHorizontalDLUsToPixels,
convertHorizontalDLUsToPixels,
convertVerticalDLUsToPixels,
convertVerticalDLUsToPixels,
convertWidthInCharsToPixels,
convertWidthInCharsToPixels,
createButton,
createButtonBar,
createButtonsForButtonBar,
createContents,
dialogFontIsDefault,
getBlockedHandler,
getButton,
getButtonBar,
getCancelButton,
getDialogArea,
getDialogBoundsSettings,
getDialogBoundsStrategy,
getImage,
getInitialLocation,
getInitialSize,
getOKButton,
initializeBounds,
initializeDialogUnits,
isResizable,
setBlockedHandler,
setButtonLayoutData,
setButtonLayoutFormData,
shortenText
|
Methods inherited from class org.eclipse.jface.window.
Window
|
canHandleShellCloseEvent,
constrainShellSize,
createShell,
getConstrainedShellBounds,
getContents,
getDefaultImage,
getDefaultImages,
getDefaultOrientation,
getLayout,
getParentShell,
getReturnCode,
getShell,
getShellListener,
getShellStyle,
getWindowManager,
handleFontChange,
open,
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
|
SystemQuickOpenDialog
public SystemQuickOpenDialog(
Shell shell,
ISelection selection,
String pageId)
- The constructor for the quick open dialog.
-
Parameters:
-
shell - the shell. -
selection - the current selection. -
pageId - the initial page id.
create
public void create()
-
-
Overrides:
-
create
in class
Dialog
-
-
See Also:
-
Window.create()
configureShell
protected void configureShell(
Shell shell)
-
-
Overrides:
-
configureShell
in class
Window
-
-
See Also:
-
Window.configureShell(org.eclipse.swt.widgets.Shell)
createDialogArea
protected
Control createDialogArea(
Composite parent)
- Creates a page area, a progress monitor and a separator.
-
-
Overrides:
-
createDialogArea
in class
Dialog
-
-
See Also:
-
Dialog.createDialogArea(org.eclipse.swt.widgets.Composite)
createPageArea
protected
Control createPageArea(
Composite parent)
- Creates the page area.
-
-
-
Parameters:
-
parent - the parent composite.
-
Returns:
- the page area control.
cancelPressed
protected void cancelPressed()
- Calls the super class method if there are no running operations.
-
-
Overrides:
-
cancelPressed
in class
Dialog
-
-
See Also:
-
Dialog.cancelPressed()
okPressed
protected void okPressed()
- Calls
performAction . If the result of calling this method is true
-
-
Overrides:
-
okPressed
in class
Dialog
-
-
See Also:
-
Dialog.okPressed()
performAction
protected boolean performAction()
- Returns whether ok to close. Asks the current page, if any, whether it is ok to close.
-
-
-
Returns:
-
true if the dialog can be closed, false otherwise.
getRunnableContext
public
IRunnableContext getRunnableContext()
-
Description copied from interface:
ISystemQuickOpenPageContainer
- Returns the context for the search operation.
This context allows progress to be shown inside the search dialog.
-
-
Specified by:
-
getRunnableContext
in interface
ISystemQuickOpenPageContainer
-
-
Returns:
- the
IRunnableContext for the search operation -
See Also:
-
ISystemQuickOpenPageContainer.getRunnableContext()
getSelection
public
ISelection getSelection()
-
Description copied from interface:
ISystemQuickOpenPageContainer
- Returns the selection with which this container was opened.
-
-
Specified by:
-
getSelection
in interface
ISystemQuickOpenPageContainer
-
-
Returns:
- the selection passed to this container when it was opened
-
See Also:
-
ISystemQuickOpenPageContainer.getSelection()
setPerformActionEnabled
public void setPerformActionEnabled(boolean state)
-
Description copied from interface:
ISystemQuickOpenPageContainer
- Sets the enable state of the perform action button
of this container.
-
-
Specified by:
-
setPerformActionEnabled
in interface
ISystemQuickOpenPageContainer
-
-
Parameters:
-
state - true to enable the button which performs the action -
See Also:
-
ISystemQuickOpenPageContainer.setPerformActionEnabled(boolean)
run
public void run(boolean fork,
boolean cancelable,
IRunnableWithProgress runnable)
throws
InvocationTargetException,
InterruptedException
-
-
Specified by:
-
run
in interface
IRunnableContext
-
-
Throws:
-
InvocationTargetException
-
InterruptedException
-
See Also:
-
IRunnableContext.run(boolean, boolean, org.eclipse.jface.operation.IRunnableWithProgress)
getProgressMonitor
protected
IProgressMonitor getProgressMonitor()
- Returns the progress monitor. If the dialog doesn't
have a progress monitor,
null is returned.
-
-
aboutToStart
protected
HashMap aboutToStart(boolean enableCancelButton)
- About to start a long running operation tiggered through the dialog.
Shows the progress monitor and disables the dialog.
-
-
-
Parameters:
-
enableCancelButton - true if cancel button should be enabled, false otherwise.
-
Returns:
- the saved UI state.
-
See Also:
-
stopped(HashMap)
stopped
protected void stopped(
HashMap state)
- A long running operation triggered through the wizard
was stopped either by user input or by normal end.
-
-
-
Parameters:
-
savedState - The saveState returned by aboutToStart . -
See Also:
-
aboutToStart(boolean)
restoreEnableState
protected void restoreEnableState(
Control w,
HashMap h,
String key)
- Restores the enable state of a control.
-
-
-
Parameters:
-
w - the control whose state needs to be restored. -
h - the hashmap containing the enable state of the control. -
key - the key to use to retrieve the enable state.
handleShellCloseEvent
protected void handleShellCloseEvent()
- Checks to see if there are any long running operations. If there are, a dialog is shown
-
-
Overrides:
-
handleShellCloseEvent
in class
Window
-
-
See Also:
-
Window.handleShellCloseEvent()
okToClose
public boolean okToClose()
- Checks if any operations are running. If so, shows a message dialog alerting the user, and returns
false
indicating the dialog should not be closed.
-
-
-
Returns:
-
true if it is ok to close the dialog, false otherwise.
Copyright (c) IBM Corporation and others 2000, 2008. All Rights Reserved.
|
|