Skip to content

Commit

Permalink
Fix incorrect uID set for minimized icon
Browse files Browse the repository at this point in the history
  • Loading branch information
fcFn committed Jul 26, 2020
1 parent 368172a commit 5dc9460
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 3 deletions.
2 changes: 1 addition & 1 deletion src/traymond.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -128,7 +128,7 @@ void minimizeToTray(TRCONTEXT *context, long restoreWindow) {
nid.hIcon = (HICON)icon;
nid.uFlags = NIF_MESSAGE | NIF_ICON | NIF_TIP | NIF_SHOWTIP;
nid.uVersion = NOTIFYICON_VERSION_4;
nid.uID = reinterpret_cast<UINT>(currWin);
nid.uID = LOWORD(reinterpret_cast<UINT>(currWin));
nid.uCallbackMessage = WM_ICON;
GetWindowText(currWin, nid.szTip, 128);
for (int i = 0; i < context->iconIndex; i++) {
Expand Down
5 changes: 3 additions & 2 deletions traymond.vcxproj
Original file line number Diff line number Diff line change
Expand Up @@ -14,17 +14,18 @@
<VCProjectVersion>15.0</VCProjectVersion>
<ProjectGuid>{7FDF991D-57D7-48AE-BDAC-8DD9BE849241}</ProjectGuid>
<Keyword>Win32Proj</Keyword>
<WindowsTargetPlatformVersion>10.0</WindowsTargetPlatformVersion>
</PropertyGroup>
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.Default.props" />
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'" Label="Configuration">
<ConfigurationType>Application</ConfigurationType>
<UseDebugLibraries>true</UseDebugLibraries>
<PlatformToolset>v141</PlatformToolset>
<PlatformToolset>v142</PlatformToolset>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'" Label="Configuration">
<ConfigurationType>Application</ConfigurationType>
<UseDebugLibraries>false</UseDebugLibraries>
<PlatformToolset>v141</PlatformToolset>
<PlatformToolset>v142</PlatformToolset>
</PropertyGroup>
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.props" />
<ImportGroup Label="ExtensionSettings">
Expand Down

0 comments on commit 5dc9460

Please sign in to comment.