From 6471fbe19a7f1c8009cfffdbbb9cce3664e459eb Mon Sep 17 00:00:00 2001 From: reunion-maestro-bot Date: Tue, 8 Oct 2024 22:11:43 +0000 Subject: [PATCH] Syncing content from committish 1af696287a7dc82f30bd6368a2a818158a4e580a --- dxaml/xcp/dxaml/lib/AppBar_Partial.cpp | 18 +++++++++++++++++- eng/Version.Details.xml | 12 ++++++------ 2 files changed, 23 insertions(+), 7 deletions(-) diff --git a/dxaml/xcp/dxaml/lib/AppBar_Partial.cpp b/dxaml/xcp/dxaml/lib/AppBar_Partial.cpp index 4b323c17a0..8c4e9090d6 100644 --- a/dxaml/xcp/dxaml/lib/AppBar_Partial.cpp +++ b/dxaml/xcp/dxaml/lib/AppBar_Partial.cpp @@ -27,6 +27,12 @@ #include "XamlRoot.g.h" #include "ElementSoundPlayerService_Partial.h" +#include + +// Bug 53617690: [(GE)WCD_ON][2024.09A][Compat][OS Issue][File explorer]: The context menu appears upside when clicking "See more" in Windows File Explorer. +// Bug 53845621: [1.5 servicing] [(GE)WCD_ON][2024.09A][Compat][OS Issue][File explorer]: The context menu appears upside when clicking "See more" in Windows File Explorer. +#define WINAPPSDK_CHANGEID_53845621 53845621 + using namespace DirectUI; using namespace std::placeholders; @@ -1435,7 +1441,17 @@ _Check_return_ HRESULT AppBar::HasSpaceForAppBarToOpenDown(bool* hasSpace) layoutBounds.X -= windowBounds.X; layoutBounds.Y -= windowBounds.Y; - *hasSpace = (bottomOfExpandedAppBar.Y <= layoutBounds.Y + layoutBounds.Height); + auto bottomOfLayout = layoutBounds.Y + layoutBounds.Height; + + if (WinAppSdk::Containment::IsChangeEnabled()) + { + // Pixel rounding can sometimes cause the bounds and AppBar size to be off by a pixel when we expect them to be equal. + // To account for that possibility, we'll allow the AppBar to open down if its height is at most one pixel greater + // than the layout bounds height. + bottomOfLayout += 1; + } + + *hasSpace = (bottomOfExpandedAppBar.Y <= bottomOfLayout); return S_OK; } diff --git a/eng/Version.Details.xml b/eng/Version.Details.xml index 3c00d6cabd..7d373b76ff 100644 --- a/eng/Version.Details.xml +++ b/eng/Version.Details.xml @@ -2,17 +2,17 @@ - + https://dev.azure.com/microsoft/ProjectReunion/_git/WindowsAppSDK - ad621f84e7cc1b2c4e2409f82582cda4570f22d9 + f51f55b53b094d28a8fb117fe79fa354a3287c3b - + https://dev.azure.com/microsoft/LiftedIXP/_git/DCPP - 534b0b3660f84e948237f93c52b11bb816fb985c + 943a920dac1612ac395a09f42af287a08e6eddac - + https://dev.azure.com/microsoft/LiftedIXP/_git/DCPP - 534b0b3660f84e948237f93c52b11bb816fb985c + 943a920dac1612ac395a09f42af287a08e6eddac