Skip to content

Commit

Permalink
Merge branch 'main' into fix-387
Browse files Browse the repository at this point in the history
  • Loading branch information
rmarinho authored May 17, 2021
2 parents 5254c6d + 11ab949 commit 102a9fc
Show file tree
Hide file tree
Showing 1,002 changed files with 24,729 additions and 6,306 deletions.
4 changes: 4 additions & 0 deletions .editorconfig
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,10 @@ indent_size = 2
[*.cs]
indent_style = tab

# TODO: Disable platform compatibility analyzer until all CA1416 violations are fixed
# https://docs.microsoft.com/en-us/dotnet/fundamentals/code-analysis/quality-rules/ca1416
dotnet_diagnostic.CA1416.severity = none

# Modifier preferences
dotnet_style_require_accessibility_modifiers = never:suggestion

Expand Down
48 changes: 30 additions & 18 deletions .nuspec/Microsoft.Maui.Controls.MultiTargeting.targets
Original file line number Diff line number Diff line change
@@ -1,41 +1,47 @@
<Project>
<ItemGroup Condition="$(TargetFramework.StartsWith('Xamarin.iOS')) != true AND $(TargetFramework.StartsWith('net6.0-ios')) != true AND $(TargetFramework.StartsWith('net6.0-maccatalyst')) != true ">
<Compile Remove="**\*.iOS.cs" />
<None Include="**\*.iOS.cs" />
<Compile Remove="**\iOS\*.cs" />
<None Include="**\iOS\*.cs" />
<Compile Remove="**\**\*.iOS.cs" />
<None Include="**\**\*.iOS.cs" />
<Compile Remove="**\iOS\**\*.cs" />
<None Include="**\iOS\**\*.cs" />
</ItemGroup>
<ItemGroup Condition="$(TargetFramework.StartsWith('Xamarin.Mac')) != true ">
<Compile Remove="**\*.Mac.cs" />
<None Include="**\*.Mac.cs" />
<Compile Remove="**\Mac\*.cs" />
<None Include="**\Mac\*.cs" />
<Compile Remove="**\Mac\**\*.cs" />
<None Include="**\Mac\**\*.cs" />
</ItemGroup>
<ItemGroup Condition="$(TargetFramework.StartsWith('Xamarin.Mac')) != true AND $(TargetFramework.StartsWith('Xamarin.iOS')) != true AND $(TargetFramework.StartsWith('net6.0-ios')) != true AND $(TargetFramework.StartsWith('net6.0-maccatalyst')) != true">
<Compile Remove="**\*.MaciOS.cs" />
<None Include="**\*.MaciOS.cs" />
<Compile Remove="**\MaciOS\*.cs" />
<None Include="**\MaciOS\*.cs" />
<Compile Remove="**\MaciOS\**\*.cs" />
<None Include="**\MaciOS\**\*.cs" />
</ItemGroup>
<ItemGroup Condition="$(TargetFramework.StartsWith('MonoAndroid')) != true AND $(TargetFramework.StartsWith('net6.0-android')) != true ">
<Compile Remove="**\*.Android.cs" />
<None Include="**\*.Android.cs" />
<Compile Remove="**\Android\*.cs" />
<None Include="**\Android\*.cs" />
<Compile Remove="**\**\*.Android.cs" />
<None Include="**\**\*.Android.cs" />
<Compile Remove="**\Android\**\*.cs" />
<None Include="**\Android\**\*.cs" />
</ItemGroup>
<ItemGroup Condition="$(TargetFramework.StartsWith('netstandard')) != true ">
<Compile Remove="**\*.Standard.cs" />
<None Include="**\*.Standard.cs" />
<Compile Remove="**\Standard\*.cs" />
<None Include="**\Standard\*.cs" />
<Compile Remove="**\Standard\**\*.cs" />
<None Include="**\Standard\**\*.cs" />
</ItemGroup>
<ItemGroup Condition="$(TargetFramework.Contains('-windows')) != true ">
<Compile Remove="**\*.Windows.cs" />
<None Include="**\*.Windows.cs" />
<Compile Remove="**\Windows\*.cs" />
<None Include="**\Windows\*.cs" />
<Compile Remove="**\Windows\**\*.cs" />
<None Include="**\Windows\**\*.cs" />
<Compile Remove="**\*.uwp.cs" />
<None Include="**\*.uwp.cs" />
</ItemGroup>

