mirror of
https://github.com/microsoft/vscode.git
synced 2026-04-23 18:19:12 +01:00
Rename modeId -> languageId
This commit is contained in:
@@ -15,16 +15,16 @@ import type * as vscode from 'vscode';
|
||||
import { equals } from 'vs/base/common/arrays';
|
||||
|
||||
const _modeId2WordDefinition = new Map<string, RegExp>();
|
||||
export function setWordDefinitionFor(modeId: string, wordDefinition: RegExp | undefined): void {
|
||||
export function setWordDefinitionFor(languageId: string, wordDefinition: RegExp | undefined): void {
|
||||
if (!wordDefinition) {
|
||||
_modeId2WordDefinition.delete(modeId);
|
||||
_modeId2WordDefinition.delete(languageId);
|
||||
} else {
|
||||
_modeId2WordDefinition.set(modeId, wordDefinition);
|
||||
_modeId2WordDefinition.set(languageId, wordDefinition);
|
||||
}
|
||||
}
|
||||
|
||||
export function getWordDefinitionFor(modeId: string): RegExp | undefined {
|
||||
return _modeId2WordDefinition.get(modeId);
|
||||
export function getWordDefinitionFor(languageId: string): RegExp | undefined {
|
||||
return _modeId2WordDefinition.get(languageId);
|
||||
}
|
||||
|
||||
export class ExtHostDocumentData extends MirrorTextModel {
|
||||
|
||||
Reference in New Issue
Block a user