mirror of
https://github.com/ckaczor/azuredatastudio.git
synced 2026-02-16 18:46:40 -05:00
listen to command a and select the active element. (#8969)
* listen to command a and select the active element. * type fix
This commit is contained in:
@@ -68,6 +68,14 @@ export class TextCellComponent extends CellView implements OnInit, OnChanges {
|
|||||||
this._model.updateActiveCell(undefined);
|
this._model.updateActiveCell(undefined);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@HostListener('document:keydown.meta.a', ['$event'])
|
||||||
|
onkeydown(e) {
|
||||||
|
// use preventDefault() to avoid invoking the editor's select all
|
||||||
|
// select the active .
|
||||||
|
e.preventDefault();
|
||||||
|
document.execCommand('selectAll');
|
||||||
|
}
|
||||||
|
|
||||||
private _content: string | string[];
|
private _content: string | string[];
|
||||||
private _lastTrustedMode: boolean;
|
private _lastTrustedMode: boolean;
|
||||||
private isEditMode: boolean;
|
private isEditMode: boolean;
|
||||||
|
|||||||
Reference in New Issue
Block a user