protected override void AddMonoBehaviourHighlighting(IHighlightingConsumer consumer, ICSharpDeclaration element, string text, string tooltip, DaemonProcessKind kind) { if (!myAssetSerializationMode.IsForceText || !Settings.GetValue((UnitySettings key) => key.EnableInspectorPropertiesEditor) || !Settings.GetValue((UnitySettings key) => key.IsAssetIndexingEnabled)) { AddHighlighting(consumer, element, text, tooltip, kind); return; } if (RiderIconProviderUtil.IsCodeVisionEnabled(Settings, myFieldUsageProvider.ProviderId, () => { base.AddHighlighting(consumer, element, text, tooltip, kind); }, out var useFallback)) { if (!useFallback) { consumer.AddImplicitConfigurableHighlighting(element); } var isProcessing = myDeferredCacheController.IsProcessingFiles(); myFieldUsageProvider.AddInspectorHighlighting(consumer, element, element.DeclaredElement, text, tooltip, isProcessing ? "Inspector values are not available during asset indexing" : text, isProcessing ? myIconHost.Transform(CodeInsightsThemedIcons.InsightWait.Id) : myIconHost.Transform(InsightUnityIcons.InsightUnity.Id), GetActions(element), RiderIconProviderUtil.GetExtraActions(mySolutionTracker, myConnectionTracker)); } }
protected override void AddMonoBehaviourHighlighting(IHighlightingConsumer consumer, ICSharpDeclaration element, string text, string tooltip, DaemonProcessKind kind) { if (!myAssetSerializationMode.IsForceText || !Settings.GetValue((UnitySettings key) => key.EnableInspectorPropertiesEditor)) { AddHighlighting(consumer, element, text, tooltip, kind); return; } if (RiderIconProviderUtil.IsCodeVisionEnabled(Settings, myFieldUsageProvider.ProviderId, () => { base.AddHighlighting(consumer, element, text, tooltip, kind); }, out var useFallback)) { if (!useFallback) { consumer.AddImplicitConfigurableHighlighting(element); } myFieldUsageProvider.AddInspectorHighlighting(consumer, element, element.DeclaredElement, text, tooltip, text, myIconHost.Transform(InsightUnityIcons.InsightUnity.Id), GetActions(element), RiderIconProviderUtil.GetExtraActions(mySolutionTracker, myConnectionTracker)); } }