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

[plug-in] Fix 'onDidSelectItem' behavior for Quick Pick widget #4046

Closed
RomanNikitenko opened this issue Jan 14, 2019 · 0 comments
Closed

[plug-in] Fix 'onDidSelectItem' behavior for Quick Pick widget #4046

RomanNikitenko opened this issue Jan 14, 2019 · 0 comments
Assignees
Labels
bug bugs found in the application plug-in system issues related to the plug-in system Team: Che-Plugins issues related to the che-plugins team

Comments

@RomanNikitenko
Copy link
Contributor

I have the following code in my plugin:

const options = { placeHolder: 'Pick a machine to run the task' } as theia.QuickPickOptions;
            options.onDidSelectItem = (item => {
                // an item is selected
              });
theia.window.showQuickPick(items, options);

The problem is onDidSelectItem is invoked immediately after opening the Quick Pick widget.
At this step Quick Pick widget is in PREVIEW mode and first item gets selection by default.
So I think we should invoke onDidSelectItem when Quick Pick widget is in OPEN mode and user has ability to select some item.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug bugs found in the application plug-in system issues related to the plug-in system Team: Che-Plugins issues related to the che-plugins team
Projects
None yet
Development

No branches or pull requests

2 participants