Browse Source
Merge branch 'master' into fixes/Warnings/CA1223
pull/9854/head
workgroupengineering
3 years ago
committed by
GitHub
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
10 changed files with
21 additions and
17 deletions
-
src/Avalonia.Base/Rendering/SceneGraph/VisualNode.cs
-
src/Avalonia.Controls.DataGrid/DataGrid.cs
-
src/Avalonia.Controls.DataGrid/DataGridColumn.cs
-
src/Avalonia.Controls.DataGrid/DataGridColumnHeader.cs
-
src/Avalonia.Controls.DataGrid/DataGridRow.cs
-
src/Avalonia.Controls.DataGrid/DataGridRows.cs
-
src/Avalonia.Controls/ApplicationLifetimes/IClassicDesktopStyleApplicationLifetime.cs
-
src/Avalonia.Controls/BorderVisual.cs
-
src/Avalonia.OpenGL/Avalonia.OpenGL.csproj
-
src/Browser/Avalonia.Browser/webapp/package-lock.json
|
|
|
@ -303,7 +303,7 @@ namespace Avalonia.Rendering.SceneGraph |
|
|
|
if (ClipToBounds) |
|
|
|
{ |
|
|
|
context.Transform = Matrix.Identity; |
|
|
|
if (ClipToBoundsRadius.IsEmpty) |
|
|
|
if (ClipToBoundsRadius.IsDefault) |
|
|
|
context.PushClip(ClipBounds); |
|
|
|
else |
|
|
|
context.PushClip(new RoundedRect(ClipBounds, ClipToBoundsRadius)); |
|
|
|
|
|
|
|
@ -3294,7 +3294,7 @@ namespace Avalonia.Controls |
|
|
|
newCell.IsVisible = column.IsVisible; |
|
|
|
if (row.OwningGrid.CellTheme is {} cellTheme) |
|
|
|
{ |
|
|
|
newCell.SetValue(ThemeProperty, cellTheme, BindingPriority.TemplatedParent); |
|
|
|
newCell.SetValue(ThemeProperty, cellTheme, BindingPriority.Template); |
|
|
|
} |
|
|
|
} |
|
|
|
row.Cells.Insert(column.Index, newCell); |
|
|
|
|
|
|
|
@ -897,7 +897,7 @@ namespace Avalonia.Controls |
|
|
|
result[!ContentControl.ContentTemplateProperty] = this[!HeaderTemplateProperty]; |
|
|
|
if (OwningGrid.ColumnHeaderTheme is {} columnTheme) |
|
|
|
{ |
|
|
|
result.SetValue(StyledElement.ThemeProperty, columnTheme, BindingPriority.TemplatedParent); |
|
|
|
result.SetValue(StyledElement.ThemeProperty, columnTheme, BindingPriority.Template); |
|
|
|
} |
|
|
|
|
|
|
|
return result; |
|
|
|
|
|
|
|
@ -673,7 +673,7 @@ namespace Avalonia.Controls |
|
|
|
}; |
|
|
|
if (OwningGrid.ColumnHeaderTheme is {} columnHeaderTheme) |
|
|
|
{ |
|
|
|
dragIndicator.SetValue(ThemeProperty, columnHeaderTheme, BindingPriority.TemplatedParent); |
|
|
|
dragIndicator.SetValue(ThemeProperty, columnHeaderTheme, BindingPriority.Template); |
|
|
|
} |
|
|
|
|
|
|
|
dragIndicator.PseudoClasses.Add(":dragIndicator"); |
|
|
|
|
|
|
|
@ -253,7 +253,7 @@ namespace Avalonia.Controls |
|
|
|
}; |
|
|
|
if (OwningGrid.CellTheme is {} cellTheme) |
|
|
|
{ |
|
|
|
_fillerCell.SetValue(ThemeProperty, cellTheme, BindingPriority.TemplatedParent); |
|
|
|
_fillerCell.SetValue(ThemeProperty, cellTheme, BindingPriority.Template); |
|
|
|
} |
|
|
|
if (_cellsElement != null) |
|
|
|
{ |
|
|
|
|
|
|
|
@ -1029,7 +1029,7 @@ namespace Avalonia.Controls |
|
|
|
dataGridRow.DataContext = dataContext; |
|
|
|
if (RowTheme is {} rowTheme) |
|
|
|
{ |
|
|
|
dataGridRow.SetValue(ThemeProperty, rowTheme, BindingPriority.TemplatedParent); |
|
|
|
dataGridRow.SetValue(ThemeProperty, rowTheme, BindingPriority.Template); |
|
|
|
} |
|
|
|
CompleteCellsCollection(dataGridRow); |
|
|
|
|
|
|
|
@ -2743,7 +2743,7 @@ namespace Avalonia.Controls |
|
|
|
groupHeader.Level = rowGroupInfo.Level; |
|
|
|
if (RowGroupTheme is {} rowGroupTheme) |
|
|
|
{ |
|
|
|
groupHeader.SetValue(ThemeProperty, rowGroupTheme, BindingPriority.TemplatedParent); |
|
|
|
groupHeader.SetValue(ThemeProperty, rowGroupTheme, BindingPriority.Template); |
|
|
|
} |
|
|
|
|
|
|
|
// Set the RowGroupHeader's PropertyName. Unfortunately, CollectionViewGroup doesn't have this
|
|
|
|
|
|
|
|
@ -1,6 +1,5 @@ |
|
|
|
using System; |
|
|
|
using System.Collections.Generic; |
|
|
|
using System.ComponentModel; |
|
|
|
using Avalonia.Metadata; |
|
|
|
|
|
|
|
namespace Avalonia.Controls.ApplicationLifetimes |
|
|
|
@ -19,7 +18,7 @@ namespace Avalonia.Controls.ApplicationLifetimes |
|
|
|
|
|
|
|
/// <summary>
|
|
|
|
/// Gets the arguments passed to the
|
|
|
|
/// <see cref="ClassicDesktopStyleApplicationLifetimeExtensions.StartWithClassicDesktopLifetime{T}(T, string[], ShutdownMode)"/>
|
|
|
|
/// <see cref="ClassicDesktopStyleApplicationLifetimeExtensions.StartWithClassicDesktopLifetime(AppBuilder, string[], ShutdownMode)"/>
|
|
|
|
/// method.
|
|
|
|
/// </summary>
|
|
|
|
string[]? Args { get; } |
|
|
|
|
|
|
|
@ -50,7 +50,7 @@ class CompositionBorderVisual : CompositionDrawListVisual |
|
|
|
if (ClipToBounds) |
|
|
|
{ |
|
|
|
var clipRect = Root!.SnapToDevicePixels(new Rect(new Size(Size.X, Size.Y))); |
|
|
|
if (_cornerRadius.IsEmpty) |
|
|
|
if (_cornerRadius.IsDefault) |
|
|
|
canvas.PushClip(clipRect); |
|
|
|
else |
|
|
|
canvas.PushClip(new RoundedRect(clipRect, _cornerRadius)); |
|
|
|
@ -73,4 +73,4 @@ class CompositionBorderVisual : CompositionDrawListVisual |
|
|
|
protected override bool HandlesClipToBounds => true; |
|
|
|
} |
|
|
|
|
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
@ -13,4 +13,9 @@ |
|
|
|
<Import Project="..\..\build\DevAnalyzers.props" /> |
|
|
|
<Import Project="..\..\build\SourceGenerators.props" /> |
|
|
|
<Import Project="..\..\build\TrimmingEnable.props" /> |
|
|
|
|
|
|
|
<ItemGroup> |
|
|
|
<Compile Remove="..\Shared\SourceGeneratorAttributes.cs"/> |
|
|
|
<None Include="..\Shared\SourceGeneratorAttributes.cs" Visible="false"/> |
|
|
|
</ItemGroup> |
|
|
|
</Project> |
|
|
|
|
|
|
|
@ -2162,9 +2162,9 @@ |
|
|
|
"dev": true |
|
|
|
}, |
|
|
|
"node_modules/json5": { |
|
|
|
"version": "1.0.1", |
|
|
|
"resolved": "https://registry.npmjs.org/json5/-/json5-1.0.1.tgz", |
|
|
|
"integrity": "sha512-aKS4WQjPenRxiQsC93MNfjx+nbF4PAdYzmd/1JIj8HYzqfbu86beTuNgXDzPknWk0n0uARlyewZo4s++ES36Ow==", |
|
|
|
"version": "1.0.2", |
|
|
|
"resolved": "https://registry.npmjs.org/json5/-/json5-1.0.2.tgz", |
|
|
|
"integrity": "sha512-g1MWMLBiz8FKi1e4w0UyVL3w+iJceWAFBAaBnnGKOpNa5f8TLktkbre1+s6oICydWAm+HRUGTmI+//xv2hvXYA==", |
|
|
|
"dev": true, |
|
|
|
"dependencies": { |
|
|
|
"minimist": "^1.2.0" |
|
|
|
@ -4699,9 +4699,9 @@ |
|
|
|
"dev": true |
|
|
|
}, |
|
|
|
"json5": { |
|
|
|
"version": "1.0.1", |
|
|
|
"resolved": "https://registry.npmjs.org/json5/-/json5-1.0.1.tgz", |
|
|
|
"integrity": "sha512-aKS4WQjPenRxiQsC93MNfjx+nbF4PAdYzmd/1JIj8HYzqfbu86beTuNgXDzPknWk0n0uARlyewZo4s++ES36Ow==", |
|
|
|
"version": "1.0.2", |
|
|
|
"resolved": "https://registry.npmjs.org/json5/-/json5-1.0.2.tgz", |
|
|
|
"integrity": "sha512-g1MWMLBiz8FKi1e4w0UyVL3w+iJceWAFBAaBnnGKOpNa5f8TLktkbre1+s6oICydWAm+HRUGTmI+//xv2hvXYA==", |
|
|
|
"dev": true, |
|
|
|
"requires": { |
|
|
|
"minimist": "^1.2.0" |
|
|
|
|