Skip to content

Commit

Permalink
Fix for RemoveDesktop
Browse files Browse the repository at this point in the history
  • Loading branch information
RadAd committed Nov 30, 2022
1 parent 2ffe8b5 commit 022e7f2
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 3 deletions.
3 changes: 2 additions & 1 deletion src/VDUtils.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -333,12 +333,13 @@ void CreateDesktop(LogF* pLog, void* logdata)
template <class VD, class VDMI>
void RemoveDesktop(LogF* pLog, void* logdata, VDMI* pDesktopManagerInternal, int d)
{
CComPtr<VD> pDesktop = GetDesktop<VD>(pLog, logdata, pDesktopManagerInternal, d);
CComPtr<VD> pCurrentDesktop;
LogHR(pLog, logdata, GetCurrentDesktop(pDesktopManagerInternal, &pCurrentDesktop), L"GetCurrentDesktop");
CComPtr<VD> pDesktop = d == -1 ? pCurrentDesktop : GetDesktop<VD>(pLog, logdata, pDesktopManagerInternal, d);
CComPtr<VD> pFallbackDesktop = pCurrentDesktop;
if (!pFallbackDesktop || pFallbackDesktop.IsEqualObject(pDesktop))
{
pFallbackDesktop.Release();
LogHR(pLog, logdata, pDesktopManagerInternal->GetAdjacentDesktop(pCurrentDesktop, AdjacentDesktop::RightDirection, &pFallbackDesktop), TYPE_E_OUTOFBOUNDS, L"GetAdjacentDesktop");
if (!pFallbackDesktop)
LogHR(pLog, logdata, pDesktopManagerInternal->GetAdjacentDesktop(pCurrentDesktop, AdjacentDesktop::LeftDirection, &pFallbackDesktop), TYPE_E_OUTOFBOUNDS, L"GetAdjacentDesktop");
Expand Down
4 changes: 2 additions & 2 deletions src/VirtualDesktop.rc
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
//

VS_VERSION_INFO VERSIONINFO
FILEVERSION 1,3,1,0
FILEVERSION 1,3,2,0
PRODUCTVERSION 3,0,2,2161
FILEFLAGSMASK 0x17L
#ifdef _DEBUG
Expand All @@ -24,7 +24,7 @@ BEGIN
BEGIN
BLOCK "040904E4"
BEGIN
VALUE "FileVersion", "1.3.1.0"
VALUE "FileVersion", "1.3.2.0"
VALUE "LegalCopyright", "� 2021 - Adam Gates"

// Don't change the entries below!
Expand Down

0 comments on commit 022e7f2

Please sign in to comment.