Class Dialogs


  • public class Dialogs
    extends java.lang.Object
    Factory class for common dialogs.
    • Constructor Summary

      Constructors 
      Constructor Description
      Dialogs()  
    • Method Summary

      All Methods Static Methods Concrete Methods 
      Modifier and Type Method Description
      static boolean confirmDiscardChanges​(java.awt.Container owner)
      Display a dialog to confirm closing a window with unsaved data.
      static boolean confirmDiscardChanges​(java.util.ResourceBundle bundle, java.awt.Container owner)
      Display a dialog to confirm closing a window with unsaved data.
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Constructor Detail

      • Dialogs

        public Dialogs()
    • Method Detail

      • confirmDiscardChanges

        public static boolean confirmDiscardChanges​(java.awt.Container owner)
        Display a dialog to confirm closing a window with unsaved data.
        Parameters:
        owner - the owner for the dialog (e.g. the window being closed)
        Returns:
        true if the user chose to discard unsaved data
      • confirmDiscardChanges

        public static boolean confirmDiscardChanges​(java.util.ResourceBundle bundle,
                                                    java.awt.Container owner)
        Display a dialog to confirm closing a window with unsaved data.
        Parameters:
        bundle - provides title and button text
        owner - the owner for the dialog (e.g. the window being closed)
        Returns:
        true if the user chose to discard unsaved data