mirror of
https://github.com/ckaczor/azuredatastudio.git
synced 2026-01-27 01:25:36 -05:00
Remove optimized table setting (#16857)
* Remove optimized table option * comment out * completely remove * one more
This commit is contained in:
@@ -20,7 +20,6 @@ import { escape } from 'sql/base/common/strings';
|
||||
import { hyperLinkFormatter, textFormatter } from 'sql/base/browser/ui/table/formatters';
|
||||
import { AdditionalKeyBindings } from 'sql/base/browser/ui/table/plugins/additionalKeyBindings.plugin';
|
||||
import { CopyKeybind } from 'sql/base/browser/ui/table/plugins/copyKeybind.plugin';
|
||||
import { GridTable as HighPerfGridTable } from 'sql/workbench/contrib/query/browser/highPerfGridPanel';
|
||||
|
||||
import { IContextMenuService, IContextViewService } from 'vs/platform/contextview/browser/contextView';
|
||||
import { IConfigurationService } from 'vs/platform/configuration/common/configuration';
|
||||
@@ -69,17 +68,15 @@ const MIN_GRID_HEIGHT = (MIN_GRID_HEIGHT_ROWS * ROW_HEIGHT) + HEADER_HEIGHT + ES
|
||||
export class GridPanel extends Disposable {
|
||||
private container = document.createElement('div');
|
||||
private scrollableView: ScrollableView;
|
||||
private tables: Array<GridTable<any> | HighPerfGridTable<any>> = [];
|
||||
private tables: Array<GridTable<any>> = [];
|
||||
private tableDisposable = this._register(new DisposableStore());
|
||||
private queryRunnerDisposables = this._register(new DisposableStore());
|
||||
|
||||
private runner: QueryRunner;
|
||||
|
||||
private maximizedGrid: GridTable<any> | HighPerfGridTable<any>;
|
||||
private maximizedGrid: GridTable<any>;
|
||||
private _state: GridPanelState | undefined;
|
||||
|
||||
private readonly optimized = this.configurationService.getValue<IQueryEditorConfiguration>('queryEditor').results.optimizedTable;
|
||||
|
||||
constructor(
|
||||
@IConfigurationService private readonly configurationService: IConfigurationService,
|
||||
@IInstantiationService private readonly instantiationService: IInstantiationService,
|
||||
@@ -87,7 +84,7 @@ export class GridPanel extends Disposable {
|
||||
@IThemeService private readonly themeService: IThemeService,
|
||||
) {
|
||||
super();
|
||||
this.scrollableView = new ScrollableView(this.container, { scrollDebouce: this.optimized ? 0 : undefined });
|
||||
this.scrollableView = new ScrollableView(this.container);
|
||||
this.scrollableView.onDidScroll(e => {
|
||||
if (this.state && this.scrollableView.length !== 0) {
|
||||
this.state.scrollPosition = e.scrollTop;
|
||||
@@ -204,7 +201,7 @@ export class GridPanel extends Disposable {
|
||||
}
|
||||
|
||||
private addResultSet(resultSet: ResultSetSummary[]) {
|
||||
const tables: Array<GridTable<any> | HighPerfGridTable<any>> = [];
|
||||
const tables: Array<GridTable<any>> = [];
|
||||
|
||||
for (const set of resultSet) {
|
||||
// ensure we aren't adding a resultSet that is already visible
|
||||
@@ -221,12 +218,7 @@ export class GridPanel extends Disposable {
|
||||
this.state.tableStates.push(tableState);
|
||||
}
|
||||
}
|
||||
let table: GridTable<any> | HighPerfGridTable<any>;
|
||||
if (this.optimized) {
|
||||
table = this.instantiationService.createInstance(HighPerfGridTable, this.runner, set, tableState);
|
||||
} else {
|
||||
table = this.instantiationService.createInstance(GridTable, this.runner, set, tableState);
|
||||
}
|
||||
const table = this.instantiationService.createInstance(GridTable, this.runner, set, tableState);
|
||||
this.tableDisposable.add(tableState.onMaximizedChange(e => {
|
||||
if (e) {
|
||||
this.maximizeTable(table.id);
|
||||
|
||||
Reference in New Issue
Block a user