Skip to content
This repository has been archived by the owner on Nov 27, 2020. It is now read-only.

Commit

Permalink
Use paket package manager
Browse files Browse the repository at this point in the history
Pick up VS integration from nuget packages
Fix analyzer warnings
  • Loading branch information
marklam committed Jun 3, 2018
1 parent 10cc9ed commit 9246881
Show file tree
Hide file tree
Showing 34 changed files with 1,779 additions and 609 deletions.
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -166,3 +166,4 @@ pip-log.txt

# Nuget packages
/packages
/paket-files
296 changes: 296 additions & 0 deletions .paket/Paket.Restore.targets

Large diffs are not rendered by default.

Binary file added .paket/paket.bootstrapper.exe
Binary file not shown.
Binary file added .paket/paket.exe
Binary file not shown.
35 changes: 0 additions & 35 deletions ImageComments.VS10.sln

This file was deleted.

5 changes: 5 additions & 0 deletions ImageComments.sln
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,11 @@ Microsoft Visual Studio Solution File, Format Version 12.00
# Visual Studio 15
VisualStudioVersion = 15.0.27428.2005
MinimumVisualStudioVersion = 10.0.40219.1
Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = ".paket", ".paket", "{3D25D288-D5EC-4E08-A8D6-8CD7429388A4}"
ProjectSection(SolutionItems) = preProject
paket.dependencies = paket.dependencies
EndProjectSection
EndProject
Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "Solution Items", "Solution Items", "{5F0DF01A-F177-4AD2-A7C2-E71A530C2DD3}"
ProjectSection(SolutionItems) = preProject
License.txt = License.txt
Expand Down
3 changes: 3 additions & 0 deletions ImageCommentsExtension/ExceptionHandler.cs
Original file line number Diff line number Diff line change
@@ -1,11 +1,14 @@
namespace LM.ImageComments.EditorComponent
{
using Microsoft.VisualStudio.Shell;
using System;

internal static class ExceptionHandler
{
public static void Notify(Exception ex, bool showMessage)
{
ThreadHelper.ThrowIfNotOnUIThread();

string message = string.Format("{0}: {1}", DateTime.Now, ex.ToString());
Console.WriteLine(message);
if (showMessage)
Expand Down
7 changes: 7 additions & 0 deletions ImageCommentsExtension/ImageAdornmentManager.cs
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@ namespace LM.ImageComments.EditorComponent
using System.Windows.Controls;
using System.Windows.Media;
using System.Xml;
using Microsoft.VisualStudio.Shell;
using Microsoft.VisualStudio.Text;
using Microsoft.VisualStudio.Text.Editor;
using Microsoft.VisualStudio.Text.Formatting;
Expand Down Expand Up @@ -42,6 +43,8 @@ static ImageAdornmentManager()
/// </summary>
public static void ToggleEnabled()
{
ThreadHelper.ThrowIfNotOnUIThread();

Enabled = !Enabled;
string message = string.Format("Image comments {0}. Scroll editor window(s) to update.",
Enabled ? "enabled" : "disabled");
Expand Down Expand Up @@ -72,6 +75,8 @@ private void contentTypeChangedHandler(object sender, ContentTypeChangedEventArg
/// </summary>
private void LayoutChangedHandler(object sender, TextViewLayoutChangedEventArgs e)
{
ThreadHelper.ThrowIfNotOnUIThread();

if (!Enabled)
return;

Expand Down Expand Up @@ -122,6 +127,8 @@ private void CreateVisuals(ITextViewLine line, int lineNumber)
bool imageDetected = false; // useful for tracing
#pragma warning restore 219

ThreadHelper.ThrowIfNotOnUIThread();

string lineText = line.Extent.GetText();
string matchedText;
int matchIndex = ImageCommentParser.Match(_contentTypeName, lineText, out matchedText);
Expand Down
166 changes: 0 additions & 166 deletions ImageCommentsExtension/ImageCommentsEditorComponent.VS10.csproj

This file was deleted.

Loading

0 comments on commit 9246881

Please sign in to comment.