Skip to content

Commit 5fae692

Browse files
committed
1 parent d9a8bd0 commit 5fae692

1 file changed

Lines changed: 2 additions & 4 deletions

File tree

src/vs/editor/contrib/hover/hover.ts

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,6 @@ import * as nls from 'vs/nls';
88
import { IKeyboardEvent } from 'vs/base/browser/keyboardEvent';
99
import { KeyChord, KeyCode, KeyMod } from 'vs/base/common/keyCodes';
1010
import { IDisposable, dispose } from 'vs/base/common/lifecycle';
11-
import * as platform from 'vs/base/common/platform';
1211
import { IEmptyContentData } from 'vs/editor/browser/controller/mouseTarget';
1312
import { ICodeEditor, IEditorMouseEvent, MouseTargetType } from 'vs/editor/browser/editorBrowser';
1413
import { EditorAction, ServicesAccessor, registerEditorAction, registerEditorContribution } from 'vs/editor/browser/editorExtensions';
@@ -146,18 +145,17 @@ export class ModesHoverController implements IEditorContribution {
146145
private _onEditorMouseMove(mouseEvent: IEditorMouseEvent): void {
147146
// const this._editor.getConfiguration().contribInfo.hover.sticky;
148147
let targetType = mouseEvent.target.type;
149-
const hasStopKey = (platform.isMacintosh ? mouseEvent.event.metaKey : mouseEvent.event.ctrlKey);
150148

151149
if (this._isMouseDown && this._hoverClicked && this.contentWidget.isColorPickerVisible()) {
152150
return;
153151
}
154152

155-
if (this._isHoverSticky && targetType === MouseTargetType.CONTENT_WIDGET && mouseEvent.target.detail === ModesContentHoverWidget.ID && !hasStopKey) {
153+
if (this._isHoverSticky && targetType === MouseTargetType.CONTENT_WIDGET && mouseEvent.target.detail === ModesContentHoverWidget.ID) {
156154
// mouse moved on top of content hover widget
157155
return;
158156
}
159157

160-
if (this._isHoverSticky && targetType === MouseTargetType.OVERLAY_WIDGET && mouseEvent.target.detail === ModesGlyphHoverWidget.ID && !hasStopKey) {
158+
if (this._isHoverSticky && targetType === MouseTargetType.OVERLAY_WIDGET && mouseEvent.target.detail === ModesGlyphHoverWidget.ID) {
161159
// mouse moved on top of overlay hover widget
162160
return;
163161
}

0 commit comments

Comments
 (0)