提交 2f1285a1 编写于 作者: A Alex Dima

Fixes #21740: Keybindings editor's info tooltips are misaligned

上级 0bc62d16
......@@ -179,21 +179,21 @@ export class DefineKeybindingController implements editorCommon.IEditorContribut
data.forEach((item) => {
let msg: MarkedString[];
let className: string;
let inlineClassName: string;
let beforeContentClassName: string;
let overviewRulerColor: string;
if (!item.label) {
// this is the error case
msg = [NLS_KB_LAYOUT_ERROR_MESSAGE];
className = 'keybindingError';
inlineClassName = 'inlineKeybindingError';
beforeContentClassName = 'inlineKeybindingError';
overviewRulerColor = 'rgba(250, 100, 100, 0.6)';
} else {
// this is the info case
msg = [NLS_KB_LAYOUT_INFO_MESSAGE];
msg = msg.concat(this._keybindingService.getLabelFor(item.keybinding));
className = 'keybindingInfo';
inlineClassName = 'inlineKeybindingInfo';
beforeContentClassName = 'inlineKeybindingInfo';
overviewRulerColor = 'rgba(100, 100, 250, 0.6)';
}
......@@ -202,7 +202,7 @@ export class DefineKeybindingController implements editorCommon.IEditorContribut
range: new Range(item.range.startLineNumber, item.range.startColumn, item.range.startLineNumber, item.range.startColumn + 1),
options: {
stickiness: editorCommon.TrackedRangeStickiness.NeverGrowsWhenTypingAtEdges,
inlineClassName: inlineClassName
beforeContentClassName: beforeContentClassName
}
});
......
......@@ -277,6 +277,7 @@ export class FoldingController implements IFoldingController {
iconClicked = true;
break;
case editorCommon.MouseTargetType.CONTENT_EMPTY:
case editorCommon.MouseTargetType.CONTENT_TEXT:
if (range.isEmpty && range.startColumn === model.getLineMaxColumn(range.startLineNumber)) {
break;
}
......
......@@ -72,7 +72,7 @@ export class CollapsibleRegion {
if (this._isCollapsed) {
return {
stickiness: editorCommon.TrackedRangeStickiness.NeverGrowsWhenTypingAtEdges,
inlineClassName: 'inline-folded',
afterContentClassName: 'inline-folded',
linesDecorationsClassName: 'folding collapsed'
};
} else {
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册