Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add VS2019 support #10

Merged
merged 6 commits into from
Dec 27, 2019
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,12 @@ Microsoft Visual Studio Solution File, Format Version 12.00
# Visual Studio 15
VisualStudioVersion = 15.0.26228.9
MinimumVisualStudioVersion = 10.0.40219.1
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "GenerateFilter", "GenerateFilter\GenerateFilter.csproj", "{18555A86-3A5F-4D33-8C12-01E288BDC30E}"
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "GenerateCppFiltersExtension", "GenerateCppFiltersExtension\GenerateCppFiltersExtension.csproj", "{18555A86-3A5F-4D33-8C12-01E288BDC30E}"
EndProject
Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "Solution Items", "Solution Items", "{6B724A13-034C-4ABA-884B-15B550A8274F}"
ProjectSection(SolutionItems) = preProject
appveyor.yml = appveyor.yml
EndProjectSection
EndProject
Global
GlobalSection(SolutionConfigurationPlatforms) = preSolution
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
//------------------------------------------------------------------------------
// <copyright file="GenerateFilter.cs" company="Company">
// <copyright file="GenerateCppFilters.cs" company="Company">
// Copyright (c) Company. All rights reserved.
// </copyright>
//------------------------------------------------------------------------------
Expand All @@ -16,9 +16,9 @@
using System.Reflection;
using System.Text;

