Author: bobtarling
Date: 2010-02-15 14:03:32-0800
New Revision: 18021

Modified:
   trunk/src/argouml-app/src/org/argouml/ui/ProjectBrowser.java

Log:
Logging only to get some clues as to activity when closing on Mac

Modified: trunk/src/argouml-app/src/org/argouml/ui/ProjectBrowser.java
Url: 
http://argouml.tigris.org/source/browse/argouml/trunk/src/argouml-app/src/org/argouml/ui/ProjectBrowser.java?view=diff&pathrev=18021&r1=18020&r2=18021
==============================================================================
--- trunk/src/argouml-app/src/org/argouml/ui/ProjectBrowser.java        
(original)
+++ trunk/src/argouml-app/src/org/argouml/ui/ProjectBrowser.java        
2010-02-15 14:03:32-0800
@@ -975,7 +975,9 @@
      * save and exit, exit without saving or cancel the exit operation.
      */
     public void tryExit() {
+        LOG.info("Trying to exit the application");
         if (saveAction != null && saveAction.isEnabled()) {
+            LOG.info("A save is needed - prompting the user");
             Project p = ProjectManager.getManager().getCurrentProject();
 
             String t =
@@ -990,15 +992,18 @@
                 // The trySave method results in the save taking place in 
another thread.
                 // If that completes without error the ProjectBrowser.exit() 
method will
                 // be called which will actually exist the system.
+                LOG.info("The user chose to exit and save");
                 trySave(ProjectManager.getManager().getCurrentProject() != null
                         && ProjectManager.getManager().getCurrentProject()
                                 .getURI() != null,
                                 false, true);
                 return;
             } else if (response == JOptionPane.CANCEL_OPTION) {
+                LOG.info("The user cancelled the save dialog");
                 return;
             }
         }
+        LOG.info("We will now exit");
         exit();
     }
     
@@ -1033,6 +1038,7 @@
          * @see 
java.awt.event.WindowListener#windowClosing(java.awt.event.WindowEvent)
          */
         public void windowClosing(WindowEvent e) {
+            LOG.info("Detected attempt to close application - checking if save 
needed");
             tryExit();
         }
     } /* end class WindowCloser */

------------------------------------------------------
http://argouml.tigris.org/ds/viewMessage.do?dsForumId=5905&dsMessageId=2447903

To unsubscribe from this discussion, e-mail: 
[commits-unsubscr...@argouml.tigris.org].

Reply via email to