Skip to content

Commit 6536bbb

Browse files
authored
Merge pull request #3134 from MahApps/feature/HamburgerMenu_UWPCommunityToolkit_CreatorsStyle_pr2975_i2931
HamburgerMenu and Item selection/hover brush improvements
2 parents 89b57f7 + 94eb1d0 commit 6536bbb

File tree

58 files changed

+2559
-849
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

58 files changed

+2559
-849
lines changed

src/.paket/Paket.Restore.targets

Lines changed: 38 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,9 @@
22
<!-- Prevent dotnet template engine to parse this file -->
33
<!--/-:cnd:noEmit-->
44
<PropertyGroup>
5+
<!-- make MSBuild track this file for incremental builds. -->
6+
<!-- ref https://blogs.msdn.microsoft.com/msbuild/2005/09/26/how-to-ensure-changes-to-a-custom-target-file-prompt-a-rebuild/ -->
7+
<MSBuildAllProjects>$(MSBuildAllProjects);$(MSBuildThisFileFullPath)</MSBuildAllProjects>
58
<!-- Mark that this target file has been loaded. -->
69
<IsPaketRestoreTargetsFileLoaded>true</IsPaketRestoreTargetsFileLoaded>
710
<PaketToolsPath>$(MSBuildThisFileDirectory)</PaketToolsPath>
@@ -27,16 +30,32 @@
2730
<DisableImplicitSystemValueTupleReference>true</DisableImplicitSystemValueTupleReference>
2831
</PropertyGroup>
2932

30-
<Target Name="PaketRestore" BeforeTargets="_GenerateDotnetCliToolReferenceSpecs;_GenerateProjectRestoreGraphPerFramework;_GenerateRestoreGraphWalkPerFramework;CollectPackageReferences" >
33+
<Target Name="PaketRestore" Condition="'$(PaketRestoreDisabled)' != 'True'" BeforeTargets="_GenerateDotnetCliToolReferenceSpecs;_GenerateProjectRestoreGraphPerFramework;_GenerateRestoreGraphWalkPerFramework;CollectPackageReferences" >
3134

3235
<!-- Step 1 Check if lockfile is properly restored -->
3336
<PropertyGroup>
3437
<PaketRestoreRequired>true</PaketRestoreRequired>
38+
<NoWarn>$(NoWarn);NU1603</NoWarn>
3539
</PropertyGroup>
3640

41+
<!-- Because ReadAllText is slow on osx/linux, try to find shasum and awk -->
42+
<PropertyGroup>
43+
<PaketRestoreCachedHasher Condition="'$(OS)' != 'Windows_NT' And '$(PaketRestoreCachedHasher)' == '' And Exists('/usr/bin/shasum') And Exists('/usr/bin/awk')">/usr/bin/shasum $(PaketRestoreCacheFile) | /usr/bin/awk '{ print $1 }'</PaketRestoreCachedHasher>
44+
<PaketRestoreLockFileHasher Condition="'$(OS)' != 'Windows_NT' And '$(PaketRestoreLockFileHash)' == '' And Exists('/usr/bin/shasum') And Exists('/usr/bin/awk')">/usr/bin/shasum $(PaketLockFilePath) | /usr/bin/awk '{ print $1 }'</PaketRestoreLockFileHasher>
45+
</PropertyGroup>
46+
47+
<!-- If shasum and awk exist get the hashes -->
48+
<Exec Condition=" '$(PaketRestoreCachedHasher)' != '' " Command="$(PaketRestoreCachedHasher)" ConsoleToMSBuild='true'>
49+
<Output TaskParameter="ConsoleOutput" PropertyName="PaketRestoreCachedHash" />
50+
</Exec>
51+
<Exec Condition=" '$(PaketRestoreLockFileHasher)' != '' " Command="$(PaketRestoreLockFileHasher)" ConsoleToMSBuild='true'>
52+
<Output TaskParameter="ConsoleOutput" PropertyName="PaketRestoreLockFileHash" />
53+
</Exec>
54+
3755
<PropertyGroup Condition="Exists('$(PaketRestoreCacheFile)') ">
38-
<PaketRestoreCachedHash>$([System.IO.File]::ReadAllText('$(PaketRestoreCacheFile)'))</PaketRestoreCachedHash>
39-
<PaketRestoreLockFileHash>$([System.IO.File]::ReadAllText('$(PaketLockFilePath)'))</PaketRestoreLockFileHash>
56+
<!-- if no hash has been done yet fall back to just reading in the files and comparing them -->
57+
<PaketRestoreCachedHash Condition=" '$(PaketRestoreCachedHash)' == '' ">$([System.IO.File]::ReadAllText('$(PaketRestoreCacheFile)'))</PaketRestoreCachedHash>
58+
<PaketRestoreLockFileHash Condition=" '$(PaketRestoreLockFileHash)' == '' ">$([System.IO.File]::ReadAllText('$(PaketLockFilePath)'))</PaketRestoreLockFileHash>
4059
<PaketRestoreRequired>true</PaketRestoreRequired>
4160
<PaketRestoreRequired Condition=" '$(PaketRestoreLockFileHash)' == '$(PaketRestoreCachedHash)' ">false</PaketRestoreRequired>
4261
<PaketRestoreRequired Condition=" '$(PaketRestoreLockFileHash)' == '' ">true</PaketRestoreRequired>
@@ -80,11 +99,11 @@
8099
</PropertyGroup>
81100

82101
<!-- Step 3 Restore project specific stuff if required -->
83-
<Warning Condition=" '$(PaketRestoreRequired)' == 'true' " Text="Detected a change ('$(PaketRestoreRequiredReason)') in the project file '$(MSBuildProjectFullPath)', calling paket restore" />
102+
<Message Condition=" '$(PaketRestoreRequired)' == 'true' " Importance="low" Text="Detected a change ('$(PaketRestoreRequiredReason)') in the project file '$(MSBuildProjectFullPath)', calling paket restore" />
84103
<Exec Command='$(PaketCommand) restore --project "$(MSBuildProjectFullPath)"' Condition=" '$(PaketRestoreRequired)' == 'true' " ContinueOnError="false" />
85104

86105
<!-- This shouldn't actually happen, but just to be sure. -->
87-
<Error Condition=" !Exists('$(PaketResolvedFilePath)') AND '$(TargetFramework)' != '' " Text="A paket file for the framework '$(TargetFramework)' is missing. Please delete 'paket-files/paket.restore.cached' and call 'paket restore'." />
106+
<Error Condition=" !Exists('$(PaketResolvedFilePath)') AND '$(TargetFramework)' != '' AND '$(ResolveNuGetPackages)' != 'False' " Text="Paket file '$(PaketResolvedFilePath)' is missing while restoring $(MSBuildProjectFile). Please delete 'paket-files/paket.restore.cached' and call 'paket restore'." />
88107

89108
<!-- Step 4 forward all msbuild properties (PackageReference, DotNetCliToolReference) to msbuild -->
90109
<ReadLinesFromFile Condition="Exists('$(PaketResolvedFilePath)')" File="$(PaketResolvedFilePath)" >
@@ -95,9 +114,11 @@
95114
<PaketReferencesFileLinesInfo Include="@(PaketReferencesFileLines)" >
96115
<PackageName>$([System.String]::Copy('%(PaketReferencesFileLines.Identity)').Split(',')[0])</PackageName>
97116
<PackageVersion>$([System.String]::Copy('%(PaketReferencesFileLines.Identity)').Split(',')[1])</PackageVersion>
117+
<AllPrivateAssets>$([System.String]::Copy('%(PaketReferencesFileLines.Identity)').Split(',')[4])</AllPrivateAssets>
98118
</PaketReferencesFileLinesInfo>
99119
<PackageReference Include="%(PaketReferencesFileLinesInfo.PackageName)">
100120
<Version>%(PaketReferencesFileLinesInfo.PackageVersion)</Version>
121+
<PrivateAssets Condition="%(PaketReferencesFileLinesInfo.AllPrivateAssets) == 'true'">All</PrivateAssets>
101122
</PackageReference>
102123
</ItemGroup>
103124

@@ -132,22 +153,29 @@
132153
</Target>
133154

134155
<Target Name="PaketOverrideNuspec" AfterTargets="GenerateNuspec" Condition="('$(IsPackable)' == '' Or '$(IsPackable)' == 'true') And Exists('$(MSBuildProjectDirectory)/obj/$(MSBuildProjectFile).references')" >
156+
<ItemGroup>
157+
<_NuspecFilesNewLocation Include="$(BaseIntermediateOutputPath)$(Configuration)\*.nuspec"/>
158+
</ItemGroup>
159+
135160
<PropertyGroup>
136161
<PaketProjectFile>$(MSBuildProjectDirectory)/$(MSBuildProjectFile)</PaketProjectFile>
137162
<ContinuePackingAfterGeneratingNuspec>true</ContinuePackingAfterGeneratingNuspec>
138163
<UseNewPack>false</UseNewPack>
139164
<UseNewPack Condition=" '$(NuGetToolVersion)' != '4.0.0' ">true</UseNewPack>
165+
<AdjustedNuspecOutputPath>$(BaseIntermediateOutputPath)$(Configuration)</AdjustedNuspecOutputPath>
166+
<AdjustedNuspecOutputPath Condition="@(_NuspecFilesNewLocation) == ''">$(BaseIntermediateOutputPath)</AdjustedNuspecOutputPath>
140167
</PropertyGroup>
141168

