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

focus out possible again for debug configuration #12046

Merged
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 0 additions & 1 deletion packages/debug/src/browser/debug-configuration-manager.ts
Original file line number Diff line number Diff line change
Expand Up @@ -388,7 +388,6 @@ export class DebugConfigurationManager {
}
const root = await this.quickPickService.show(items, {
placeholder: nls.localize('theia/debug/addConfigurationPlaceholder', 'Select workspace root to add configuration to'),
ignoreFocusOut: true
});
return root?.value;
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -103,7 +103,7 @@ export class DebugConfigurationSelect extends React.Component<DebugConfiguration
if (!value) {
return false;
} else if (value === DebugConfigurationSelect.ADD_CONFIGURATION) {
this.manager.addConfiguration();
setTimeout(() => this.manager.addConfiguration());
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I agree that this is a bit 'hacky' and I tested animationFrame().then(() => this.manager.addConfiguration()); which also seems to work but I don't see any additional benefit from using that instead. I also did not find any alternative solution that solves that issue but I also don't think there are going to be any side effects from this, so in my opinion this could be merged.

The only thing that would be nice is a short comment explaining why this particular call needs to be handled differently though in theory that could be derived from the Git history. @tsmaeder How do you usually handle these situations with regard to documentation?

} else if (value.startsWith(DebugConfigurationSelect.PICK)) {
const providerType = this.parsePickValue(value);
this.selectDynamicConfigFromQuickPick(providerType);
Expand Down