-
Notifications
You must be signed in to change notification settings - Fork 45
/
SampleCodeInsightsProvider.cs
34 lines (27 loc) · 1.21 KB
/
SampleCodeInsightsProvider.cs
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
using System.Collections.Generic;
using JetBrains.ProjectModel;
using JetBrains.ReSharper.Daemon.CodeInsights;
using JetBrains.Rider.Model;
using JetBrains.Util;
namespace ReSharperPlugin.CodeVision;
[SolutionComponent]
public class SampleCodeInsightsProvider : ICodeInsightsProvider
{
public bool IsAvailableIn(ISolution solution)
{
return true;
}
public void OnClick(CodeInsightHighlightInfo highlightInfo, ISolution solution)
{
MessageBox.ShowInfo($"{nameof(SampleCodeInsightsProvider)}.{nameof(OnClick)}", "ReSharper SDK");
}
public void OnExtraActionClick(CodeInsightHighlightInfo highlightInfo, string actionId, ISolution solution)
{
MessageBox.ShowInfo($"{nameof(SampleCodeInsightsProvider)}.{nameof(OnExtraActionClick)}", "ReSharper SDK");
}
public string ProviderId => nameof(SampleCodeInsightsProvider);
public string DisplayName => $"ReSharper SDK: {nameof(SampleCodeInsightsProvider)}.{nameof(DisplayName)}";
public CodeVisionAnchorKind DefaultAnchor => CodeVisionAnchorKind.Top;
public ICollection<CodeVisionRelativeOrdering> RelativeOrderings => new List<CodeVisionRelativeOrdering>
{ new CodeVisionRelativeOrderingFirst() };
}