Skip to content
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

Tree global selection listener not triggered when selecting TreeItems appended to the Tree root #832

Closed
vegegoku opened this issue Sep 3, 2023 · 0 comments
Assignees
Labels
bug Something isn't working
Milestone

Comments

@vegegoku
Copy link
Member

vegegoku commented Sep 3, 2023

Describe the bug
A selection listener added to the Tree root will not be triggered from TreeItem directly appended to the Tree.

To Reproduce

Tree.<String>create("Menu")
                            .setSearchable(true)
                            .addSelectionListener((source, selection) -> {
                                DomGlobal.console.info("Item selected");
                            })
                            .appendChild(TreeItem.create("Item 1"))
                            .appendChild(TreeItem.create("Item 2"))

The selection listener wont be triggered.

Expected behavior
The selection listener should be executed and print the log message.

@vegegoku vegegoku added the bug Something isn't working label Sep 3, 2023
@vegegoku vegegoku added this to the 2.0.0-RC2 milestone Sep 3, 2023
@vegegoku vegegoku self-assigned this Sep 3, 2023
vegegoku added a commit that referenced this issue Sep 3, 2023
@vegegoku vegegoku closed this as completed Sep 3, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
Status: Done
Development

No branches or pull requests

1 participant