mirror of
https://github.com/ckaczor/azuredatastudio.git
synced 2026-01-19 17:22:48 -05:00
Added code to enable disable split cell icon (#17331)
* Added code to enable diable split cell icon * adding back the deleted code * refactored * minimized lines * simplified code * minor change * minor change * Addressed PR * Addressed PR * removing unused enum value
This commit is contained in:
@@ -58,6 +58,7 @@ export class CellModel extends Disposable implements ICellModel {
|
||||
private _onTableUpdated = new Emitter<ITableUpdatedEvent>();
|
||||
private _onCellModeChanged = new Emitter<boolean>();
|
||||
private _onExecutionStateChanged = new Emitter<CellExecutionState>();
|
||||
private _onCurrentEditModeChanged = new Emitter<CellEditModes>();
|
||||
private _isTrusted: boolean;
|
||||
private _active: boolean;
|
||||
private _hover: boolean;
|
||||
@@ -382,6 +383,10 @@ export class CellModel extends Disposable implements ICellModel {
|
||||
return this._onExecutionStateChanged.event;
|
||||
}
|
||||
|
||||
public get onCurrentEditModeChanged(): Event<CellEditModes> {
|
||||
return this._onCurrentEditModeChanged.event;
|
||||
}
|
||||
|
||||
private fireExecutionStateChanged(): void {
|
||||
this._onExecutionStateChanged.fire(this.executionState);
|
||||
}
|
||||
@@ -416,6 +421,7 @@ export class CellModel extends Disposable implements ICellModel {
|
||||
public set showPreview(val: boolean) {
|
||||
this._showPreview = val;
|
||||
this._onCellPreviewChanged.fire(this._showPreview);
|
||||
this._onCurrentEditModeChanged.fire(this.currentMode);
|
||||
}
|
||||
|
||||
public get showMarkdown(): boolean {
|
||||
@@ -425,6 +431,7 @@ export class CellModel extends Disposable implements ICellModel {
|
||||
public set showMarkdown(val: boolean) {
|
||||
this._showMarkdown = val;
|
||||
this._onCellMarkdownChanged.fire(this._showMarkdown);
|
||||
this._onCurrentEditModeChanged.fire(this.currentMode);
|
||||
}
|
||||
|
||||
public get defaultTextEditMode(): string {
|
||||
|
||||
@@ -540,6 +540,7 @@ export interface ICellModel {
|
||||
cellSourceChanged: boolean;
|
||||
readonly savedConnectionName: string | undefined;
|
||||
attachments: nb.ICellAttachments | undefined;
|
||||
readonly onCurrentEditModeChanged: Event<CellEditModes>;
|
||||
readonly currentMode: CellEditModes;
|
||||
/**
|
||||
* Adds image as an attachment to cell metadata
|
||||
|
||||
Reference in New Issue
Block a user