title: Finding the restore bounds of a JFrame when it is in a maximized state
body: <p>When a JFrame is in a maximized state, the <code>getBounds</code> method returns bounds that match its current state. What I need is the "restore bounds" (that is, the size/location of what the window would be set to if a user clicked on "Restore Down" on a Windows platform) without actually setting it to a non-maximized state.</p>
  
  <p>The reason I ask is because I wish to save the bounds as a preference and then when the user reopens the application, set the window to the saved bounds (and then maximize it if that is what the last state was).</p>
  
  <p>I considered adding a listener for when a window is maximized but it seems to me that the listener is notified <em>after</em> its maximized and I'll need to be notified right <em>before</em> it is maximized.</p>