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

Provide API for running nested events loops, similar to what modal dialogs do

    XMLWordPrintable

    Details

    • Subcomponent:
    • Resolved In Build:
      b112
    • CPU:
      generic
    • OS:
      generic
    • Verification:
      Verified

      Description

      One of the most valuable features of AWT/Swing modal dialogs is about blocking the current (calling) thread until the dialog is hidden/disposed. It's implemented differently for the calling thread be EDT or any other thread:

      1. On EDT, we start a nested message pump so the application doesn't get frozen.
      2. On any other thread, we just wait on AWT TreeLock.

      However, all the code behind this feature is package private, see Dialog.show() for details. Many external developers, as well as internal projects like Swing and Java Plugin, need this functionality: stop the current thread until a certain condition is met - both for EDT and non-EDT threads.

        Attachments

          Issue Links

            Activity

              People

              Assignee:
              art Artem Ananiev
              Reporter:
              art Artem Ananiev
              Votes:
              0 Vote for this issue
              Watchers:
              0 Start watching this issue

                Dates

                Created:
                Updated:
                Resolved:
                Imported:
                Indexed: