code: private void uninstallClientDecorations(JRootPane root) {
          uninstallBorder(root);
          uninstallWindowListeners(root);
          setTitlePane(root, null);
          uninstallLayout(root);
          // We have to revalidate/repaint root if the style is JRootPane.NONE
          // only. When we needs to call revalidate/repaint with other styles
          // the installClientDecorations is always called after this method
          // imediatly and it will cause the revalidate/repaint at the proper
          // time.
          int style = root.getWindowDecorationStyle();
  
          if (style == JRootPane.NONE) {
              root.repaint();
              root.revalidate();
          }
          // Reset the cursor, as we may have changed it to a resize cursor
          if (window != null) {
              window.setCursor(Cursor.getPredefinedCursor(Cursor.DEFAULT_CURSOR));
          }
  
          window = null;
      }
docs: Uninstalls any state that <code>installClientDecorations</code> has
  installed.
  
  <p>NOTE: This may be called if you haven't installed client decorations
  yet (ie before <code>installClientDecorations</code> has been invoked).
  </p>
  
  @param root the JRootPane.