<ItemGroup Condition=" $(TargetFramework.StartsWith('uap10.0')) ">
<Compile Remove="**\*.uwp.cs" />
<None Include="**\*.uwp.cs" />
</ItemGroup>

<PropertyGroup>
<!-- Windows -->
<WindowsProjectFolder>Platform\Windows\</WindowsProjectFolder>
Expand Down Expand Up @@ -64,7 +70,6 @@
<DefineConstants>$(DefineConstants);MACCATALYST;IOS</DefineConstants>
</PropertyGroup>


<PropertyGroup Condition="'$(Configuration)|$(TargetFramework)|$(Platform)'=='Debug|netstandard2.0|AnyCPU'">
<TreatWarningsAsErrors>false</TreatWarningsAsErrors>
</PropertyGroup>
Expand All @@ -73,12 +78,19 @@
<PackageReference Include="Xamarin.AndroidX.Lifecycle.LiveData" />
<PackageReference Include="Xamarin.Google.Android.Material" />
<PackageReference Include="Xamarin.AndroidX.Legacy.Support.V4" />
<PackageReference Include="Xamarin.AndroidX.Navigation.UI" />
<PackageReference Include="Xamarin.AndroidX.Navigation.Fragment" />
<PackageReference Include="Xamarin.AndroidX.Navigation.Runtime" />
<PackageReference Include="Xamarin.AndroidX.Navigation.Common" />
</ItemGroup>
<PropertyGroup Condition="$(TargetFramework.Contains('-windows')) == true ">
<TargetPlatformMinVersion>10.0.17763.0</TargetPlatformMinVersion>
<RuntimeIdentifiers>win10-x86;win10-x64;win10-arm64</RuntimeIdentifiers>
<DefineConstants>WINDOWS;$(DefineConstants)</DefineConstants>
</PropertyGroup>
<PropertyGroup Condition=" $(TargetFramework.StartsWith('uap10.0')) ">
<DefineConstants>WINDOWS_UWP;$(DefineConstants)</DefineConstants>
</PropertyGroup>
<ItemGroup Condition="$(TargetFramework.Contains('-windows')) == true ">
<PackageReference Include="Microsoft.ProjectReunion" />
<PackageReference Include="Microsoft.ProjectReunion.Foundation" />
Expand Down
33 changes: 21 additions & 12 deletions .nuspec/Microsoft.Maui.Resizetizer.targets
Original file line number Diff line number Diff line change
Expand Up @@ -32,14 +32,18 @@
AssemblyFile="$(_ResizetizerTaskAssemblyName)"
TaskName="Microsoft.Maui.Resizetizer.GenerateSplashStoryboard" />

<UsingTask
AssemblyFile="$(_ResizetizerTaskAssemblyName)"
TaskName="Microsoft.Maui.Resizetizer.GetMauiAssetPath" />

<PropertyGroup>
<CleanDependsOn>
$(CleanDependsOn);
_CleanResizetizer;
</CleanDependsOn>

