Skip to content

Commit

Permalink
Remove the debug.enableAllHovers settings
Browse files Browse the repository at this point in the history
fixes #97153
  • Loading branch information
isidorn committed May 7, 2020
1 parent 7a5baba commit 1934836
Show file tree
Hide file tree
Showing 2 changed files with 0 additions and 26 deletions.
5 changes: 0 additions & 5 deletions src/vs/workbench/contrib/debug/browser/debug.contribution.ts
Original file line number Diff line number Diff line change
Expand Up @@ -229,11 +229,6 @@ configurationRegistry.registerConfiguration({
default: 'openOnSessionStart',
description: nls.localize('openDebug', "Controls when the debug view should open.")
},
'debug.enableAllHovers': {
type: 'boolean',
description: nls.localize({ comment: ['This is the description for a setting'], key: 'enableAllHovers' }, "Controls whether the non-debug hovers should be enabled while debugging. When enabled the hover providers will be called to provide a hover. Regular hovers will not be shown even if this setting is enabled."),
default: false
},
'debug.showSubSessionsInToolBar': {
type: 'boolean',
description: nls.localize({ comment: ['This is the description for a setting'], key: 'showSubSessionsInToolBar' }, "Controls whether the debug sub-sessions are shown in the debug tool bar. When this setting is false the stop command on a sub-session will also stop the parent session."),
Expand Down
21 changes: 0 additions & 21 deletions src/vs/workbench/contrib/debug/browser/debugEditorContribution.ts
Original file line number Diff line number Diff line change
Expand Up @@ -30,10 +30,8 @@ import { CoreEditingCommands } from 'vs/editor/browser/controller/coreCommands';
import { first } from 'vs/base/common/arrays';
import { memoize, createMemoizer } from 'vs/base/common/decorators';
import { IEditorHoverOptions, EditorOption } from 'vs/editor/common/config/editorOptions';
import { CancellationToken } from 'vs/base/common/cancellation';
import { DebugHoverWidget } from 'vs/workbench/contrib/debug/browser/debugHover';
import { ITextModel } from 'vs/editor/common/model';
import { getHover } from 'vs/editor/contrib/hover/getHover';
import { dispose, IDisposable } from 'vs/base/common/lifecycle';
import { EditOperation } from 'vs/editor/common/core/editOperation';
import { basename } from 'vs/base/common/path';
Expand Down Expand Up @@ -170,7 +168,6 @@ class DebugEditorContribution implements IDebugEditorContribution {

private toDispose: IDisposable[];
private hoverWidget: DebugHoverWidget;
private nonDebugHoverPosition: Position | undefined;
private hoverRange: Range | null = null;
private mouseDown = false;
private static readonly MEMOIZER = createMemoizer();
Expand Down Expand Up @@ -204,7 +201,6 @@ class DebugEditorContribution implements IDebugEditorContribution {
this.toDispose.push(this.editor.onMouseUp(() => this.mouseDown = false));
this.toDispose.push(this.editor.onMouseMove((e: IEditorMouseEvent) => this.onEditorMouseMove(e)));
this.toDispose.push(this.editor.onMouseLeave((e: IPartialEditorMouseEvent) => {
this.provideNonDebugHoverScheduler.cancel();
const hoverDomNode = this.hoverWidget.getDomNode();
if (!hoverDomNode) {
return;
Expand Down Expand Up @@ -315,24 +311,11 @@ class DebugEditorContribution implements IDebugEditorContribution {
return scheduler;
}

@memoize
private get provideNonDebugHoverScheduler(): RunOnceScheduler {
const scheduler = new RunOnceScheduler(() => {
if (this.editor.hasModel() && this.nonDebugHoverPosition) {
getHover(this.editor.getModel(), this.nonDebugHoverPosition, CancellationToken.None);
}
}, HOVER_DELAY);
this.toDispose.push(scheduler);

return scheduler;
}

private hideHoverWidget(): void {
if (!this.hideHoverScheduler.isScheduled() && this.hoverWidget.isVisible()) {
this.hideHoverScheduler.schedule();
}
this.showHoverScheduler.cancel();
this.provideNonDebugHoverScheduler.cancel();
}

// hover business
Expand All @@ -351,10 +334,6 @@ class DebugEditorContribution implements IDebugEditorContribution {
return;
}

if (this.configurationService.getValue<IDebugConfiguration>('debug').enableAllHovers && mouseEvent.target.position) {
this.nonDebugHoverPosition = mouseEvent.target.position;
this.provideNonDebugHoverScheduler.schedule();
}
const targetType = mouseEvent.target.type;
const stopKey = env.isMacintosh ? 'metaKey' : 'ctrlKey';

Expand Down

0 comments on commit 1934836

Please sign in to comment.