You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@pivot.apache.org by gb...@apache.org on 2010/04/17 19:38:02 UTC

svn commit: r935214 - /pivot/trunk/wtk/src/org/apache/pivot/wtk/DesktopApplicationContext.java

Author: gbrown
Date: Sat Apr 17 17:38:02 2010
New Revision: 935214

URL: http://svn.apache.org/viewvc?rev=935214&view=rev
Log:
Additional update for PIVOT-460.

Modified:
    pivot/trunk/wtk/src/org/apache/pivot/wtk/DesktopApplicationContext.java

Modified: pivot/trunk/wtk/src/org/apache/pivot/wtk/DesktopApplicationContext.java
URL: http://svn.apache.org/viewvc/pivot/trunk/wtk/src/org/apache/pivot/wtk/DesktopApplicationContext.java?rev=935214&r1=935213&r2=935214&view=diff
==============================================================================
--- pivot/trunk/wtk/src/org/apache/pivot/wtk/DesktopApplicationContext.java (original)
+++ pivot/trunk/wtk/src/org/apache/pivot/wtk/DesktopApplicationContext.java Sat Apr 17 17:38:02 2010
@@ -287,25 +287,23 @@ public final class DesktopApplicationCon
         }
 
         if (!cancelShutdown) {
-            if (windowedHostFrame.getExtendedState() == 0) {
-                try {
-                    Preferences preferences = Preferences.userNodeForPackage(DesktopApplicationContext.class);
-                    preferences = preferences.node(applicationClassName);
+            try {
+                Preferences preferences = Preferences.userNodeForPackage(DesktopApplicationContext.class);
+                preferences = preferences.node(applicationClassName);
 
-                    preferences.putInt(X_ARGUMENT, windowedHostFrame.getX());
-                    preferences.putInt(Y_ARGUMENT, windowedHostFrame.getY());
-                    preferences.putInt(WIDTH_ARGUMENT, windowedHostFrame.getWidth());
-                    preferences.putInt(HEIGHT_ARGUMENT, windowedHostFrame.getHeight());
-
-                    int state = (windowedHostFrame.getExtendedState() & java.awt.Frame.MAXIMIZED_BOTH);
-                    preferences.putBoolean(MAXIMIZED_ARGUMENT, state == java.awt.Frame.MAXIMIZED_BOTH);
-
-                    preferences.flush();
-                } catch (SecurityException exception) {
-                    // No-op
-                } catch (BackingStoreException exception) {
-                    // No-op
-                }
+                preferences.putInt(X_ARGUMENT, windowedHostFrame.getX());
+                preferences.putInt(Y_ARGUMENT, windowedHostFrame.getY());
+                preferences.putInt(WIDTH_ARGUMENT, windowedHostFrame.getWidth());
+                preferences.putInt(HEIGHT_ARGUMENT, windowedHostFrame.getHeight());
+
+                int state = (windowedHostFrame.getExtendedState() & java.awt.Frame.MAXIMIZED_BOTH);
+                preferences.putBoolean(MAXIMIZED_ARGUMENT, state > 0);
+
+                preferences.flush();
+            } catch (SecurityException exception) {
+                // No-op
+            } catch (BackingStoreException exception) {
+                // No-op
             }
 
             windowedHostFrame.dispose();