<_ResizetizerInputsFile>$(IntermediateOutputPath)resizetizer.inputs</_ResizetizerInputsFile>
<_ResizetizerStampFile>$(IntermediateOutputPath)resizetizer.stamp</_ResizetizerStampFile>
<_ResizetizerInputsFile>$(IntermediateOutputPath)mauiimage.inputs</_ResizetizerInputsFile>
<_ResizetizerStampFile>$(IntermediateOutputPath)mauiimage.stamp</_ResizetizerStampFile>
<_MauiFontInputsFile>$(IntermediateOutputPath)mauifont.inputs</_MauiFontInputsFile>
<_MauiFontStampFile>$(IntermediateOutputPath)mauifont.stamp</_MauiFontStampFile>
<_MauiSplashInputsFile>$(IntermediateOutputPath)mauisplash.inputs</_MauiSplashInputsFile>
Expand Down Expand Up @@ -79,6 +83,7 @@
<ResizetizeDependsOnTargets>
$(ResizetizeDependsOnTargets);
ResizetizeCollectItems;
ProcessMauiSplashScreens;
</ResizetizeDependsOnTargets>
<ProcessMauiFontsDependsOnTargets>
$(ProcessMauiFontsDependsOnTargets);
Expand Down Expand Up @@ -166,7 +171,7 @@
<MauiItem Include="@(MauiImage)" ItemGroupName="MauiImage" Condition="'%(MauiImage.ForegroundFile)' == ''" />
<MauiItem Include="@(MauiImage)" ItemGroupName="MauiImage" Condition="'%(MauiImage.ForegroundFile)' != ''" ForegroundFile="$([System.IO.Path]::GetFullPath('%(MauiImage.ForegroundFile)'))" />
<MauiItem Include="@(MauiFont)" ItemGroupName="MauiFont" />
<MauiItem Include="@(MauiAsset)" ItemGroupName="MauiAsset" />
<MauiItem Include="@(MauiAsset)" ItemGroupName="MauiAsset" ProjectDirectory="$(MSBuildProjectDirectory)" />
<MauiItem Include="@(MauiSplashScreen)" ItemGroupName="MauiSplashScreen" />
</ItemGroup>

Expand Down Expand Up @@ -246,15 +251,19 @@
</Target>

<Target Name="ProcessMauiAssets">
<ItemGroup Condition="'$(_ResizetizerIsAndroidApp)' == 'True'">
<AndroidAsset Include="@(MauiAsset)" Link="%(FileName)%(Extension)" />
</ItemGroup>
<ItemGroup Condition="'$(_ResizetizerIsiOSApp)' == 'True'">
<Content Include="@(MauiAsset)" Link="%(FileName)%(Extension)" />
</ItemGroup>
<ItemGroup Condition="'$(_ResizetizerIsUWPApp)' == 'True' Or '$(_ResizetizerIsWinUIApp)' == 'True'">
<ContentWithTargetPath Include="@(MauiAsset)" TargetPath="Assets\%(Filename)%(Extension)" />
</ItemGroup>
<PropertyGroup Condition="'$(_ResizetizerIsUWPApp)' == 'True' Or '$(_ResizetizerIsWinUIApp)' == 'True'">
<_MauiAssetFolderName>Assets</_MauiAssetFolderName>
<_MauiAssetItemMetadata>TargetPath</_MauiAssetItemMetadata>
</PropertyGroup>
<GetMauiAssetPath
ProjectDirectory="$(MSBuildProjectDirectory)"
FolderName="$(_MauiAssetFolderName)"
ItemMetadata="$(_MauiAssetItemMetadata)"
Input="@(MauiAsset)">
<Output ItemName="AndroidAsset" TaskParameter="Output" Condition="'$(_ResizetizerIsAndroidApp)' == 'True'" />
<Output ItemName="Content" TaskParameter="Output" Condition="'$(_ResizetizerIsiOSApp)' == 'True'" />
<Output ItemName="ContentWithTargetPath" TaskParameter="Output" Condition="'$(_ResizetizerIsUWPApp)' == 'True' Or '$(_ResizetizerIsWinUIApp)' == 'True'" />
</GetMauiAssetPath>
</Target>

<Target Name="ProcessMauiSplashScreens"
Expand Down
Loading

0 comments on commit 102a9fc

Please sign in to comment.