Skip to content

Commit 8b63081

Browse files
committed
Use Python display name for submenus
1 parent de375ea commit 8b63081

File tree

1 file changed

+6
-3
lines changed

1 file changed

+6
-3
lines changed

src/pyshellext/shellext.cpp

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -84,9 +84,12 @@ static HRESULT ReadIdleInstalls(std::vector<IdleData> &idles, HKEY hive, REGSAM
8484
break;
8585
}
8686

87-
IdleData data = {
88-
.title = std::wstring(L"IDLE ") + name
89-
};
87+
IdleData data;
88+
89+
err = RegReadStr(hkTag, L"DisplayName", data.title);
90+
if (err) {
91+
data.title = std::wstring(L"Python ") + name;
92+
}
9093

9194
err = RegReadStr(hkInstall, L"WindowedExecutablePath", data.exe);
9295
if (err == ERROR_FILE_NOT_FOUND || err == ERROR_INVALID_DATA) {

0 commit comments

Comments
 (0)