Package PamView.dialog.warn
Class WarnOnceDialogFX
java.lang.Object
PamView.dialog.warn.WarnOnceDialogFX
A warning dialog in JavaFX with a "do not show again" dialog box.
- Author:
- Jamie Macaulay
-
Constructor Summary
ConstructorDescriptionWarnOnceDialogFX
(javafx.stage.Window parentStage, String title, String message, javafx.scene.control.Alert.AlertType alertType, String helpPoint, Throwable error) Constructor the warn once dialog.WarnOnceDialogFX
(javafx.stage.Window parentStage, String title, String message, javafx.scene.control.Alert.AlertType alertType, String helpPoint, Throwable error, String oktext, String canceltext) Constructor the warn once dialog. -
Method Summary
Modifier and TypeMethodDescriptionvoid
If the cancel button is pressed, check if this is a warning message.int
Get the answer from the warning dialog.boolean
void
Show the warning dialog.
-
Constructor Details
-
WarnOnceDialogFX
public WarnOnceDialogFX(javafx.stage.Window parentStage, String title, String message, javafx.scene.control.Alert.AlertType alertType, String helpPoint, Throwable error) Constructor the warn once dialog.- Parameters:
parentStage
- - the parent windowtitle
-message
-alertType
-helpPoint
-error
-
-
WarnOnceDialogFX
public WarnOnceDialogFX(javafx.stage.Window parentStage, String title, String message, javafx.scene.control.Alert.AlertType alertType, String helpPoint, Throwable error, String oktext, String canceltext) Constructor the warn once dialog.- Parameters:
parentStage
- - the parent windowtitle
- - the titlemessage
- - the messagealertType
- - the alerethelpPoint
-error
-oktext
-canceltext
-
-
-
Method Details
-
showDialog
public void showDialog()Show the warning dialog. -
cancelButtonPressed
public void cancelButtonPressed()If the cancel button is pressed, check if this is a warning message. If it is, then the cancel button is really the copy-to-clip board button. In that case, copy the message (and the error message, if available) to the clip board -
isShowAgain
public boolean isShowAgain() -
isShowThisSess
-
getAnswer
public int getAnswer()Get the answer from the warning dialog.- Returns:
- the awarning answer.
-