namespace VisualStudioCppExtensions
namespace GenerateCppFiltersExtension
{
internal sealed class GenerateFilter
internal sealed class GenerateCppFilters
{
#region ATTRIBUTES
public const int CommandId = 0x0100;
Expand All @@ -41,11 +41,11 @@ void OnBeforeQueryStatus(object sender, EventArgs e)
}
#endregion
/// <summary>
/// Initializes a new instance of the <see cref="GenerateFilter"/> class.
/// Initializes a new instance of the <see cref="GenerateCppFilters"/> class.
/// Adds our command handlers for menu (commands must exist in the command table file)
/// </summary>
/// <param name="package">Owner package, not null.</param>
private GenerateFilter(Package package)
private GenerateCppFilters(Package package)
{
if (package == null)
{
Expand All @@ -68,7 +68,7 @@ private GenerateFilter(Package package)
/// <summary>
/// Gets the instance of the command.
/// </summary>
public static GenerateFilter Instance
public static GenerateCppFilters Instance
{
get;
private set;
Expand All @@ -91,7 +91,7 @@ private IServiceProvider ServiceProvider
/// <param name="package">Owner package, not null.</param>
public static void Initialize(Package package)
{
Instance = new GenerateFilter(package);
Instance = new GenerateCppFilters(package);
}

#region PROJECT UTILS
Expand Down Expand Up @@ -158,7 +158,7 @@ static private void SetAdditionalIncludeDirectories(Project project, Dictionary<
includePaths.Add(GetRelativePathIfNeeded(projectPath, Path.GetDirectoryName(file)));
}

string filterAssemblyInstallionPath = Path.GetDirectoryName(GetAssemblyLocalPathFrom(typeof(GenerateFilterPackage)));
string filterAssemblyInstallionPath = Path.GetDirectoryName(GetAssemblyLocalPathFrom(typeof(GenerateCppFiltersPackage)));

DTE dte = (DTE)Package.GetGlobalService(typeof(DTE));
if (dte.Version.StartsWith("14"))
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@
<UpgradeBackupLocation>
</UpgradeBackupLocation>
<OldToolsVersion>15.0</OldToolsVersion>
<DeployExtension Condition="'$(AppVeyor)' != ''">False</DeployExtension>
</PropertyGroup>
<PropertyGroup>
<SignAssembly>true</SignAssembly>
Expand All @@ -20,7 +21,7 @@
<AssemblyOriginatorKeyFile>Key.snk</AssemblyOriginatorKeyFile>
</PropertyGroup>
<PropertyGroup>
<ApplicationIcon>Resources\GenerateFilter.ico</ApplicationIcon>
<ApplicationIcon>Resources\GenerateCppFilters.ico</ApplicationIcon>
</PropertyGroup>
<Import Project="$(MSBuildExtensionsPath)\$(MSBuildToolsVersion)\Microsoft.Common.props" Condition="Exists('$(MSBuildExtensionsPath)\$(MSBuildToolsVersion)\Microsoft.Common.props')" />
<PropertyGroup>
Expand All @@ -31,8 +32,8 @@
<ProjectGuid>{18555A86-3A5F-4D33-8C12-01E288BDC30E}</ProjectGuid>
<OutputType>Library</OutputType>
<AppDesignerFolder>Properties</AppDesignerFolder>
<RootNamespace>VisualStudioCppExtensions</RootNamespace>
<AssemblyName>VisualStudioCppExtensions</AssemblyName>
<RootNamespace>GenerateCppFiltersExtension</RootNamespace>
<AssemblyName>GenerateCppFiltersExtension</AssemblyName>
<TargetFrameworkVersion>v4.6</TargetFrameworkVersion>
<GeneratePkgDefFile>true</GeneratePkgDefFile>
<IncludeAssemblyInVSIXContainer>true</IncludeAssemblyInVSIXContainer>
Expand All @@ -59,32 +60,29 @@
<WarningLevel>4</WarningLevel>
</PropertyGroup>
<ItemGroup>
<Compile Include="GenerateFilter.cs" />
<Compile Include="GenerateFilterPackage.cs" />
<Compile Include="GenerateCppFilters.cs" />
<Compile Include="GenerateCppFiltersPackage.cs" />
<Compile Include="Properties\AssemblyInfo.cs" />
</ItemGroup>
<ItemGroup>
<None Include="Key.snk" />
<None Include="packages.config">
<SubType>Designer</SubType>
</None>
<Content Include="Resources\LICENSE">
<IncludeInVSIX>true</IncludeInVSIX>
</Content>
<None Include="packages.config" />
<None Include="source.extension.vsixmanifest">
<SubType>Designer</SubType>
</None>
</ItemGroup>
<ItemGroup>
<VSCTCompile Include="GenerateFilterPackage.vsct">
<VSCTCompile Include="GenerateCppFiltersPackage.vsct">
<ResourceName>Menus.ctmenu</ResourceName>
<SubType>Designer</SubType>
</VSCTCompile>
<Content Include="index.html" />
<Content Include="Resources\GenerateFilterPackage.ico">
<Content Include="Resources\GenerateCppFiltersPackage.ico">
<IncludeInVSIX>true</IncludeInVSIX>
</Content>
<Content Include="Resources\GenerateFilter.ico">
<Content Include="Resources\GenerateCppFilters.ico">
<CopyToOutputDirectory>Always</CopyToOutputDirectory>
<IncludeInVSIX>true</IncludeInVSIX>
</Content>
Expand All @@ -97,7 +95,6 @@
<Content Include="Resources\PreviewImage.png">
<IncludeInVSIX>true</IncludeInVSIX>
</Content>
<Content Include="stylesheet.css" />
</ItemGroup>
<ItemGroup>
<Reference Include="EnvDTE, Version=8.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a">
Expand All @@ -120,75 +117,60 @@
</Reference>
<Reference Include="Microsoft.VisualStudio.Imaging, Version=14.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a, processorArchitecture=MSIL">
<HintPath>..\packages\Microsoft.VisualStudio.Imaging.14.3.25407\lib\net45\Microsoft.VisualStudio.Imaging.dll</HintPath>
<Private>True</Private>
</Reference>
<Reference Include="Microsoft.VisualStudio.OLE.Interop, Version=7.1.40304.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a">
<HintPath>..\packages\Microsoft.VisualStudio.OLE.Interop.7.10.6070\lib\Microsoft.VisualStudio.OLE.Interop.dll</HintPath>
<Private>True</Private>
</Reference>
<Reference Include="Microsoft.VisualStudio.Shell.14.0, Version=14.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a, processorArchitecture=MSIL" />
<Reference Include="Microsoft.VisualStudio.Shell.14.0, Version=14.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a, processorArchitecture=MSIL">
<HintPath>..\packages\Microsoft.VisualStudio.Shell.14.0.14.3.25407\lib\Microsoft.VisualStudio.Shell.14.0.dll</HintPath>
</Reference>
<Reference Include="Microsoft.VisualStudio.Shell.Immutable.10.0, Version=10.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a, processorArchitecture=MSIL">
<HintPath>..\packages\Microsoft.VisualStudio.Shell.Immutable.10.0.10.0.30319\lib\net40\Microsoft.VisualStudio.Shell.Immutable.10.0.dll</HintPath>
<Private>True</Private>
</Reference>
<Reference Include="Microsoft.VisualStudio.Shell.Immutable.11.0, Version=11.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a, processorArchitecture=MSIL">
<HintPath>..\packages\Microsoft.VisualStudio.Shell.Immutable.11.0.11.0.50727\lib\net45\Microsoft.VisualStudio.Shell.Immutable.11.0.dll</HintPath>
<Private>True</Private>
</Reference>
<Reference Include="Microsoft.VisualStudio.Shell.Immutable.12.0, Version=12.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a, processorArchitecture=MSIL">
<HintPath>..\packages\Microsoft.VisualStudio.Shell.Immutable.12.0.12.0.21003\lib\net45\Microsoft.VisualStudio.Shell.Immutable.12.0.dll</HintPath>
<Private>True</Private>
</Reference>
<Reference Include="Microsoft.VisualStudio.Shell.Immutable.14.0, Version=14.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a, processorArchitecture=MSIL">
<HintPath>..\packages\Microsoft.VisualStudio.Shell.Immutable.14.0.14.3.25407\lib\net45\Microsoft.VisualStudio.Shell.Immutable.14.0.dll</HintPath>
<Private>True</Private>
</Reference>
<Reference Include="Microsoft.VisualStudio.Shell.Interop, Version=7.1.40304.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a">
<HintPath>..\packages\Microsoft.VisualStudio.Shell.Interop.7.10.6071\lib\Microsoft.VisualStudio.Shell.Interop.dll</HintPath>
<Private>True</Private>
</Reference>
<Reference Include="Microsoft.VisualStudio.Shell.Interop.10.0, Version=10.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a, processorArchitecture=MSIL">
<EmbedInteropTypes>True</EmbedInteropTypes>
<HintPath>..\packages\Microsoft.VisualStudio.Shell.Interop.10.0.10.0.30319\lib\Microsoft.VisualStudio.Shell.Interop.10.0.dll</HintPath>
<Private>True</Private>
<EmbedInteropTypes>True</EmbedInteropTypes>
</Reference>
<Reference Include="Microsoft.VisualStudio.Shell.Interop.11.0, Version=11.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a, processorArchitecture=MSIL">
<EmbedInteropTypes>True</EmbedInteropTypes>
<HintPath>..\packages\Microsoft.VisualStudio.Shell.Interop.11.0.11.0.61030\lib\Microsoft.VisualStudio.Shell.Interop.11.0.dll</HintPath>
<Private>True</Private>
<EmbedInteropTypes>True</EmbedInteropTypes>
</Reference>
<Reference Include="Microsoft.VisualStudio.Shell.Interop.12.0, Version=12.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a, processorArchitecture=MSIL">
<EmbedInteropTypes>True</EmbedInteropTypes>
<HintPath>..\packages\Microsoft.VisualStudio.Shell.Interop.12.0.12.0.30110\lib\Microsoft.VisualStudio.Shell.Interop.12.0.dll</HintPath>
<Private>True</Private>
<EmbedInteropTypes>True</EmbedInteropTypes>
</Reference>
<Reference Include="Microsoft.VisualStudio.Shell.Interop.8.0, Version=8.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a">
<HintPath>..\packages\Microsoft.VisualStudio.Shell.Interop.8.0.8.0.50727\lib\Microsoft.VisualStudio.Shell.Interop.8.0.dll</HintPath>
<Private>True</Private>
</Reference>
<Reference Include="Microsoft.VisualStudio.Shell.Interop.9.0, Version=9.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a">
<HintPath>..\packages\Microsoft.VisualStudio.Shell.Interop.9.0.9.0.30729\lib\Microsoft.VisualStudio.Shell.Interop.9.0.dll</HintPath>
<Private>True</Private>
</Reference>
<Reference Include="Microsoft.VisualStudio.TextManager.Interop, Version=7.1.40304.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a">
<HintPath>..\packages\Microsoft.VisualStudio.TextManager.Interop.7.10.6070\lib\Microsoft.VisualStudio.TextManager.Interop.dll</HintPath>
<Private>True</Private>
</Reference>
<Reference Include="Microsoft.VisualStudio.TextManager.Interop.8.0, Version=8.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a">
<HintPath>..\packages\Microsoft.VisualStudio.TextManager.Interop.8.0.8.0.50727\lib\Microsoft.VisualStudio.TextManager.Interop.8.0.dll</HintPath>
<Private>True</Private>
</Reference>
<Reference Include="Microsoft.VisualStudio.Threading, Version=14.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a, processorArchitecture=MSIL">
<HintPath>..\packages\Microsoft.VisualStudio.Threading.14.1.111\lib\net45\Microsoft.VisualStudio.Threading.dll</HintPath>
<Private>True</Private>
</Reference>
<Reference Include="Microsoft.VisualStudio.Utilities, Version=14.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a, processorArchitecture=MSIL">
<HintPath>..\packages\Microsoft.VisualStudio.Utilities.14.3.25407\lib\net45\Microsoft.VisualStudio.Utilities.dll</HintPath>
<Private>True</Private>
</Reference>
<Reference Include="Microsoft.VisualStudio.Validation, Version=14.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a, processorArchitecture=MSIL">
<HintPath>..\packages\Microsoft.VisualStudio.Validation.14.1.111\lib\net45\Microsoft.VisualStudio.Validation.dll</HintPath>
<Private>True</Private>
</Reference>
<Reference Include="stdole, Version=7.0.3300.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a">
<EmbedInteropTypes>False</EmbedInteropTypes>
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
//------------------------------------------------------------------------------
// <copyright file="GenerateFilterPackage.cs" company="Company">
// <copyright file="GenerateCppFiltersPackage.cs" company="Company">
// Copyright (c) Company. All rights reserved.
// </copyright>
//------------------------------------------------------------------------------
Expand All @@ -16,7 +16,7 @@
using Microsoft.VisualStudio.Shell.Interop;
using Microsoft.Win32;

namespace VisualStudioCppExtensions
namespace GenerateCppFiltersExtension
{
/// <summary>
/// This is the class that implements the package exposed by this assembly.
Expand All @@ -38,20 +38,20 @@ namespace VisualStudioCppExtensions
[PackageRegistration(UseManagedResourcesOnly = true)]
[InstalledProductRegistration("#110", "#112", "1.0", IconResourceID = 400)] // Info on this package for Help/About
[ProvideMenuResource("Menus.ctmenu", 1)]
[Guid(GenerateFilterPackage.PackageGuidString)]
[Guid(GenerateCppFiltersPackage.PackageGuidString)]
[SuppressMessage("StyleCop.CSharp.DocumentationRules", "SA1650:ElementDocumentationMustBeSpelledCorrectly", Justification = "pkgdef, VS and vsixmanifest are valid VS terms")]
[ProvideAutoLoad(UIContextGuids.SolutionExists)]
public sealed class GenerateFilterPackage : Package
public sealed class GenerateCppFiltersPackage : Package
{
/// <summary>
/// GenerateFilterPackage GUID string.
/// GenerateCppFiltersPackage GUID string.
/// </summary>
public const string PackageGuidString = "99d03761-6200-41ad-b2a1-638ae9e780e5";

/// <summary>
/// Initializes a new instance of the <see cref="GenerateFilter"/> class.
/// Initializes a new instance of the <see cref="GenerateCppFilters"/> class.
/// </summary>
public GenerateFilterPackage()
public GenerateCppFiltersPackage()
{
// Inside this method you can place any initialization code that does not require
// any Visual Studio service because at this point the package object is created but
Expand All @@ -67,7 +67,7 @@ public GenerateFilterPackage()
/// </summary>
protected override void Initialize()
{
GenerateFilter.Initialize(this);
GenerateCppFilters.Initialize(this);
base.Initialize();
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,9 +3,9 @@
<Extern href="stdidcmd.h"/>
<Extern href="vsshlids.h"/>

<Commands package="guidGenerateFilterPackage">
<Commands package="guidGenerateCppFiltersPackage">
<Groups>
<Group guid="guidGenerateFilterPackageCmdSet" id="grpIdProjectContextAdd" priority="0x0102">
<Group guid="guidGenerateCppFiltersPackageCmdSet" id="grpIdProjectContextAdd" priority="0x0102">
<!-- Can check what the other existing id/priority (for positioning) are by looking at SharedCmdPlace.vsct, need to modify the group priority while targetting the right id -->
<Parent guid="guidSHLMainMenu" id="IDM_VS_CTXT_PROJNODE" />

Expand All @@ -15,9 +15,9 @@
</Groups>

<Buttons>
<Button guid="guidGenerateFilterPackageCmdSet" id="GenerateFilterCommand" type="Button" priority="0x0100">
<Parent guid="guidGenerateFilterPackageCmdSet" id="grpIdProjectContextAdd" />
<Icon guid="GenerateFilterIcon" id="GenerateFilterIconID" />
<Button guid="guidGenerateCppFiltersPackageCmdSet" id="GenerateCppFiltersCommand" type="Button" priority="0x0100">
<Parent guid="guidGenerateCppFiltersPackageCmdSet" id="grpIdProjectContextAdd" />
<Icon guid="GenerateCppFiltersIcon" id="GenerateCppFiltersIconID" />

<CommandFlag>DefaultInvisible</CommandFlag>
<CommandFlag>DynamicVisibility</CommandFlag>
Expand All @@ -29,21 +29,21 @@
</Buttons>

<Bitmaps>
<Bitmap guid="GenerateFilterIcon" href="Resources\GenerateFilter.ico" usedList="GenerateFilterIconID"/>
<Bitmap guid="GenerateCppFiltersIcon" href="Resources\GenerateCppFilters.ico" usedList="GenerateCppFiltersIconID"/>
</Bitmaps>
</Commands>

<Symbols>
<GuidSymbol name="guidGenerateFilterPackage" value="{99d03761-6200-41ad-b2a1-638ae9e780e5}" />
<GuidSymbol name="guidGenerateCppFiltersPackage" value="{99d03761-6200-41ad-b2a1-638ae9e780e5}" />

<GuidSymbol name="guidGenerateFilterPackageCmdSet" value="{acd8036f-19ae-43b2-a2d6-11788cb282fe}">
<IDSymbol name="GenerateFilterCommand" value="0x0100" />
<GuidSymbol name="guidGenerateCppFiltersPackageCmdSet" value="{acd8036f-19ae-43b2-a2d6-11788cb282fe}">
<IDSymbol name="GenerateCppFiltersCommand" value="0x0100" />
<IDSymbol name="grpIdProjectContextAdd" value="0x1080" />
<IDSymbol name="grpIdSolutionContextAdd" value="0x1081" />
</GuidSymbol>

<GuidSymbol name="GenerateFilterIcon" value="{363F9640-FBB7-4403-AB20-9A53EA067ECA}">
<IDSymbol name="GenerateFilterIconID" value="1" />
<GuidSymbol name="GenerateCppFiltersIcon" value="{363F9640-FBB7-4403-AB20-9A53EA067ECA}">
<IDSymbol name="GenerateCppFiltersIconID" value="1" />
</GuidSymbol>
</Symbols>
</CommandTable>
File renamed without changes.
Original file line number Diff line number Diff line change
Expand Up @@ -5,11 +5,11 @@
// General Information about an assembly is controlled through the following
// set of attributes. Change these attribute values to modify the information
// associated with an assembly.
[assembly: AssemblyTitle("VisualStudioCppExtensions")]
[assembly: AssemblyTitle("GenerateCppFiltersExtension")]
[assembly: AssemblyDescription("")]
[assembly: AssemblyConfiguration("")]
[assembly: AssemblyCompany("")]
[assembly: AssemblyProduct("VisualStudioCppExtensions")]
[assembly: AssemblyProduct("GenerateCppFiltersExtension")]
[assembly: AssemblyCopyright("")]
[assembly: AssemblyTrademark("")]
[assembly: AssemblyCulture("")]
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -118,13 +118,13 @@
<value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</resheader>
<data name="110" xml:space="preserve">
<value>GenerateFilter Extension</value>
<value>GenerateCppFilters Extension</value>
</data>
<data name="112" xml:space="preserve">
<value>GenerateFilter Visual Studio Extension Detailed Info</value>
<value>GenerateCppFilters Visual Studio Extension Detailed Info</value>
</data>
<assembly alias="System.Windows.Forms" name="System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" />
<data name="400" type="System.Resources.ResXFileRef, System.Windows.Forms">
<value>Resources\GenerateFilterPackage.ico;System.Drawing.Icon, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a</value>
<value>Resources\GenerateCppFiltersPackage.ico;System.Drawing.Icon, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a</value>
</data>
</root>
Loading