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

ComboPopup: cancelHandler does not clear selected items, if any. #677

Open
brunano21 opened this issue Nov 29, 2016 · 2 comments
Open

ComboPopup: cancelHandler does not clear selected items, if any. #677

brunano21 opened this issue Nov 29, 2016 · 2 comments

Comments

@brunano21
Copy link
Contributor

brunano21 commented Nov 29, 2016

Valid only for Combobox's selectionMode = multiple
Whenever the user opens up the dropdown and selected some items, if he hits the Cancel button, the selection made is not cleared.

Potential fix would be to clear reset the combo.list.selectedItems to an empty array ([]) and then call combo._validateMultiple(true), so the widget state gets update accordingly.

This bug has been introduced by 785de84.

@wkeese
Copy link
Member

wkeese commented Dec 30, 2016

Note that I'm not adding the [bug] label because this regression wasn't (and will not be) in any official release. It broke after 0.8 and will be fixed before 0.9.

brunano21 added a commit to brunano21/deliteful that referenced this issue Jan 4, 2017
@wkeese wkeese closed this as completed in ad9a031 Jan 5, 2017
@wkeese
Copy link
Member

wkeese commented Nov 8, 2017

Actually, this fix isn't quite right. The "Cancel" button is clearing the selection, rather than restoring the selection to what it was before the dropdown was opened.

But this begs the question: Why have a cancel button at all? There's no button on desktop that lets you revert to the state before the dropdown was opened.

@wkeese wkeese reopened this Nov 8, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants