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
dialogs - better massage options #172022
dialogs - better massage options #172022
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -500,13 +500,13 @@ export class EditSessionsContribution extends Disposable implements IWorkbenchCo | |
conflictingChanges.length > 1 ? | ||
localize('resume edit session warning many', 'Resuming your working changes from the cloud will overwrite the following {0} files. Do you want to proceed?', conflictingChanges.length) : | ||
localize('resume edit session warning 1', 'Resuming your working changes from the cloud will overwrite {0}. Do you want to proceed?', basename(conflictingChanges[0].uri)), | ||
[cancel, yes], | ||
[yes, cancel], | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. @joyceerhl please check, cancel buttons should be last in the dialog. |
||
{ | ||
detail: conflictingChanges.length > 1 ? getFileNamesMessage(conflictingChanges.map((c) => c.uri)) : undefined, | ||
cancelId: 0 | ||
cancelId: 1 | ||
}); | ||
|
||
if (result.choice === 0) { | ||
if (result.choice === 1) { | ||
return; | ||
} | ||
} | ||
|
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -104,8 +104,8 @@ export class PromptExtensionInstallFailureAction extends Action { | |
if (this.error.name === ExtensionManagementErrorCode.Unsupported) { | ||
const productName = isWeb ? localize('VS Code for Web', "{0} for the Web", this.productService.nameLong) : this.productService.nameLong; | ||
const message = localize('cannot be installed', "The '{0}' extension is not available in {1}. Click 'More Information' to learn more.", this.extension.displayName || this.extension.identifier.id, productName); | ||
const result = await this.dialogService.show(Severity.Info, message, [localize('close', "Close"), localize('more information', "More Information")], { cancelId: 0 }); | ||
if (result.choice === 1) { | ||
const result = await this.dialogService.show(Severity.Info, message, [localize('more information', "More Information"), localize('close', "Close")], { cancelId: 1 }); | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. @sandy081 fyi |
||
if (result.choice === 0) { | ||
this.openerService.open(isWeb ? URI.parse('https://aka.ms/vscode-web-extensions-guide') : URI.parse('https://aka.ms/vscode-remote')); | ||
} | ||
return; | ||
|
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -216,10 +216,10 @@ export class TaskQuickPick extends Disposable { | |
const changeSettingResult = await this._dialogService.show(Severity.Warning, | ||
nls.localize('TaskQuickPick.changeSettingDetails', | ||
"Task detection for {0} tasks causes files in any workspace you open to be run as code. Enabling {0} task detection is a user setting and will apply to any workspace you open. \n\n Do you want to enable {0} task detection for all workspaces?", selectedType), | ||
[noButton, yesButton], | ||
[yesButton, noButton], | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. @meganrogge fyi, I changed this so that cancelling the dialog would not execute the "Yes" button. |
||
{ cancelId: 1 } | ||
); | ||
if (changeSettingResult.choice === 1) { | ||
if (changeSettingResult.choice === 0) { | ||
await this._configurationService.updateValue(`${selectedType}.autoDetect`, 'on'); | ||
await new Promise<void>(resolve => setTimeout(() => resolve(), 100)); | ||
return this.show(nls.localize('TaskService.pickRunTask', 'Select the task to run'), undefined, selectedType); | ||
|
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.
@roblourens @connor4312 fyi, the cancel button was never assigned properly
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.
👍 thanks for the fix