com.intellij.openapi.ui
Class Messages.ChooseDialog

java.lang.Object
  extended by com.intellij.openapi.ui.DialogWrapper
      extended by com.intellij.openapi.ui.Messages.ChooseDialog
Enclosing class:
Messages

protected static class Messages.ChooseDialog
extends DialogWrapper


Field Summary
 
Fields inherited from class com.intellij.openapi.ui.DialogWrapper
CANCEL_EXIT_CODE, DEFAULT_ACTION, NEXT_USER_EXIT_CODE, OK_EXIT_CODE
 
Constructor Summary
Messages.ChooseDialog(java.awt.Component parent, java.lang.String message, java.lang.String title, javax.swing.Icon icon, java.lang.String[] values, java.lang.String initialValue)
           
Messages.ChooseDialog(Project project, java.lang.String message, java.lang.String title, javax.swing.Icon icon, java.lang.String[] values, java.lang.String initialValue)
           
Messages.ChooseDialog(Project project, java.lang.String message, java.lang.String title, javax.swing.Icon icon, java.lang.String[] values, java.lang.String initialValue, java.lang.String[] options, int defaultOption)
           
Messages.ChooseDialog(java.lang.String message, java.lang.String title, javax.swing.Icon icon, java.lang.String[] values, java.lang.String initialValue)
           
 
Method Summary
protected  javax.swing.Action[] createActions()
          This is factory method which creates action of dialog.
protected  javax.swing.JComponent createNorthPanel()
          Factory method.
protected  void doOKAction()
          This method is invoked by default implementation of "OK" action.
 javax.swing.JComboBox getComboBox()
           
 java.lang.String getInputString()
           
 javax.swing.JComponent getPreferredFocusedComponent()
           
 int getSelectedIndex()
           
 void setValidator(InputValidator validator)
           
 
Methods inherited from class com.intellij.openapi.ui.DialogWrapper
addKeyListener, addMouseListener, addMouseListener, centerRelativeToParent, clickDefaultButton, close, createContentPane, createContentPaneBorder, createDefaultActions, createJButtonForAction, createLeftSideActions, createSouthPanel, createTitlePane, dispose, doHelpAction, getCancelAction, getContentPane, getDimensionKey, getDimensionServiceKey, getExitCode, getHelpAction, getHorizontalStretch, getInitialLocation, getLocation, getOKAction, getOwner, getPreferredSize, getRootPane, getSize, getTitle, getVerticalStretch, getWindow, init, isModalProgress, isOK, isOKActionEnabled, isProgressDialog, isResizable, isShowing, isVisible, pack, repaint, setButtonsAlignment, setButtonsMargin, setCancelButtonIcon, setCancelButtonText, setCrossClosesWindow, setHorizontalStretch, setLocation, setLocation, setModal, setOKActionEnabled, setOKButtonIcon, setOKButtonText, setResizable, setSize, setTitle, setUndecorated, setVerticalStretch, shouldCloseOnCross, show, toBack, toFront, validate
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

Messages.ChooseDialog

public Messages.ChooseDialog(Project project,
                             java.lang.String message,
                             java.lang.String title,
                             javax.swing.Icon icon,
                             java.lang.String[] values,
                             java.lang.String initialValue,
                             java.lang.String[] options,
                             int defaultOption)

Messages.ChooseDialog

public Messages.ChooseDialog(Project project,
                             java.lang.String message,
                             java.lang.String title,
                             javax.swing.Icon icon,
                             java.lang.String[] values,
                             java.lang.String initialValue)

Messages.ChooseDialog

public Messages.ChooseDialog(java.awt.Component parent,
                             java.lang.String message,
                             java.lang.String title,
                             javax.swing.Icon icon,
                             java.lang.String[] values,
                             java.lang.String initialValue)

Messages.ChooseDialog

public Messages.ChooseDialog(java.lang.String message,
                             java.lang.String title,
                             javax.swing.Icon icon,
                             java.lang.String[] values,
                             java.lang.String initialValue)
Method Detail

createActions

protected javax.swing.Action[] createActions()
Description copied from class: DialogWrapper
This is factory method which creates action of dialog. Each action is represented by JButton which is created by createJButtonForAction(Action) method. These buttons are places into panel which is created by createButtonsPanel method. Therefore you have anough ways to customise the dialog by ovverriding of createActions(), createButtonsPanel() and createJButtonForAction(Action) methods. By default the createActions() method returns "OK" and "Cancel" action.

See Also:
DialogWrapper.createSouthPanel(), DialogWrapper.createJButtonForAction(javax.swing.Action)

createNorthPanel

protected javax.swing.JComponent createNorthPanel()
Description copied from class: DialogWrapper
Factory method. It creates the panel located at the north of the dialog's content pane. The implementation can return null value. In this case there will be no input panel.


doOKAction

protected void doOKAction()
Description copied from class: DialogWrapper
This method is invoked by default implementation of "OK" action. It just closes dialog with OK_EXIT_CODE. This is convenient place to override functionality of "OK" action. Note that the method does nothing if "OK" action isn't enabled.

Overrides:
doOKAction in class DialogWrapper

getPreferredFocusedComponent

public javax.swing.JComponent getPreferredFocusedComponent()
Overrides:
getPreferredFocusedComponent in class DialogWrapper
Returns:
component which should be focused when the dialog appears on the screen.

getInputString

public java.lang.String getInputString()

getSelectedIndex

public int getSelectedIndex()

getComboBox

public javax.swing.JComboBox getComboBox()

setValidator

public void setValidator(InputValidator validator)