Saros
Distributed Collaborative Editing and Distributed Party Programming
de.fu_berlin.inf.dpp.ui.util.DialogUtils Class Reference

List of all members.

Static Public Member Functions

static int openWindow (Window wd)
static int openErrorMessageDialog (Shell shell, String dialogTitle, String dialogMessage)
static void showErrorPopup (final Logger log, final String title, final String message, Exception e, IProgressMonitor monitor)
static int openInformationMessageDialog (Shell shell, String dialogTitle, String dialogMessage)
static int openWarningMessageDialog (Shell shell, String dialogTitle, String dialogMessage)
static boolean openQuestionMessageDialog (Shell shell, String dialogTitle, String dialogMessage)
static boolean popUpCustomQuestion (final String title, final String message, final String[] dialogButtonLabels, boolean failSilently)
static boolean popUpYesNoQuestion (final String title, final String message, boolean failSilently)
static void popUpFailureMessage (final String title, final String message, boolean failSilently)

Member Function Documentation

static int de.fu_berlin.inf.dpp.ui.util.DialogUtils.openErrorMessageDialog ( Shell  shell,
String  dialogTitle,
String  dialogMessage 
) [static]

Opens a MessageDialog of the type MessageDialog#ERROR and dispatches a call to forceActive (which gives a visual hint on the taskbar that the application wants focus).

Parameters:
shellthe parent shell
dialogTitlethe dialog title, or null if none
dialogMessagethe dialog message
Returns:
static int de.fu_berlin.inf.dpp.ui.util.DialogUtils.openInformationMessageDialog ( Shell  shell,
String  dialogTitle,
String  dialogMessage 
) [static]

Opens a MessageDialog of the type MessageDialog#INFORMATION and dispatches a call to forceActive (which gives a visual hint on the taskbar that the application wants focus).

Parameters:
shellthe parent shell
dialogTitlethe dialog title, or null if none
dialogMessagethe dialog message
Returns:
static boolean de.fu_berlin.inf.dpp.ui.util.DialogUtils.openQuestionMessageDialog ( Shell  shell,
String  dialogTitle,
String  dialogMessage 
) [static]

Opens a MessageDialog of the type MessageDialog#QUESTION and dispatches a call to forceActive (which gives a visual hint on the task-bar that the application wants focus).

Parameters:
shellthe parent shell
dialogTitlethe dialog title, or null if none
dialogMessagethe dialog message
Returns:
true if the user answered with YES
static int de.fu_berlin.inf.dpp.ui.util.DialogUtils.openWarningMessageDialog ( Shell  shell,
String  dialogTitle,
String  dialogMessage 
) [static]

Opens a MessageDialog of the type MessageDialog#WARNING and dispatches a call to forceActive (which gives a visual hint on the taskbar that the application wants focus).

Parameters:
shellthe parent shell
dialogTitlethe dialog title, or null if none
dialogMessagethe dialog message
Returns:
static int de.fu_berlin.inf.dpp.ui.util.DialogUtils.openWindow ( Window  wd) [static]

Calls open() on the given window and returns the result.

static boolean de.fu_berlin.inf.dpp.ui.util.DialogUtils.popUpCustomQuestion ( final String  title,
final String  message,
final String[]  dialogButtonLabels,
boolean  failSilently 
) [static]

Ask the User a given question. It pops up a QuestionDialog with given title and message. Additionally custom button labels are applicable.

Parameters:
titledialog title
messagedisplayed message
dialogButtonLabelscustom button labels
failSilentlydon`t open the dialog
Returns:
boolean indicating whether the user said Yes or No
static void de.fu_berlin.inf.dpp.ui.util.DialogUtils.popUpFailureMessage ( final String  title,
final String  message,
boolean  failSilently 
) [static]

Indicate the User that there was an error. It pops up an ErrorDialog with given title and message.

static boolean de.fu_berlin.inf.dpp.ui.util.DialogUtils.popUpYesNoQuestion ( final String  title,
final String  message,
boolean  failSilently 
) [static]

Ask the User a given question. It pops up a QuestionDialog with given title and message.

Returns:
boolean indicating whether the user said Yes or No
static void de.fu_berlin.inf.dpp.ui.util.DialogUtils.showErrorPopup ( final Logger  log,
final String  title,
final String  message,
Exception  e,
IProgressMonitor  monitor 
) [static]

Shows an error window and sets monitors subTask to message or exceptions message.

Parameters:
titleTitle of error window
messageMessage of error window
eException caused this error, may be null
monitorMay be null
 All Classes Namespaces Files Functions Variables Enumerations