Skip to content

Commit

Permalink
Add commands to Outlining menu
Browse files Browse the repository at this point in the history
  • Loading branch information
mdmower committed Oct 29, 2022
1 parent 247bef7 commit f07139e
Show file tree
Hide file tree
Showing 6 changed files with 13 additions and 104 deletions.
3 changes: 0 additions & 3 deletions Common/CollapseRegionCommon.projitems
Original file line number Diff line number Diff line change
Expand Up @@ -12,9 +12,6 @@
<Compile Include="$(MSBuildThisFileDirectory)RegionCommands.cs" />
<Compile Include="$(MSBuildThisFileDirectory)RegionCommandsPackage.cs" />
</ItemGroup>
<ItemGroup>
<None Include="$(MSBuildThisFileDirectory)RegionCommandsPackage.vsct" />
</ItemGroup>
<ItemGroup>
<EmbeddedResource Include="$(MSBuildThisFileDirectory)VSPackage.resx" />
</ItemGroup>
Expand Down
89 changes: 0 additions & 89 deletions Common/RegionCommandsPackage.vsct

This file was deleted.

19 changes: 10 additions & 9 deletions Metadata/RegionCommandsPackage.vsct
Original file line number Diff line number Diff line change
Expand Up @@ -35,10 +35,12 @@
other menus or buttons (commands); from a visual point of view you can see the
group as the part of a menu contained between two lines. The parent of a group
must be a menu. -->
<!--
<Groups>
<Group guid="guidRegionCommandsPackageCmdSet" id="MyMenuGroup" priority="0x0600">
<Group guid="guidRegionCommandsPackageCmdSet" id="RegionCommandsGroup" priority="0xFFFF">
</Group>
</Groups>
-->

<!--Buttons section. -->
<!--This section defines the elements the user can interact with, like a menu command or a button
Expand All @@ -51,27 +53,26 @@
<CommandFlag>DefaultInvisible</CommandFlag>
<CommandFlag>DynamicVisibility</CommandFlag>
If you do not want an image next to your command, remove the Icon node /> -->
<Button guid="guidRegionCommandsPackageCmdSet" id="RegionExpandId" priority="0x0100" type="Button">
<Button guid="guidRegionCommandsPackageCmdSet" id="RegionExpandId" priority="0xFFFF" type="Button">
<Parent guid="guidStdEd" id="IDG_VS_EDITOR_OUTLINING_CMDS" />
<Strings>
<LocCanonicalName>RegionManagement.Expand</LocCanonicalName>
<ButtonText>Expand all regions</ButtonText>
</Strings>
</Button>
<Button guid="guidRegionCommandsPackageCmdSet" id="RegionCollapseId" priority="0x0100" type="Button">
<Button guid="guidRegionCommandsPackageCmdSet" id="RegionCollapseId" priority="0xFFFF" type="Button">
<Parent guid="guidStdEd" id="IDG_VS_EDITOR_OUTLINING_CMDS" />
<Strings>
<LocCanonicalName>RegionManagement.Collapse</LocCanonicalName>
<ButtonText>Collapse all regions</ButtonText>
</Strings>
</Button>
</Buttons>

</Commands>

<KeyBindings>
<KeyBinding guid="guidRegionCommandsPackageCmdSet" id="RegionExpandId"
editor="guidVSStd97" key1="R" mod1="Control" key2="VK_ADD" mod2="Control"/>
<KeyBinding guid="guidRegionCommandsPackageCmdSet" id="RegionCollapseId"
editor="guidVSStd97" key1="R" mod1="Control" key2="VK_SUBTRACT" mod2="Control"/>
<KeyBinding guid="guidRegionCommandsPackageCmdSet" id="RegionExpandId" editor="guidVSStd97" key1="R" mod1="Control" key2="VK_ADD" mod2="Control" />
<KeyBinding guid="guidRegionCommandsPackageCmdSet" id="RegionCollapseId" editor="guidVSStd97" key1="R" mod1="Control" key2="VK_SUBTRACT" mod2="Control" />
</KeyBindings>

<Symbols>
Expand All @@ -80,7 +81,7 @@

<!-- This is the guid used to group the menu commands together -->
<GuidSymbol name="guidRegionCommandsPackageCmdSet" value="{155b6515-ed99-4e79-8950-2bdf525871db}">
<IDSymbol name="MyMenuGroup" value="0x0200" />
<!--<IDSymbol name="RegionCommandsGroup" value="0x0200" />-->
<IDSymbol name="RegionExpandId" value="0x0100" />
<IDSymbol name="RegionCollapseId" value="0x0101" />
</GuidSymbol>
Expand Down
2 changes: 1 addition & 1 deletion VS2017/source.extension.vsixmanifest
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<?xml version="1.0" encoding="utf-8"?>
<PackageManifest Version="2.0.0" xmlns="http://schemas.microsoft.com/developer/vsx-schema/2011" xmlns:d="http://schemas.microsoft.com/developer/vsx-schema-design/2011">
<Metadata>
<Identity Id="CollapseRegionExtension.0c27e759-a1dc-4e4b-9795-1aeb944b714f" Version="1.4" Language="en-US" Publisher="Matt Mower" />
<Identity Id="CollapseRegionExtension.0c27e759-a1dc-4e4b-9795-1aeb944b714f" Version="1.5" Language="en-US" Publisher="Matt Mower" />
<DisplayName>Collapse Region</DisplayName>
<Description xml:space="preserve">Collapse/Expand #regions in code editor tabs.</Description>
<MoreInfo>https://github.com/mdmower/CollapseRegionExtension</MoreInfo>
Expand Down
2 changes: 1 addition & 1 deletion VS2019/source.extension.vsixmanifest
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<?xml version="1.0" encoding="utf-8"?>
<PackageManifest Version="2.0.0" xmlns="http://schemas.microsoft.com/developer/vsx-schema/2011" xmlns:d="http://schemas.microsoft.com/developer/vsx-schema-design/2011">
<Metadata>
<Identity Id="CollapseRegionExtension.0c27e759-a1dc-4e4b-9795-1aeb944b714f" Version="1.4" Language="en-US" Publisher="Matt Mower" />
<Identity Id="CollapseRegionExtension.0c27e759-a1dc-4e4b-9795-1aeb944b714f" Version="1.5" Language="en-US" Publisher="Matt Mower" />
<DisplayName>Collapse Region</DisplayName>
<Description xml:space="preserve">Collapse/Expand #regions in code editor tabs.</Description>
<MoreInfo>https://github.com/mdmower/CollapseRegionExtension</MoreInfo>
Expand Down
2 changes: 1 addition & 1 deletion VS2022/source.extension.vsixmanifest
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<?xml version="1.0" encoding="utf-8"?>
<PackageManifest Version="2.0.0" xmlns="http://schemas.microsoft.com/developer/vsx-schema/2011" xmlns:d="http://schemas.microsoft.com/developer/vsx-schema-design/2011">
<Metadata>
<Identity Id="CollapseRegionExtension.0c27e759-a1dc-4e4b-9795-1aeb944b714f" Version="1.4" Language="en-US" Publisher="Matt Mower" />
<Identity Id="CollapseRegionExtension.0c27e759-a1dc-4e4b-9795-1aeb944b714f" Version="1.5" Language="en-US" Publisher="Matt Mower" />
<DisplayName>Collapse Region</DisplayName>
<Description xml:space="preserve">Collapse/Expand #regions in code editor tabs.</Description>
<MoreInfo>https://github.com/mdmower/CollapseRegionExtension</MoreInfo>
Expand Down

0 comments on commit f07139e

Please sign in to comment.