142169
<ItemGroup>
143-
<_NuspecFiles Include="$(BaseIntermediateOutputPath)*.nuspec"/>
170+
<_NuspecFiles Include="$(AdjustedNuspecOutputPath)\*.nuspec"/>
144171
</ItemGroup>
145172

146173
<Exec Command='$(PaketCommand) fix-nuspecs files "@(_NuspecFiles)" project-file "$(PaketProjectFile)" ' Condition="@(_NuspecFiles) != ''" />
147174

148175
<ConvertToAbsolutePath Condition="@(_NuspecFiles) != ''" Paths="@(_NuspecFiles)">
149176
<Output TaskParameter="AbsolutePaths" PropertyName="NuspecFileAbsolutePath" />
150-
</ConvertToAbsolutePath>
177+
</ConvertToAbsolutePath>
178+
151179

152180
<!-- Call Pack -->
153181
<PackTask Condition="$(UseNewPack)"
@@ -184,7 +212,7 @@
184212
Serviceable="$(Serviceable)"
185213
FrameworkAssemblyReferences="@(_FrameworkAssemblyReferences)"
186214
ContinuePackingAfterGeneratingNuspec="$(ContinuePackingAfterGeneratingNuspec)"
187-
NuspecOutputPath="$(BaseIntermediateOutputPath)"
215+
NuspecOutputPath="$(AdjustedNuspecOutputPath)"
188216
IncludeBuildOutput="$(IncludeBuildOutput)"
189217
BuildOutputFolder="$(BuildOutputTargetFolder)"
190218
ContentTargetFolders="$(ContentTargetFolders)"
@@ -226,7 +254,7 @@
226254
Serviceable="$(Serviceable)"
227255
AssemblyReferences="@(_References)"
228256
ContinuePackingAfterGeneratingNuspec="$(ContinuePackingAfterGeneratingNuspec)"
229-
NuspecOutputPath="$(BaseIntermediateOutputPath)"
257+
NuspecOutputPath="$(AdjustedNuspecOutputPath)"
230258
IncludeBuildOutput="$(IncludeBuildOutput)"
231259
BuildOutputFolder="$(BuildOutputTargetFolder)"
232260
ContentTargetFolders="$(ContentTargetFolders)"
@@ -236,4 +264,4 @@
236264
NuspecProperties="$(NuspecProperties)"/>
237265
</Target>
238266
<!--/+:cnd:noEmit-->
239-
</Project>
267+
</Project>

src/.paket/paket.exe

88 KB
Binary file not shown.

src/MahApps.Metro.Samples/MahApps.Metro.Caliburn.Demo/MahApps.Metro.Caliburn.Demo.NET40/App.config

Lines changed: 13 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -4,17 +4,17 @@
44
<supportedRuntime version="v4.0" sku=".NETFramework,Version=v4.0" />
55
</startup>
66
<runtime>
7-
8-
<assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1">
9-
<dependentAssembly>
10-
<Paket>True</Paket>
11-
<assemblyIdentity name="System.Runtime" publicKeyToken="b03f5f7f11d50a3a" culture="neutral" />
12-
<bindingRedirect oldVersion="0.0.0.0-65535.65535.65535.65535" newVersion="2.6.10.0" />
13-
</dependentAssembly>
14-
<dependentAssembly>
15-
<Paket>True</Paket>
16-
<assemblyIdentity name="System.Threading.Tasks" publicKeyToken="b03f5f7f11d50a3a" culture="neutral" />
17-
<bindingRedirect oldVersion="0.0.0.0-65535.65535.65535.65535" newVersion="2.6.10.0" />
18-
</dependentAssembly>
19-
</assemblyBinding></runtime>
7+
<assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1">
8+
<dependentAssembly>
9+
<Paket>True</Paket>
10+
<assemblyIdentity name="System.Runtime" publicKeyToken="b03f5f7f11d50a3a" culture="neutral" />
11+
<bindingRedirect oldVersion="0.0.0.0-65535.65535.65535.65535" newVersion="2.6.10.0" />
12+
</dependentAssembly>
13+
<dependentAssembly>
14+
<Paket>True</Paket>
15+
<assemblyIdentity name="System.Threading.Tasks" publicKeyToken="b03f5f7f11d50a3a" culture="neutral" />
16+
<bindingRedirect oldVersion="0.0.0.0-65535.65535.65535.65535" newVersion="2.6.10.0" />
17+
</dependentAssembly>
18+
</assemblyBinding>
19+
</runtime>
2020
</configuration>

0 commit comments

Comments
 (0)