Skip to content

Commit 07f651f

Browse files
committed
1.11.0.0
1 parent 6825b41 commit 07f651f

16 files changed

+147
-116
lines changed

Assets/screenshot1.png

7.16 KB
Loading

Assets/screenshot2.png

-80.2 KB
Loading

Assets/screenshot3.png

99.7 KB
Loading
Lines changed: 1 addition & 0 deletions
Loading

WorkspaceLauncherForVSCode/Classes/Icon.cs

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,11 +6,15 @@ namespace WorkspaceLauncherForVSCode.Classes;
66

77
public static class Icon
88
{
9+
public static readonly IconInfo Extension = IconHelpers.FromRelativePath(@"Assets\icon.svg");
910
public static readonly IconInfo VisualStudio = IconHelpers.FromRelativePath(@"Assets\VisualStudioIcon.svg");
1011
public static readonly IconInfo VisualStudioCode = IconHelpers.FromRelativePath("Assets\\VisualStudioCodeIcon.svg");
1112
public static readonly IconInfo VisualStudioAndVisualStudioCode = IconHelpers.FromRelativePath("Assets\\VisualStudioAndVisualStudioCodeIcon.svg");
12-
public static readonly IconInfo VisualStudioCodeInsider = IconHelpers.FromRelativePath("Assets\\VisualStudioCodeInsiderIcon.svg");
1313
public static readonly IconInfo FileExplorer = IconHelpers.FromRelativePath("Assets\\FileExplorer.svg");
14+
public static readonly IconInfo GitHub = IconHelpers.FromRelativePath("Assets\\github-mark-white.svg");
1415
public static readonly IconInfo Pinned = new IconInfo("\ue718");
1516
public static readonly IconInfo Unpinned = new IconInfo("\ue77a");
17+
public static readonly IconInfo Web = new("\uE774");
18+
public static readonly IconInfo Help = new IconInfo("\uE897");
19+
public static readonly IconInfo Info = new IconInfo("\uE946");
1620
}

WorkspaceLauncherForVSCode/Classes/VisualStudioCodeInstance.cs

Lines changed: 3 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@ public class VisualStudioCodeInstance
1717
public VisualStudioCodeInstallationType InstallationType { get; set; }
1818
public VisualStudioCodeType VisualStudioCodeType { get; set; }
1919
[JsonIgnore]
20-
public IconInfo Icon => GetIcon();
20+
public static IconInfo Icon => GetIcon();
2121

2222
public VisualStudioCodeInstance() { }
2323
/// <summary>
@@ -41,15 +41,8 @@ internal VisualStudioCodeInstance(string name, string executablePath, string sto
4141
/// Gets the icon associated with the Visual Studio Code instance.
4242
/// </summary>
4343
/// <returns>An icon representing the Visual Studio Code instance.</returns>
44-
private IconInfo GetIcon()
44+
private static IconInfo GetIcon()
4545
{
46-
switch (VisualStudioCodeType)
47-
{
48-
case VisualStudioCodeType.Insider:
49-
return Classes.Icon.VisualStudioCodeInsider;
50-
case VisualStudioCodeType.Default:
51-
default:
52-
return Classes.Icon.VisualStudioCode;
53-
}
46+
return Classes.Icon.VisualStudioCode;
5447
}
5548
}

WorkspaceLauncherForVSCode/Commands/OpenInExplorerCommand.cs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -10,8 +10,8 @@ namespace WorkspaceLauncherForVSCode.Commands
1010
public sealed partial class OpenInExplorerCommand : InvokableCommand
1111
{
1212
private readonly VisualStudioCodeWorkspace? workspace;
13-
private readonly VisualStudioCodePage page;
14-
public OpenInExplorerCommand(string arguments, VisualStudioCodeWorkspace? workspace, VisualStudioCodePage page, string name = "Open in Explorer", string path = "explorer.exe", string? workingDir = null, OpenInShellHelper.ShellRunAsType runAs = OpenInShellHelper.ShellRunAsType.None, bool runWithHiddenWindow = false)
13+
private readonly VisualStudioCodePage? page;
14+
public OpenInExplorerCommand(string arguments, VisualStudioCodeWorkspace? workspace, VisualStudioCodePage? page, string name = "Open in Explorer", string path = "explorer.exe", string? workingDir = null, OpenInShellHelper.ShellRunAsType runAs = OpenInShellHelper.ShellRunAsType.None, bool runWithHiddenWindow = false)
1515
{
1616
Name = name;
1717
_path = path;
Lines changed: 26 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,26 @@
1+
// Copyright (c) 2025 tanchekwei
2+
// Licensed under the MIT License. See the LICENSE file in the project root for details.
3+
using System.Diagnostics;
4+
using Microsoft.CommandPalette.Extensions;
5+
using Microsoft.CommandPalette.Extensions.Toolkit;
6+
7+
namespace WorkspaceLauncherForVSCode.Commands
8+
{
9+
internal sealed partial class OpenUrlCommand : InvokableCommand
10+
{
11+
private readonly string Url;
12+
13+
public OpenUrlCommand(string url, string name, IconInfo icon)
14+
{
15+
Url = url;
16+
Name = name;
17+
Icon = icon;
18+
}
19+
20+
public override ICommandResult Invoke()
21+
{
22+
Process.Start(new ProcessStartInfo(Url) { UseShellExecute = true });
23+
return CommandResult.Hide();
24+
}
25+
}
26+
}

WorkspaceLauncherForVSCode/Package-Dev.appxmanifest

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@
1212
<Identity
1313
Name="15722UsefulApp.WorkspaceLauncherforVSCode.Dev"
1414
Publisher="CN=BF18CC4F-2F9D-43F9-9BF7-0E949EE3057D"
15-
Version="1.10.0.0" />
15+
Version="1.11.0.0" />
1616

1717
<Properties>
1818
<DisplayName>Visual Studio / Code for Command Palette (Dev)</DisplayName>

WorkspaceLauncherForVSCode/Package.appxmanifest

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@
1212
<Identity
1313
Name="15722UsefulApp.WorkspaceLauncherforVSCode"
1414
Publisher="CN=BF18CC4F-2F9D-43F9-9BF7-0E949EE3057D"
15-
Version="1.10.0.0" />
15+
Version="1.11.0.0" />
1616

1717
<Properties>
1818
<DisplayName>Visual Studio / Code for Command Palette</DisplayName>

0 commit comments

Comments
 (0)