Integrated: 8231372: JFXPanel fails to render if setScene called on Swing thread
kcr at openjdk.java.net
Tue Dec 8 15:22:12 UTC 2020
On Fri, 4 Dec 2020 02:07:37 GMT, Kevin Rushforth <kcr at openjdk.org> wrote:
> This fix was originally proposed by @mruzicka in PR #16 which was closed several months ago without being integrated. At the time we didn't have a test case that was failing.
> While evaluating a bug that I filed, [JDK-8235843](https://bugs.openjdk.java.net/browse/JDK-8235843), I discovered that that bug was a duplicate of this one. The original proposed fix is correct, although I modified it slightly to add a try / finally so that the secondary event loop will be terminated even if the setScene throws an exception. I also added a unit test. Since the bulk of the fix is from PR #16, I will add the contributor of that PR.
> NOTE to reviewers: I pushed two commits to my branch. The first is exactly the commit created for PR #16 and the second is the unit test along with the fix to the code to add try / finally. As always, they will be squashed into a single commit by Skara.
This pull request has now been integrated.
Author: Kevin Rushforth <kcr at openjdk.org>
Stats: 73 lines in 2 files changed: 66 ins; 1 del; 6 mod
8231372: JFXPanel fails to render if setScene called on Swing thread
Correctly terminate secondary event loop in JFXPanel::setScene
Co-authored-by: Michal Růžička <michal.ruza at gmail.com>
Reviewed-by: psadhukhan, arapte
More information about the openjfx-dev