From b39e70aab0a8f7b3ed1094de687a9080ef113051 Mon Sep 17 00:00:00 2001 From: sonesuke Date: Sat, 23 Feb 2013 23:03:08 +0900 Subject: [PATCH] first commit --- STools.sln | 20 +++ STools/CommandFilter.cs | 77 +++++++++++ STools/Commands/DocumentThis.cs | 170 +++++++++++++++++++++++ STools/Commands/ICommand.cs | 10 ++ STools/GlobalSuppressions.cs | 11 ++ STools/Guids.cs | 14 ++ STools/Key.snk | Bin 0 -> 596 bytes STools/PkgCmdID.cs | 13 ++ STools/Properties/AssemblyInfo.cs | 36 +++++ STools/Resources.Designer.cs | 64 +++++++++ STools/Resources.resx | 129 ++++++++++++++++++ STools/Resources/Images.png | Bin 0 -> 989 bytes STools/Resources/Package.ico | Bin 0 -> 2998 bytes STools/STools.csproj | 193 +++++++++++++++++++++++++++ STools/STools.vsct | 116 ++++++++++++++++ STools/SToolsPackage.cs | 20 +++ STools/VSPackage.resx | 140 +++++++++++++++++++ STools/source.extension.vsixmanifest | 19 +++ 18 files changed, 1032 insertions(+) create mode 100755 STools.sln create mode 100755 STools/CommandFilter.cs create mode 100755 STools/Commands/DocumentThis.cs create mode 100755 STools/Commands/ICommand.cs create mode 100755 STools/GlobalSuppressions.cs create mode 100755 STools/Guids.cs create mode 100755 STools/Key.snk create mode 100755 STools/PkgCmdID.cs create mode 100755 STools/Properties/AssemblyInfo.cs create mode 100755 STools/Resources.Designer.cs create mode 100755 STools/Resources.resx create mode 100755 STools/Resources/Images.png create mode 100755 STools/Resources/Package.ico create mode 100755 STools/STools.csproj create mode 100755 STools/STools.vsct create mode 100755 STools/SToolsPackage.cs create mode 100755 STools/VSPackage.resx create mode 100755 STools/source.extension.vsixmanifest diff --git a/STools.sln b/STools.sln new file mode 100755 index 0000000..c94843b --- /dev/null +++ b/STools.sln @@ -0,0 +1,20 @@ + +Microsoft Visual Studio Solution File, Format Version 12.00 +# Visual Studio 2012 +Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "STools", "STools\STools.csproj", "{7F76394A-6480-4F47-BAC0-8B8C5D2605DA}" +EndProject +Global + GlobalSection(SolutionConfigurationPlatforms) = preSolution + Debug|Any CPU = Debug|Any CPU + Release|Any CPU = Release|Any CPU + EndGlobalSection + GlobalSection(ProjectConfigurationPlatforms) = postSolution + {7F76394A-6480-4F47-BAC0-8B8C5D2605DA}.Debug|Any CPU.ActiveCfg = Debug|Any CPU + {7F76394A-6480-4F47-BAC0-8B8C5D2605DA}.Debug|Any CPU.Build.0 = Debug|Any CPU + {7F76394A-6480-4F47-BAC0-8B8C5D2605DA}.Release|Any CPU.ActiveCfg = Release|Any CPU + {7F76394A-6480-4F47-BAC0-8B8C5D2605DA}.Release|Any CPU.Build.0 = Release|Any CPU + EndGlobalSection + GlobalSection(SolutionProperties) = preSolution + HideSolutionNode = FALSE + EndGlobalSection +EndGlobal diff --git a/STools/CommandFilter.cs b/STools/CommandFilter.cs new file mode 100755 index 0000000..ba9d0e8 --- /dev/null +++ b/STools/CommandFilter.cs @@ -0,0 +1,77 @@ +using System; +using System.Collections.Generic; +using System.ComponentModel.Composition; +using System.Diagnostics; + +using Microsoft.VisualStudio; +using Microsoft.VisualStudio.Editor; +using Microsoft.VisualStudio.OLE.Interop; +using Microsoft.VisualStudio.Text.Editor; +using Microsoft.VisualStudio.TextManager.Interop; +using Microsoft.VisualStudio.Utilities; + + +namespace S2.STools +{ + [Export(typeof(IVsTextViewCreationListener))] + [ContentType("code")] + [TextViewRole(PredefinedTextViewRoles.Editable)] + class VsTextViewCreationListener : IVsTextViewCreationListener + { + [Import] + IVsEditorAdaptersFactoryService AdaptersFactory = null; + + public void VsTextViewCreated(IVsTextView textViewAdapter) + { + var wpfTextView = AdaptersFactory.GetWpfTextView(textViewAdapter); + if (wpfTextView == null) + { + Debug.Fail("Unable to get IWpfTextView from text view adapter"); + return; + } + + CommandFilter filter = new CommandFilter(wpfTextView); + + IOleCommandTarget next; + if (ErrorHandler.Succeeded(textViewAdapter.AddCommandFilter(filter, out next))) + filter.Next = next; + } + } + + class CommandFilter : IOleCommandTarget + { + IWpfTextView _view; + List _commandList = new List(); + + public CommandFilter(IWpfTextView view) + { + _view = view; + _commandList.Add(new Commands.DocumentThis(_view)); + } + + internal IOleCommandTarget Next { get; set; } + + public int Exec(ref Guid pguidCmdGroup, uint nCmdID, uint nCmdexecopt, IntPtr pvaIn, IntPtr pvaOut) + { + if (pguidCmdGroup != GuidList.guidSToolsCmdSet) return Next.Exec(ref pguidCmdGroup, nCmdID, nCmdexecopt, pvaIn, pvaOut); + + Commands.ICommand command = _commandList.Find(c => c.IsYourId(nCmdID)); + Debug.Assert(command != null); + command.Execute(); + return VSConstants.S_OK; + } + + public int QueryStatus(ref Guid pguidCmdGroup, uint cCmds, OLECMD[] prgCmds, IntPtr pCmdText) + { + if (pguidCmdGroup != GuidList.guidSToolsCmdSet) return Next.QueryStatus(ref pguidCmdGroup, cCmds, prgCmds, pCmdText); + prgCmds[0].cmdf = (uint)(OLECMDF.OLECMDF_SUPPORTED); + Commands.ICommand command = _commandList.Find(c => c.IsYourId(prgCmds[0].cmdID)); + Debug.Assert(command != null); + if (command.IsEnable()) + { + prgCmds[0].cmdf |= (uint)OLECMDF.OLECMDF_ENABLED; + } + return VSConstants.S_OK; + } + } +} \ No newline at end of file diff --git a/STools/Commands/DocumentThis.cs b/STools/Commands/DocumentThis.cs new file mode 100755 index 0000000..10ed6c2 --- /dev/null +++ b/STools/Commands/DocumentThis.cs @@ -0,0 +1,170 @@ +using System; +using System.Collections.Generic; +using System.Linq; +using System.Text; +using System.Threading.Tasks; + +using Microsoft.VisualStudio; +using Microsoft.VisualStudio.Editor; +using Microsoft.VisualStudio.OLE.Interop; +using Microsoft.VisualStudio.Text; +using Microsoft.VisualStudio.Text.Editor; +using Microsoft.VisualStudio.TextManager.Interop; +using Microsoft.VisualStudio.Utilities; + +namespace S2.STools.Commands +{ + class DocumentThis : ICommand + { + IWpfTextView _view; + + public DocumentThis(IWpfTextView view) + { + _view = view; + } + + public bool IsYourId(uint commandId) + { + return commandId == PkgCmdIDList.CommandIdDocumentThis; + } + + public bool IsEnable() + { + return _view.Caret.Position.BufferPosition.GetContainingLine().GetText().Contains("="); + } + + public void Execute() + { + AlignAssignments(); + } + + private void AlignAssignments() + { + // Find all lines above and below with = signs + ITextSnapshot snapshot = _view.TextSnapshot; + + if (snapshot != snapshot.TextBuffer.CurrentSnapshot) + return; + + int currentLineNumber = snapshot.GetLineNumberFromPosition(_view.Caret.Position.BufferPosition); + + Dictionary lineNumberToEqualsColumn = new Dictionary(); + + // Start with the current line + ColumnAndOffset columnAndOffset = GetColumnNumberOfFirstEquals(snapshot.GetLineFromLineNumber(currentLineNumber)); + if (columnAndOffset.Column == -1) + return; + + lineNumberToEqualsColumn[currentLineNumber] = columnAndOffset; + + int lineNumber = currentLineNumber; + int minLineNumber = 0; + int maxLineNumber = snapshot.LineCount - 1; + + // If the selection spans multiple lines, only attempt to fix the lines in the selection + if (!_view.Selection.IsEmpty) + { + var selectionStartLine = _view.Selection.Start.Position.GetContainingLine(); + if (_view.Selection.End.Position > selectionStartLine.End) + { + minLineNumber = selectionStartLine.LineNumber; + maxLineNumber = snapshot.GetLineNumberFromPosition(_view.Selection.End.Position); + } + } + + // Moving backwards + for (lineNumber = currentLineNumber - 1; lineNumber >= minLineNumber; lineNumber--) + { + columnAndOffset = GetColumnNumberOfFirstEquals(snapshot.GetLineFromLineNumber(lineNumber)); + if (columnAndOffset.Column == -1) + break; + + lineNumberToEqualsColumn[lineNumber] = columnAndOffset; + } + + // Moving forwards + for (lineNumber = currentLineNumber + 1; lineNumber <= maxLineNumber; lineNumber++) + { + columnAndOffset = GetColumnNumberOfFirstEquals(snapshot.GetLineFromLineNumber(lineNumber)); + if (columnAndOffset.Column == -1) + break; + + lineNumberToEqualsColumn[lineNumber] = columnAndOffset; + } + + // Perform the actual edit + if (lineNumberToEqualsColumn.Count > 1) + { + int columnToIndentTo = lineNumberToEqualsColumn.Values.Max(c => c.Column); + + using (var edit = snapshot.TextBuffer.CreateEdit()) + { + foreach (var pair in lineNumberToEqualsColumn.Where(p => p.Value.Column < columnToIndentTo)) + { + ITextSnapshotLine line = snapshot.GetLineFromLineNumber(pair.Key); + string spaces = new string(' ', columnToIndentTo - pair.Value.Column); + + if (!edit.Insert(line.Start.Position + pair.Value.Offset, spaces)) + return; + } + + edit.Apply(); + } + } + } + + private ColumnAndOffset GetColumnNumberOfFirstEquals(ITextSnapshotLine line) + { + ITextSnapshot snapshot = line.Snapshot; + int tabSize = _view.Options.GetOptionValue(DefaultOptions.TabSizeOptionId); + + int column = 0; + int nonWhiteSpaceCount = 0; + for (int i = line.Start.Position; i < line.End.Position; i++) + { + char ch = snapshot[i]; + if (ch == '=') + return new ColumnAndOffset() + { + Column = column, + Offset = (i - line.Start.Position) - nonWhiteSpaceCount + }; + + // For the sake of associating characters with the '=', include only + if (!CharAssociatesWithEquals(ch)) + nonWhiteSpaceCount = 0; + else + nonWhiteSpaceCount++; + + if (ch == '\t') + column += tabSize - (column % tabSize); + else + column++; + + // Also, check to see if this is a surrogate pair. If so, skip the next character by incrementing + // the loop counter and increment the nonWhiteSpaceCount without incrementing the column + // count. + if (char.IsHighSurrogate(ch) && + i < line.End.Position - 1 && char.IsLowSurrogate(snapshot[i + 1])) + { + nonWhiteSpaceCount++; + i++; + } + } + + return new ColumnAndOffset() { Column = -1, Offset = -1 }; + } + + struct ColumnAndOffset + { + public int Column; + public int Offset; + } + + static HashSet charsThatAssociateWithEquals = new HashSet() { '+', '-', '.', '<', '>', '/', ':', '\\', '*', '&', '^', '%', '$', '#', '@', '!', '~' }; + private bool CharAssociatesWithEquals(char ch) + { + return charsThatAssociateWithEquals.Contains(ch); + } + } +} diff --git a/STools/Commands/ICommand.cs b/STools/Commands/ICommand.cs new file mode 100755 index 0000000..2af8acc --- /dev/null +++ b/STools/Commands/ICommand.cs @@ -0,0 +1,10 @@ + +namespace S2.STools.Commands +{ + interface ICommand + { + bool IsEnable(); + void Execute(); + bool IsYourId(uint commandId); + } +} diff --git a/STools/GlobalSuppressions.cs b/STools/GlobalSuppressions.cs new file mode 100755 index 0000000..175a74e --- /dev/null +++ b/STools/GlobalSuppressions.cs @@ -0,0 +1,11 @@ +// This file is used by Code Analysis to maintain SuppressMessage +// attributes that are applied to this project. Project-level +// suppressions either have no target or are given a specific target +// and scoped to a namespace, type, member, etc. +// +// To add a suppression to this file, right-click the message in the +// Error List, point to "Suppress Message(s)", and click "In Project +// Suppression File". You do not need to add suppressions to this +// file manually. + +[assembly: System.Diagnostics.CodeAnalysis.SuppressMessage("Microsoft.Design", "CA1017:MarkAssembliesWithComVisible")] diff --git a/STools/Guids.cs b/STools/Guids.cs new file mode 100755 index 0000000..045a952 --- /dev/null +++ b/STools/Guids.cs @@ -0,0 +1,14 @@ +// Guids.cs +// MUST match guids.h +using System; + +namespace S2.STools +{ + static class GuidList + { + public const string guidSToolsPkgString = "df12694e-50e9-4174-b556-ff34cae42223"; + public const string guidSToolsCmdSetString = "096616e7-26a9-482d-a91b-d1389e0c0bd9"; + + public static readonly Guid guidSToolsCmdSet = new Guid(guidSToolsCmdSetString); + }; +} \ No newline at end of file diff --git a/STools/Key.snk b/STools/Key.snk new file mode 100755 index 0000000000000000000000000000000000000000..a1b87ea169c891e429a0432cbd4132f72036051f GIT binary patch literal 596 zcmV-a0;~N80ssI2Bme+XQ$aES1ONa50096akHXn}GBmAj>)s4#O?mB+N-e(Js?l@j zdt+kdC|l3_#~r)uExn?Hp=jR4+d;UvA+(r*>;{(VG0Pkzj7|I!C*e zc=mZP=MS_YIOdGW*8M#qk;;CKmF(gs%;(U#_^!656T%*9aNb zS)?Gt5B14)A;NJV%!B#r7pCPp4JXoBVmolCI>rEvNxV`a)_KTaHxOOjF(3wogQ)t$ zM!fZ#O-?0wCA?@+V0VoU>f9k0#^2b@3t*ekjt?k@Zuq7_7R!Zvf$7Uxa#v18J3s{J zLn+Ab^gSeH7DpH**oGqLN;{SlQPr21C8+h%myrcA9VX`#oQ#UMZet8DwL3gTazwL@ zLIAc7en1q%4ED*2{I+rW61~mehvq2Z6 i%&;;$=ubYV`KM18n@$kpk7d!1Eej4gwFTql#i|<7Zy2}$ literal 0 HcmV?d00001 diff --git a/STools/PkgCmdID.cs b/STools/PkgCmdID.cs new file mode 100755 index 0000000..4ad2016 --- /dev/null +++ b/STools/PkgCmdID.cs @@ -0,0 +1,13 @@ +// PkgCmdID.cs +// MUST match PkgCmdID.h +using System; + +namespace S2.STools +{ + static class PkgCmdIDList + { + public const uint CommandIdDocumentThis = 0x100; + + + }; +} \ No newline at end of file diff --git a/STools/Properties/AssemblyInfo.cs b/STools/Properties/AssemblyInfo.cs new file mode 100755 index 0000000..e4cd482 --- /dev/null +++ b/STools/Properties/AssemblyInfo.cs @@ -0,0 +1,36 @@ +using System; +using System.Reflection; +using System.Resources; +using System.Runtime.CompilerServices; +using System.Runtime.InteropServices; + +// 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("STools")] +[assembly: AssemblyDescription("")] +[assembly: AssemblyConfiguration("")] +[assembly: AssemblyCompany("S2")] +[assembly: AssemblyProduct("STools")] +[assembly: AssemblyCopyright("")] +[assembly: AssemblyTrademark("")] +[assembly: AssemblyCulture("")] +[assembly: ComVisible(false)] +[assembly: CLSCompliant(false)] +[assembly: NeutralResourcesLanguage("en-US")] + +// Version information for an assembly consists of the following four values: +// +// Major Version +// Minor Version +// Build Number +// Revision +// +// You can specify all the values or you can default the Revision and Build Numbers +// by using the '*' as shown below: + +[assembly: AssemblyVersion("1.0.0.0")] +[assembly: AssemblyFileVersion("1.0.0.0")] + + + diff --git a/STools/Resources.Designer.cs b/STools/Resources.Designer.cs new file mode 100755 index 0000000..a495ccd --- /dev/null +++ b/STools/Resources.Designer.cs @@ -0,0 +1,64 @@ +//------------------------------------------------------------------------------ +// +// This code was generated by a tool. +// Runtime Version:2.0.50727.42 +// +// Changes to this file may cause incorrect behavior and will be lost if +// the code is regenerated. +// +//------------------------------------------------------------------------------ + +namespace S2.STools { + using System; + + + /// + /// A strongly-typed resource class, for looking up localized strings, etc. + /// + // This class was auto-generated by the StronglyTypedResourceBuilder + // class via a tool like ResGen or Visual Studio. + // To add or remove a member, edit your .ResX file then rerun ResGen + // with the /str option, or rebuild your VS project. + [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Resources.Tools.StronglyTypedResourceBuilder", "2.0.0.0")] + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + [global::System.Runtime.CompilerServices.CompilerGeneratedAttribute()] + internal class Resources { + + private static global::System.Resources.ResourceManager resourceMan; + + private static global::System.Globalization.CultureInfo resourceCulture; + + [global::System.Diagnostics.CodeAnalysis.SuppressMessageAttribute("Microsoft.Performance", "CA1811:AvoidUncalledPrivateCode")] + internal Resources() { + } + + /// + /// Returns the cached ResourceManager instance used by this class. + /// + [global::System.ComponentModel.EditorBrowsableAttribute(global::System.ComponentModel.EditorBrowsableState.Advanced)] + internal static global::System.Resources.ResourceManager ResourceManager { + get { + if (object.ReferenceEquals(resourceMan, null)) { + global::System.Resources.ResourceManager temp = new global::System.Resources.ResourceManager("S2.STools.Resources", typeof(Resources).Assembly); + resourceMan = temp; + } + return resourceMan; + } + } + + /// + /// Overrides the current thread's CurrentUICulture property for all + /// resource lookups using this strongly typed resource class. + /// + [global::System.ComponentModel.EditorBrowsableAttribute(global::System.ComponentModel.EditorBrowsableState.Advanced)] + internal static global::System.Globalization.CultureInfo Culture { + get { + return resourceCulture; + } + set { + resourceCulture = value; + } + } + + } +} diff --git a/STools/Resources.resx b/STools/Resources.resx new file mode 100755 index 0000000..352987a --- /dev/null +++ b/STools/Resources.resx @@ -0,0 +1,129 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + text/microsoft-resx + + + 2.0 + + + System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + \ No newline at end of file diff --git a/STools/Resources/Images.png b/STools/Resources/Images.png new file mode 100755 index 0000000000000000000000000000000000000000..51fe0d1577e0f962347dee799c68d4c564723416 GIT binary patch literal 989 zcmV<310wv1P)AHIP00004XF*Lt006O% z3;baP00009a7bBm000XN000XN0Y5+@$N&HXe@R3^R9HvNn7@k?K@`V>Tr2noSXfzH zC0JPqAr@8vEu$b;q`l)ni!+7z15&DBX>r)7g&@~hDWZjih`~lU5H7-9f~43S(==l6J2 zi#BQCUVn68Zaw>JiX>qXcumFt2yOFB064Pqx3=z@gZ+-_M~BJ(#`;D=3iY&Oe0DX! zzc_z7u`ds9Q}>oSK#rfEbXs4{oARpJsa`S=F&GRkQ12r^z`t^DV6fGjA2NBu%BdA2 zCS%)WJlk{5;G^``~8S_z($tv1}Php zvT4s90{6HCXfpJCUJtMVlxO)*BS1i(r@xGw*8|3JU=6@E2?9P|fK=(V7fC<}eCBrk z1ON@@Nf3ZG_j)~3tJM-2$`S+QBgkqr2@vqfa`2*rTB;4|K_(om5gUj~zw#iaGI>uf0ikhpF}cE;dO@^znV`M@XFm#Yi{FeGpe z=y&#~4r!VI^8e7`EUn%pKQ<|voIGiMA#Gg*WCfoEky^^Gmz~beCpD#Bt{-TJ7reW1 zb#h445+sMOG=PZv4@z-OHR4r!RaA$5HRx2D`7jbl`>W&&|E00000 LNkvXXu0mjfqT0N0 literal 0 HcmV?d00001 diff --git a/STools/Resources/Package.ico b/STools/Resources/Package.ico new file mode 100755 index 0000000000000000000000000000000000000000..449296f495af26f2b41bb1626a28de7432145472 GIT binary patch literal 2998 zcmeHJIc@?$5G;1VEan=&z(kgxVUhCya&kft2^&G^5AXoz*K%ZEh6^mKRC)SN;9Ie2I^4EsEuJm3ak4(0(K0-)vtx2mz-v5Du5+`|?E{2~nF zj-DY~i1~a@z`8H2Rm8@RN^*7j%+?3;*Is5r;m32z^?Gs%|GV@5y&h|~@doa#jn6yX zPm+(*yf56oD($=C(DJ(6=%K6Llfe5Uo;dPV7%T5PITm!!YhANqXLaS`0ufOBi8crP zkWX22ZGmf>3$1+|+x>UW$1lsro%1<*HCnUTM61<8yWK{o(?Pe}#b7YNXf(oPGQo5@ z#cVdiVzIz-xkMC2Sglrgd0u0)* + + + 11.0 + 11.0 + $(MSBuildExtensionsPath32)\Microsoft\VisualStudio\v$(VisualStudioVersion) + + + + Debug + AnyCPU + 2.0 + {7F76394A-6480-4F47-BAC0-8B8C5D2605DA} + {82b43b9b-a64c-4715-b499-d71e9ca2bd60};{60dc8134-eba5-43b8-bcc9-bb4bc16c2548};{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC} + Library + Properties + S2.STools + STools + True + Key.snk + v4.5 + + + true + full + false + bin\Debug\ + DEBUG;TRACE + prompt + 4 + true + + + pdbonly + true + bin\Release\ + TRACE + prompt + 4 + true + true + + + + + + + + + + + + true + + + + + + + + + + + True + + + True + + + + + + + + + + + + + + + {80CC9F66-E7D8-4DDD-85B6-D9E6CD0E93E2} + 8 + 0 + 0 + primary + False + False + + + {26AD1324-4B7C-44BC-84F8-B86AED45729F} + 10 + 0 + 0 + primary + False + False + + + {1A31287A-4D7D-413E-8E32-3B374931BD89} + 8 + 0 + 0 + primary + False + False + + + {2CE2370E-D744-4936-A090-3FFFE667B0E1} + 9 + 0 + 0 + primary + False + False + + + {1CBA492E-7263-47BB-87FE-639000619B15} + 8 + 0 + 0 + primary + False + False + + + {00020430-0000-0000-C000-000000000046} + 2 + 0 + 0 + primary + False + False + + + + + + + + + True + True + Resources.resx + + + + + + + + + ResXFileCodeGenerator + Resources.Designer.cs + Designer + + + true + VSPackage + + + + + Designer + + + + + + + + Menus.ctmenu + + + + + + + + + + true + + + + + \ No newline at end of file diff --git a/STools/STools.vsct b/STools/STools.vsct new file mode 100755 index 0000000..d3ca3c6 --- /dev/null +++ b/STools/STools.vsct @@ -0,0 +1,116 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/STools/SToolsPackage.cs b/STools/SToolsPackage.cs new file mode 100755 index 0000000..7cd1b8a --- /dev/null +++ b/STools/SToolsPackage.cs @@ -0,0 +1,20 @@ +using System; +using System.Diagnostics; +using System.Globalization; +using System.Runtime.InteropServices; +using Microsoft.VisualStudio.Shell; + +namespace S2.STools +{ + [PackageRegistration(UseManagedResourcesOnly = true)] + [InstalledProductRegistration("#110", "#112", "1.0", IconResourceID = 400)] + [ProvideMenuResource("Menus.ctmenu", 1)] + [Guid(GuidList.guidSToolsPkgString)] + public sealed class SToolsPackage : Package + { + public SToolsPackage() + { + Debug.WriteLine(string.Format(CultureInfo.CurrentCulture, "Entering constructor for: {0}", this.ToString())); + } + } +} diff --git a/STools/VSPackage.resx b/STools/VSPackage.resx new file mode 100755 index 0000000..94ca3c5 --- /dev/null +++ b/STools/VSPackage.resx @@ -0,0 +1,140 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + text/microsoft-resx + + + 2.0 + + + System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + + STools + + + An usefull tools by two persons with initial S. + + + Resources\Package.ico;System.Drawing.Icon, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a + + \ No newline at end of file diff --git a/STools/source.extension.vsixmanifest b/STools/source.extension.vsixmanifest new file mode 100755 index 0000000..8b7a83b --- /dev/null +++ b/STools/source.extension.vsixmanifest @@ -0,0 +1,19 @@ + + + + + STools + An usefull tools by two persons with initial S. + + + + + + + + + + + + +