From 63d8f7660501bd1c315e224d9cb4198ea2078b1d Mon Sep 17 00:00:00 2001 From: Mike Crider <45052236+codendone@users.noreply.github.com> Date: Thu, 6 Feb 2025 08:39:26 -0800 Subject: [PATCH 1/2] Fix TerminalVelocityFeatures-CallingPreviewSupport.h to be generated. --- .../WindowsAppSDK-SetupBuildEnvironment-Steps.yml | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/build/AzurePipelinesTemplates/WindowsAppSDK-SetupBuildEnvironment-Steps.yml b/build/AzurePipelinesTemplates/WindowsAppSDK-SetupBuildEnvironment-Steps.yml index 2d8b70f472..9b47663798 100644 --- a/build/AzurePipelinesTemplates/WindowsAppSDK-SetupBuildEnvironment-Steps.yml +++ b/build/AzurePipelinesTemplates/WindowsAppSDK-SetupBuildEnvironment-Steps.yml @@ -147,6 +147,14 @@ steps: arguments: -Path $(Build.SourcesDirectory)\dev\common\TerminalVelocityFeatures-AppNotifications.xml -Channel $(channel) -Language C++ -Namespace Microsoft.Windows.AppNotifications -Output $(Build.SourcesDirectory)\dev\common\TerminalVelocityFeatures-AppNotifications.h workingDirectory: '$(Build.SourcesDirectory)' +- task: powershell@2 + displayName: 'Create CallingPreviewSupport TerminalVelocity features' + inputs: + targetType: filePath + filePath: tools\TerminalVelocity\Generate-TerminalVelocityFeatures.ps1 + arguments: -Path $(Build.SourcesDirectory)\dev\common\TerminalVelocityFeatures-AppNotifications.xml -Channel $(channel) -Language C++ -Namespace Microsoft.Windows.CallingPreviewSupport -Output $(Build.SourcesDirectory)\dev\common\TerminalVelocityFeatures-CallingPreviewSupport.h + workingDirectory: '$(Build.SourcesDirectory)' + - task: powershell@2 displayName: 'Create PushNotifications TerminalVelocity features' inputs: From 6a2e70fb2cb9a100a750d88ede88ceb99a65e0df Mon Sep 17 00:00:00 2001 From: Mike Crider <45052236+codendone@users.noreply.github.com> Date: Thu, 6 Feb 2025 14:25:10 -0800 Subject: [PATCH 2/2] Define IsCallingPreviewSupported when needed. --- .../AppNotificationConferencingConfig.cpp | 13 +++++++++++++ 1 file changed, 13 insertions(+) diff --git a/dev/AppNotifications/AppNotificationConferencingConfig.cpp b/dev/AppNotifications/AppNotificationConferencingConfig.cpp index b89f302129..a095cf7b2b 100644 --- a/dev/AppNotifications/AppNotificationConferencingConfig.cpp +++ b/dev/AppNotifications/AppNotificationConferencingConfig.cpp @@ -5,6 +5,7 @@ #include "AppNotificationConferencingConfig.h" #include "Microsoft.Windows.AppNotifications.AppNotificationConferencingConfig.g.cpp" #include +#include "TerminalVelocityFeatures-CallingPreviewSupport.h" namespace winrt::Microsoft::Windows::AppNotifications::implementation { @@ -48,3 +49,15 @@ namespace winrt::Microsoft::Windows::AppNotifications::implementation return false; } } + +// This function (not in the "implementation" namespace) is not defined when the feature is disabled, +// resulting in a linker error. Define the function for that scenario. +#if WINDOWSAPPRUNTIME_MICROSOFT_WINDOWS_CALLINGPREVIEWSUPPORT_FEATURE_CALLINGPREVIEWSUPPORT_ENABLED != 1 +namespace winrt::Microsoft::Windows::AppNotifications +{ + bool AppNotificationConferencingConfig::IsCallingPreviewSupported() + { + return false; + } +} +#endif