Browse Source

SharpDevelop can now find the location of Sandcastle Help File Builder version 1.9.1.0

git-svn-id: svn://svn.sharpdevelop.net/sharpdevelop/branches/3.0@6425 1ccf3a8d-04fe-1044-b7c0-cef0b8235c61
pull/1/head
Matt Ward 15 years ago
parent
commit
c3aa874d24
  1. 18
      src/Main/Base/Project/Src/Commands/ProjectMenuCommands.cs

18
src/Main/Base/Project/Src/Commands/ProjectMenuCommands.cs

@ -49,9 +49,25 @@ namespace ICSharpCode.SharpDevelop.Project.Commands @@ -49,9 +49,25 @@ namespace ICSharpCode.SharpDevelop.Project.Commands
public class GenerateProjectDocumentation : AbstractMenuCommand
{
static string[] registryKeys = new string[] {
@"HKEY_CLASSES_ROOT\Sandcastle Help File Builder Project\shell\open\command",
@"HKEY_CLASSES_ROOT\SandcastleBuilder.shfbproj\shell\open\command"
};
static string FindSHFB()
{
string command = Registry.GetValue(@"HKEY_CLASSES_ROOT\Sandcastle Help File Builder Project\shell\open\command", null, string.Empty) as string;
foreach (string registryKey in registryKeys) {
string fileName = FindSHFB(registryKey);
if (fileName != null) {
return fileName;
}
}
return null;
}
static string FindSHFB(string registryKey)
{
string command = Registry.GetValue(registryKey, null, string.Empty) as string;
return ExtractExecutableFromCommand(command);
}

Loading…
Cancel
Save