Uploaded image for project: 'JDK'
  1. JDK
  2. JDK-7041387

Introduce new boolean system property java.awt.smartInvalidate

    XMLWordPrintable

Details

    • b143
    • generic, x86
    • generic, solaris_10, windows_xp, windows_vista, windows_7
    • Verified

    Description

      The fix for 6852592 made the invalidate() method stop on the nearest validate root when invalidating a component hierarchy. Initially we relied on the common pattern used in Swing applications: when they change a layout-related information, they (or the Swing library) should call the revalidate() method, e.g.:

      component.setSize(50, 50);
      component.revalidate();

      In this case the revalidate() method would dispatch a validate() call on the nearest validate root, thus validating the invalid part of the component hierarchy.

      However, it turns out that some Swing applications rely on the old behavior of the invalidate() method and simply call:

      frame.validate();

      instead of the revalidate() call. The frame is usually their top-level component (such as a JFrame or a JDialog). The fix for 6852592 made this call a no-op because the frame never gets invalidated.

      Attachments

        Issue Links

          Activity

            People

              anthony Anthony Petrov (Inactive)
              anthony Anthony Petrov (Inactive)
              Votes:
              0 Vote for this issue
              Watchers:
              8 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved:
                Imported:
                Indexed: