mirror of
https://github.com/ckaczor/azuredatastudio.git
synced 2026-02-16 18:46:40 -05:00
Change Cancel button label to Back for inner dialogs. (#24537)
This commit is contained in:
@@ -60,7 +60,7 @@ export class FileBrowserDialog extends Modal {
|
||||
@ILogService logService: ILogService,
|
||||
@ITextResourcePropertiesService textResourcePropertiesService: ITextResourcePropertiesService
|
||||
) {
|
||||
super(title, TelemetryKeys.ModalDialogName.FileBrowser, telemetryService, layoutService, clipboardService, themeService, logService, textResourcePropertiesService, contextKeyService, { dialogStyle: 'flyout', hasTitleIcon: false, hasBackButton: true, hasSpinner: true });
|
||||
super(title, TelemetryKeys.ModalDialogName.FileBrowser, telemetryService, layoutService, clipboardService, themeService, logService, textResourcePropertiesService, contextKeyService, { dialogStyle: 'flyout', hasTitleIcon: false, hasBackButton: false, hasSpinner: true });
|
||||
this._viewModel = this._instantiationService.createInstance(FileBrowserViewModel);
|
||||
this._viewModel.onAddFileTree(args => this.handleOnAddFileTree(args.rootNode, args.selectedNode, args.expandedNodes).catch(err => onUnexpectedError(err)));
|
||||
this._viewModel.onPathValidate(args => this.handleOnValidate(args.succeeded, args.message));
|
||||
@@ -77,13 +77,6 @@ export class FileBrowserDialog extends Modal {
|
||||
super.render();
|
||||
attachModalDialogStyler(this, this._themeService);
|
||||
|
||||
if (this.backButton) {
|
||||
|
||||
this.backButton.onDidClick(() => {
|
||||
this.close();
|
||||
});
|
||||
}
|
||||
|
||||
this._treeContainer = DOM.append(this._body, DOM.$('.tree-view'));
|
||||
|
||||
let tableContainer: HTMLElement = DOM.append(DOM.append(this._body, DOM.$('.option-section')), DOM.$('table.file-table-content'));
|
||||
@@ -106,7 +99,8 @@ export class FileBrowserDialog extends Modal {
|
||||
|
||||
this._okButton = this.addFooterButton(localize('fileBrowser.ok', "OK"), () => this.ok());
|
||||
this._okButton.enabled = false;
|
||||
this.addFooterButton(localize('fileBrowser.discard', "Discard"), () => this.close(), 'right', true);
|
||||
// Add a back button to the footer rather than use the built-in back button in the upper left of the dialog
|
||||
this.addFooterButton(localize('fileBrowser.back', "Back"), () => this.close(), 'right', true);
|
||||
|
||||
this.registerListeners();
|
||||
this.updateTheme();
|
||||
|
||||
Reference in New Issue
Block a user