Skip to content
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -2222,12 +2222,14 @@ private static object EnsureBitmapDataFromFormat(string format, bool autoConvert

private const int DV_E_FORMATETC = unchecked((int)0x80040064);
private const int DV_E_LINDEX = unchecked((int)0x80040068);
private const int DV_E_TYMED = unchecked((int)0x80040069);
internal const int DV_E_TYMED = unchecked((int)0x80040069);
private const int DV_E_DVASPECT = unchecked((int)0x8004006B);
private const int OLE_E_NOTRUNNING = unchecked((int)0x80040005);
private const int OLE_E_ADVISENOTSUPPORTED = unchecked((int)0x80040003);
private const int DATA_S_SAMEFORMATETC = unchecked((int)0x00040130);
private const int STG_E_MEDIUMFULL = unchecked((int)0x80030070);
internal const int CLIPBRD_E_CANT_OPEN = unchecked((int)0x800401D0);
internal const int CLIPBRD_E_BAD_DATA = unchecked((int)0x800401D3);

// Const integer base size of the file drop list: "4 + 8 + 4 + 4"
private const int FILEDROPBASESIZE = 20;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -15,18 +15,84 @@
<ProjectReference Include="$(WpfSourceDir)DirectWriteForwarder\DirectWriteForwarder.vcxproj">
<UndefineProperties>TargetFramework;TargetFrameworks</UndefineProperties>
</ProjectReference>
<!-- Clipboard image tests exercise the dynamically loaded BitmapSource/System.Drawing conversion extension. -->
<ProjectReference Include="$(WpfSourceDir)Extensions\PresentationFramework-SystemDrawing\PresentationFramework-SystemDrawing.csproj" />
<ProjectReference Include="$(WpfSourceDir)PresentationCore\PresentationCore.csproj" />
<!-- Clipboard validation paths load PresentationCore resource metadata that depends on System.Xaml. -->
<ProjectReference Include="$(WpfSourceDir)System.Xaml\System.Xaml.csproj" />
<ProjectReference Include="$(WpfSourceDir)WindowsBase\WindowsBase.csproj" />
</ItemGroup>

<!-- Clipboard tests create native WPF windows through OleServicesContext. -->
<ItemGroup Condition="'$(Platform)' != 'ARM64' And '$(Platform)' != 'AnyCPU'">
<ProjectReference Include="$(WpfSourceDir)..\redist\PresentationNative\PresentationNative.vcxproj">
<ReferenceOutputAssembly>false</ReferenceOutputAssembly>
<SkipGetTargetFrameworkProperties>true</SkipGetTargetFrameworkProperties>
<UndefineProperties>TargetFramework;TargetFrameworks</UndefineProperties>
</ProjectReference>
<ProjectReference Include="$(WpfSourceDir)WpfGfx\core\dll\wpfgfx.vcxproj">
<ReferenceOutputAssembly>false</ReferenceOutputAssembly>
<SkipGetTargetFrameworkProperties>true</SkipGetTargetFrameworkProperties>
<UndefineProperties>TargetFramework;TargetFrameworks</UndefineProperties>
</ProjectReference>
<ProjectReference Include="$(WpfSourceDir)..\redist\D3DCompiler\D3DCompiler.vcxproj">
<ReferenceOutputAssembly>false</ReferenceOutputAssembly>
<SkipGetTargetFrameworkProperties>true</SkipGetTargetFrameworkProperties>
<UndefineProperties>TargetFramework;TargetFrameworks</UndefineProperties>
</ProjectReference>
<ProjectReference Include="$(WpfSourceDir)..\redist\VCRuntime\VCRuntime.vcxproj">
<ReferenceOutputAssembly>false</ReferenceOutputAssembly>
<SkipGetTargetFrameworkProperties>true</SkipGetTargetFrameworkProperties>
<UndefineProperties>TargetFramework;TargetFrameworks</UndefineProperties>
</ProjectReference>
</ItemGroup>

<ItemGroup>
<PackageReference Include="Moq" Version="$(MoqPackageVersion)" />
<PackageReference Include="coverlet.msbuild" Version="$(CoverletMSBuildPackageVersion)" />
<PackageReference Include="xunit.stafact" Version="$(XUnitStaFactPackageVersion)" />
<PackageReference Include="FluentAssertions" Version="$(FluentAssertionsVersion)" />
<!-- Supplies the runtime dependency used by PresentationFramework-SystemDrawing during image clipboard conversion. -->
<PackageReference Include="$(SystemDrawingCommonPackage)" Version="$(SystemDrawingCommonVersion)" />
<PackageReference Include="System.Configuration.ConfigurationManager" Version="$(SystemConfigurationConfigurationManagerPackageVersion)" />
<PackageReference Include="System.Formats.Nrbf" Version="$(SystemFormatsNrbfVersion)" />
<PackageReference Include="System.Runtime.Serialization.Formatters" Version="$(SystemRuntimeSerializationFormattersPackageVersion)" />
</ItemGroup>

<Target Name="CopyClipboardTestNativeDependencies"
AfterTargets="Build"
Condition="'$(Platform)' != 'ARM64' And '$(Platform)' != 'AnyCPU'">
<ItemGroup>
<_ClipboardTestNativeDependency
Include="$(ArtifactsDir)bin\PresentationNative\$(Platform)\$(Configuration)\PresentationNative_cor3.dll"
Condition="Exists('$(ArtifactsDir)bin\PresentationNative\$(Platform)\$(Configuration)\PresentationNative_cor3.dll')" />
<_ClipboardTestNativeDependency
Include="$(ArtifactsDir)bin\wpfgfx\$(Platform)\$(Configuration)\wpfgfx_cor3.dll"
Condition="Exists('$(ArtifactsDir)bin\wpfgfx\$(Platform)\$(Configuration)\wpfgfx_cor3.dll')" />
<_ClipboardTestNativeDependency
Include="$(ArtifactsDir)bin\D3DCompiler\$(Platform)\$(Configuration)\D3DCompiler_47_cor3.dll"
Condition="Exists('$(ArtifactsDir)bin\D3DCompiler\$(Platform)\$(Configuration)\D3DCompiler_47_cor3.dll')" />
<_ClipboardTestNativeDependency
Include="$(ArtifactsDir)bin\VCRuntime\$(Platform)\$(Configuration)\**\*.dll"
Condition="Exists('$(ArtifactsDir)bin\VCRuntime\$(Platform)\$(Configuration)')" />

<!-- Native C++ projects use Win32 for x86 in Visual Studio builds. -->
<_ClipboardTestNativeDependency
Include="$(ArtifactsDir)bin\PresentationNative\Win32\$(Configuration)\PresentationNative_cor3.dll"
Condition="'$(Platform)' == 'x86' And Exists('$(ArtifactsDir)bin\PresentationNative\Win32\$(Configuration)\PresentationNative_cor3.dll')" />
<_ClipboardTestNativeDependency
Include="$(ArtifactsDir)bin\wpfgfx\Win32\$(Configuration)\wpfgfx_cor3.dll"
Condition="'$(Platform)' == 'x86' And Exists('$(ArtifactsDir)bin\wpfgfx\Win32\$(Configuration)\wpfgfx_cor3.dll')" />
<_ClipboardTestNativeDependency
Include="$(ArtifactsDir)bin\D3DCompiler\Win32\$(Configuration)\D3DCompiler_47_cor3.dll"
Condition="'$(Platform)' == 'x86' And Exists('$(ArtifactsDir)bin\D3DCompiler\Win32\$(Configuration)\D3DCompiler_47_cor3.dll')" />
<_ClipboardTestNativeDependency
Include="$(ArtifactsDir)bin\VCRuntime\Win32\$(Configuration)\**\*.dll"
Condition="'$(Platform)' == 'x86' And Exists('$(ArtifactsDir)bin\VCRuntime\Win32\$(Configuration)')" />
</ItemGroup>
<Copy SourceFiles="@(_ClipboardTestNativeDependency)"
DestinationFolder="$(TargetDir)"
SkipUnchangedFiles="true" />
</Target>

</Project>
Loading
Loading