Skip to content
Draft
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
6 changes: 3 additions & 3 deletions src/common/utils/modulesRegistry.h
Original file line number Diff line number Diff line change
Expand Up @@ -240,7 +240,7 @@ inline registry::ChangeSet getRegistryPreviewSetDefaultAppChangeSet(const std::w
std::wstring registryKeyPrefix = L"Software\\Classes\\";

std::wstring appPath = installationDir + L"\\WinUI3Apps\\PowerToys.RegistryPreview.exe";
std::wstring command = appPath + L" \"----ms-protocol:ms-encodedlaunch:App?ContractId=Windows.File&Verb=open&File=%1\"";
std::wstring command = L"\"" + appPath + L"\" \"----ms-protocol:ms-encodedlaunch:App?ContractId=Windows.File&Verb=open&File=%1\"";

changes.push_back({ scope, registryKeyPrefix + fullAppName + L"\\" + L"Application", L"ApplicationName", appName });
changes.push_back({ scope, registryKeyPrefix + fullAppName + L"\\" + L"DefaultIcon", std::nullopt, appPath });
Expand All @@ -257,8 +257,8 @@ inline registry::ChangeSet getRegistryPreviewChangeSet(const std::wstring instal
using vec_t = std::vector<registry::ValueChange>;
vec_t changes;

std::wstring command = installationDir;
command.append(L"\\WinUI3Apps\\PowerToys.RegistryPreview.exe \"%1\"");
std::wstring command = L"\"" + installationDir;
command.append(L"\\WinUI3Apps\\PowerToys.RegistryPreview.exe\" \"%1\"");
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

我说的是preview pane的东西

changes.push_back({ scope, L"Software\\Classes\\regfile\\shell\\preview\\command", std::nullopt, command });

std::wstring icon_path = installationDir;
Expand Down