-
Notifications
You must be signed in to change notification settings - Fork 476
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
8198402: ToggleButton.setToggleGroup causes memory leak when button is removed via ToggleGroup.getToggles() #167
Conversation
Make the two ways of associating a ToggleButton with a ToggleGroup interact correctly.
Hi @jskov, welcome to this OpenJDK project and thanks for contributing! We do not recognize you as Contributor and need to ensure you have signed the Oracle Contributor Agreement (OCA). If you have not signed the OCA, please follow the instructions. Please fill in your GitHub username in the "Username" field of the application. Once you have signed the OCA, please let us know by writing If you already are an OpenJDK Author, Committer or Reviewer, please click here to open a new issue so that we can record that fact. Please use "Add GitHub user jskov" as summary for the issue. If you are contributing this work on behalf of your employer and your employer has signed the OCA, please let us know by writing |
/signed |
Thank you! Please allow for up to two weeks to process your OCA, although it is usually done within one to two business days. Also, please note that pull requests that are pending an OCA check will not usually be evaluated, so your patience is appreciated! |
Webrevs
|
/reviewers 2 |
@kevinrushforth |
@arapte can you also review? |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The fix looks correct to me. Have you run all tests to ensure no regressions?
I left a couple inline comments.
@@ -193,14 +193,17 @@ public String getName() { | |||
* being added to the new group. | |||
*/ | |||
private ObjectProperty<ToggleGroup> toggleGroup; | |||
@Override |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is unrelated to the fix. The changes in this file should be reverted.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
OK. They are gone.
Would this (keeping the changes very specific to the bug?) be worth mentioning in CONTRIBUTING.md?
That is, like the note about imports: do not fix warnings that are not directly related to the issue?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Good idea. I'll add that to my growing list of things to improve in CONTRIBUTING.md.
modules/javafx.controls/src/test/java/test/javafx/scene/control/ToggleButtonTest.java
Outdated
Show resolved
Hide resolved
modules/javafx.controls/src/main/java/javafx/scene/control/ToggleGroup.java
Outdated
Show resolved
Hide resolved
@kevinrushforth I tested by: I will try to get webkit working. |
I have failed getting web:tests to work. And that is with both a locally built webkit, and the one from javafx-web-15-ea+3-linux.jar So it seems I am unable to run web:tests task on my box (Fedora 31, FWIW). Any suggestions for how to resolve this?
|
Uh, the exception is (as the comment note suggests) from using a prebuilt webkit. |
Ah, well. Ended with the same VM crash when building webkit myself. So I am kinda stuck. Suggestions? |
I have found out that my :web:test failed because I did not have the So the changes in this PR pass all tests. |
Good to know. I'll finish my review today. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Fix and tests look good to me.
@jskov This change now passes all automated pre-integration checks. When the change also fulfills all project specific requirements, type
Since the source branch of this PR was last updated there have been 31 commits pushed to the
As there are no conflicts, your changes will automatically be rebased on top of these commits when integrating. If you prefer to avoid automatic rebasing, please merge As you are not a known OpenJDK Author, an existing Committer must agree to sponsor your change. Possible candidates are the reviewers of this PR (@kevinrushforth, @arapte) but any other Committer may sponsor as well. ➡️ To flag this PR as ready for integration with the above commit message, type |
/integrate |
/sponsor |
@kevinrushforth @jskov The following commits have been pushed to master since your change was applied:
Your commit was automatically rebased without conflicts. Pushed as commit 3130fc8. |
Make the two ways of associating a ToggleButton with a ToggleGroup interact correctly.
This fixes https://bugs.openjdk.java.net/browse/JDK-8198402
Progress
Issue
Reviewers
Download
$ git fetch https://git.openjdk.java.net/jfx pull/167/head:pull/167
$ git checkout pull/167