*Greg, *// *Christopher*//, *Martijn*//, *Noel*//, *Niclas*//,*
    Sandro*//, *Todd:
    *
    can you guys please share what are best
    pivot ui state persistence patterns?

    DesktopApplicationContext painstakingly goes through

                    Preferences preferences =
    Preferences.userNodeForPackage(DesktopApplicationContext.class);
                    preferences = preferences.node(applicationClassName);

                    boolean maximized =
    (windowedHostFrame.getExtendedState()
                        & java.awt.Frame.MAXIMIZED_BOTH) ==
    java.awt.Frame.MAXIMIZED_BOTH;
                    if (!maximized) {
                        preferences.putInt(X_ARGUMENT,
    windowedHostFrame.getX());
                        preferences.putInt(Y_ARGUMENT,
    windowedHostFrame.getY());
                        preferences.putInt(WIDTH_ARGUMENT,
    windowedHostFrame.getWidth());
                        preferences.putInt(HEIGHT_ARGUMENT,
    windowedHostFrame.getHeight());
                    }

    and BXMLSerializer just gives up:
        @Override
        public void writeObject(Object object, OutputStream
    outputStream) throws IOException,
            SerializationException {
            throw new UnsupportedOperationException();
        }

    Thank you,

    Andrei

Reply via email to