mirror of
https://gitflic.ru/project/openide/openide.git
synced 2026-01-06 11:50:54 +07:00
Record file language in completion tracker to track completion in injected code (FUS-1096)
GitOrigin-RevId: ae40e7065c7de34731017167719afa0e7580f4b3
This commit is contained in:
committed by
intellij-monorepo-bot
parent
2ae955aa2c
commit
7907247aee
@@ -1,4 +1,4 @@
|
||||
// Copyright 2000-2020 JetBrains s.r.o. Use of this source code is governed by the Apache 2.0 license that can be found in the LICENSE file.
|
||||
// Copyright 2000-2021 JetBrains s.r.o. and contributors. Use of this source code is governed by the Apache 2.0 license that can be found in the LICENSE file.
|
||||
package com.intellij.codeInsight.lookup.impl;
|
||||
|
||||
import com.intellij.codeInsight.completion.BaseCompletionService;
|
||||
@@ -15,7 +15,6 @@ import com.intellij.internal.statistic.utils.PluginInfo;
|
||||
import com.intellij.internal.statistic.utils.PluginInfoDetectorKt;
|
||||
import com.intellij.lang.Language;
|
||||
import com.intellij.openapi.project.DumbService;
|
||||
import com.intellij.openapi.project.Project;
|
||||
import com.intellij.openapi.vfs.VirtualFile;
|
||||
import com.intellij.psi.PsiFile;
|
||||
import com.intellij.psi.util.PsiUtilCore;
|
||||
@@ -119,6 +118,7 @@ final class LookupUsageTracker {
|
||||
data.addLanguage(myLanguage);
|
||||
PsiFile file = myLookup.getPsiFile();
|
||||
if (file != null) {
|
||||
data.addCurrentFile(file.getLanguage());
|
||||
VirtualFile vFile = file.getVirtualFile();
|
||||
if (vFile != null) {
|
||||
String schema = FileTypeUsageCounterCollector.findSchema(myLookup.getProject(), vFile);
|
||||
|
||||
Reference in New Issue
Block a user