Skip to content
Merged
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
2 changes: 1 addition & 1 deletion Directory.Packages.props
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<Project>
<PropertyGroup>
<ManagePackageVersionsCentrally>true</ManagePackageVersionsCentrally>
<AvaloniaVersion>11.2.1</AvaloniaVersion>
<AvaloniaVersion>11.3.0</AvaloniaVersion>
</PropertyGroup>
<ItemGroup>
<PackageVersion Include="Avalonia" Version="$(AvaloniaVersion)" />
Expand Down
22 changes: 22 additions & 0 deletions src/Blazonia/generated/DockPanel.generated.cs
Original file line number Diff line number Diff line change
Expand Up @@ -26,10 +26,18 @@ static DockPanel()
RegisterAdditionalHandlers();
}

/// <summary>
/// Gets or sets the horizontal distance between the child objects.
/// </summary>
[Parameter] public double? HorizontalSpacing { get; set; }
/// <summary>
/// Gets or sets a value which indicates whether the last child of the <see cref="T:Avalonia.Controls.DockPanel" /> fills the remaining space in the panel.
/// </summary>
[Parameter] public bool? LastChildFill { get; set; }
/// <summary>
/// Gets or sets the vertical distance between the child objects.
/// </summary>
[Parameter] public double? VerticalSpacing { get; set; }

public new AC.DockPanel NativeControl => (AC.DockPanel)((AvaloniaObject)this).NativeControl;

Expand All @@ -39,13 +47,27 @@ protected override void HandleParameter(string name, object value)
{
switch (name)
{
case nameof(HorizontalSpacing):
if (!Equals(HorizontalSpacing, value))
{
HorizontalSpacing = (double?)value;
NativeControl.HorizontalSpacing = HorizontalSpacing ?? (double)AC.DockPanel.HorizontalSpacingProperty.GetDefaultValue(AC.DockPanel.HorizontalSpacingProperty.OwnerType);
}
break;
case nameof(LastChildFill):
if (!Equals(LastChildFill, value))
{
LastChildFill = (bool?)value;
NativeControl.LastChildFill = LastChildFill ?? (bool)AC.DockPanel.LastChildFillProperty.GetDefaultValue(AC.DockPanel.LastChildFillProperty.OwnerType);
}
break;
case nameof(VerticalSpacing):
if (!Equals(VerticalSpacing, value))
{
VerticalSpacing = (double?)value;
NativeControl.VerticalSpacing = VerticalSpacing ?? (double)AC.DockPanel.VerticalSpacingProperty.GetDefaultValue(AC.DockPanel.VerticalSpacingProperty.OwnerType);
}
break;

default:
base.HandleParameter(name, value);
Expand Down
22 changes: 22 additions & 0 deletions src/Blazonia/generated/Grid.generated.cs
Original file line number Diff line number Diff line change
Expand Up @@ -31,10 +31,18 @@ static Grid()
/// </summary>
[Parameter] public OneOf.OneOf<AC.ColumnDefinitions, string> ColumnDefinitions { get; set; }
/// <summary>
/// Gets or sets the size of the spacing to place between grid columns.
/// </summary>
[Parameter] public double? ColumnSpacing { get; set; }
/// <summary>
/// Returns a RowDefinitions of row definitions.
/// </summary>
[Parameter] public OneOf.OneOf<AC.RowDefinitions, string> RowDefinitions { get; set; }
/// <summary>
/// Gets or sets the size of the spacing to place between grid rows.
/// </summary>
[Parameter] public double? RowSpacing { get; set; }
/// <summary>
/// ShowGridLines property.
/// </summary>
[Parameter] public bool? ShowGridLines { get; set; }
Expand All @@ -61,6 +69,13 @@ protected override void HandleParameter(string name, object value)
}
}
break;
case nameof(ColumnSpacing):
if (!Equals(ColumnSpacing, value))
{
ColumnSpacing = (double?)value;
NativeControl.ColumnSpacing = ColumnSpacing ?? (double)AC.Grid.ColumnSpacingProperty.GetDefaultValue(AC.Grid.ColumnSpacingProperty.OwnerType);
}
break;
case nameof(RowDefinitions):
if (!Equals(RowDefinitions, value))
{
Expand All @@ -75,6 +90,13 @@ protected override void HandleParameter(string name, object value)
}
}
break;
case nameof(RowSpacing):
if (!Equals(RowSpacing, value))
{
RowSpacing = (double?)value;
NativeControl.RowSpacing = RowSpacing ?? (double)AC.Grid.RowSpacingProperty.GetDefaultValue(AC.Grid.RowSpacingProperty.OwnerType);
}
break;
case nameof(ShowGridLines):
if (!Equals(ShowGridLines, value))
{
Expand Down
11 changes: 11 additions & 0 deletions src/Blazonia/generated/Image.generated.cs
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,10 @@ static Image()
RegisterAdditionalHandlers();
}

/// <summary>
/// Gets or sets the blend mode for the image.
/// </summary>
[Parameter] public global::Avalonia.Media.Imaging.BitmapBlendingMode? BlendMode { get; set; }
/// <summary>
/// Gets or sets the image that will be displayed.
/// </summary>
Expand All @@ -47,6 +51,13 @@ protected override void HandleParameter(string name, object value)
{
switch (name)
{
case nameof(BlendMode):
if (!Equals(BlendMode, value))
{
BlendMode = (global::Avalonia.Media.Imaging.BitmapBlendingMode?)value;
NativeControl.BlendMode = BlendMode ?? (global::Avalonia.Media.Imaging.BitmapBlendingMode)AC.Image.BlendModeProperty.GetDefaultValue(AC.Image.BlendModeProperty.OwnerType);
}
break;
case nameof(Source):
if (!Equals(Source, value))
{
Expand Down
11 changes: 11 additions & 0 deletions src/Blazonia/generated/ItemsControl.generated.cs
Original file line number Diff line number Diff line change
Expand Up @@ -47,6 +47,7 @@ static ItemsControl()
/// Gets or sets the data template used to display the items in the control.
/// </summary>
[Parameter] public RenderFragment<T> ItemTemplate { get; set; }
[Parameter] public EventCallback<AC.ContainerPreparedEventArgs> OnPreparingContainer { get; set; }
[Parameter] public EventCallback<AC.ContainerPreparedEventArgs> OnContainerPrepared { get; set; }
[Parameter] public EventCallback<AC.ContainerIndexChangedEventArgs> OnContainerIndexChanged { get; set; }
[Parameter] public EventCallback<AC.ContainerClearingEventArgs> OnContainerClearing { get; set; }
Expand Down Expand Up @@ -90,6 +91,16 @@ protected override void HandleParameter(string name, object value)
case nameof(ItemTemplate):
ItemTemplate = (RenderFragment<T>)value;
break;
case nameof(OnPreparingContainer):
if (!Equals(OnPreparingContainer, value))
{
void NativeControlPreparingContainer(object sender, AC.ContainerPreparedEventArgs e) => InvokeEventCallback(OnPreparingContainer, e);

OnPreparingContainer = (EventCallback<AC.ContainerPreparedEventArgs>)value;
NativeControl.PreparingContainer -= NativeControlPreparingContainer;
NativeControl.PreparingContainer += NativeControlPreparingContainer;
}
break;
case nameof(OnContainerPrepared):
if (!Equals(OnContainerPrepared, value))
{
Expand Down
11 changes: 11 additions & 0 deletions src/Blazonia/generated/Primitives/Popup.generated.cs
Original file line number Diff line number Diff line change
Expand Up @@ -89,6 +89,10 @@ static Popup()
/// </summary>
[Parameter] public AC.Control PlacementTarget { get; set; }
/// <summary>
/// Gets or sets a value that indicates whether the popup should be shown in the overlay layer of the parent window.
/// </summary>
[Parameter] public bool? ShouldUseOverlayLayer { get; set; }
/// <summary>
/// Gets or sets a value indicating whether the popup, on show, transfers focus from any focused native control to Avalonia. The default is <c>true</c>.
/// </summary>
[Parameter] public bool? TakesFocusFromNativeControl { get; set; }
Expand Down Expand Up @@ -220,6 +224,13 @@ protected override void HandleParameter(string name, object value)
NativeControl.PlacementTarget = PlacementTarget;
}
break;
case nameof(ShouldUseOverlayLayer):
if (!Equals(ShouldUseOverlayLayer, value))
{
ShouldUseOverlayLayer = (bool?)value;
NativeControl.ShouldUseOverlayLayer = ShouldUseOverlayLayer ?? (bool)ACP.Popup.ShouldUseOverlayLayerProperty.GetDefaultValue(ACP.Popup.ShouldUseOverlayLayerProperty.OwnerType);
}
break;
case nameof(TakesFocusFromNativeControl):
if (!Equals(TakesFocusFromNativeControl, value))
{
Expand Down
22 changes: 22 additions & 0 deletions src/Blazonia/generated/Primitives/UniformGrid.generated.cs
Original file line number Diff line number Diff line change
Expand Up @@ -33,13 +33,21 @@ static UniformGrid()
/// </summary>
[Parameter] public int? Columns { get; set; }
/// <summary>
/// Specifies the spacing between columns.
/// </summary>
[Parameter] public double? ColumnSpacing { get; set; }
/// <summary>
/// Specifies, for the first row, the column where the items should start.
/// </summary>
[Parameter] public int? FirstColumn { get; set; }
/// <summary>
/// Specifies the row count. If set to 0, row count will be calculated automatically.
/// </summary>
[Parameter] public int? Rows { get; set; }
/// <summary>
/// Specifies the spacing between rows.
/// </summary>
[Parameter] public double? RowSpacing { get; set; }

public new ACP.UniformGrid NativeControl => (ACP.UniformGrid)((AvaloniaObject)this).NativeControl;

Expand All @@ -56,6 +64,13 @@ protected override void HandleParameter(string name, object value)
NativeControl.Columns = Columns ?? (int)ACP.UniformGrid.ColumnsProperty.GetDefaultValue(ACP.UniformGrid.ColumnsProperty.OwnerType);
}
break;
case nameof(ColumnSpacing):
if (!Equals(ColumnSpacing, value))
{
ColumnSpacing = (double?)value;
NativeControl.ColumnSpacing = ColumnSpacing ?? (double)ACP.UniformGrid.ColumnSpacingProperty.GetDefaultValue(ACP.UniformGrid.ColumnSpacingProperty.OwnerType);
}
break;
case nameof(FirstColumn):
if (!Equals(FirstColumn, value))
{
Expand All @@ -70,6 +85,13 @@ protected override void HandleParameter(string name, object value)
NativeControl.Rows = Rows ?? (int)ACP.UniformGrid.RowsProperty.GetDefaultValue(ACP.UniformGrid.RowsProperty.OwnerType);
}
break;
case nameof(RowSpacing):
if (!Equals(RowSpacing, value))
{
RowSpacing = (double?)value;
NativeControl.RowSpacing = RowSpacing ?? (double)ACP.UniformGrid.RowSpacingProperty.GetDefaultValue(ACP.UniformGrid.RowSpacingProperty.OwnerType);
}
break;

default:
base.HandleParameter(name, value);
Expand Down
35 changes: 34 additions & 1 deletion src/Blazonia/generated/WrapPanel.generated.cs
Original file line number Diff line number Diff line change
Expand Up @@ -31,11 +31,23 @@ static WrapPanel()
/// </summary>
[Parameter] public double? ItemHeight { get; set; }
/// <summary>
/// Gets or sets the alignment of items in the WrapPanel.
/// </summary>
[Parameter] public AC.WrapPanelItemsAlignment? ItemsAlignment { get; set; }
/// <summary>
/// Gets or sets the spacing between lines.
/// </summary>
[Parameter] public double? ItemSpacing { get; set; }
/// <summary>
/// Gets or sets the width of all items in the WrapPanel.
/// </summary>
[Parameter] public double? ItemWidth { get; set; }
/// <summary>
/// Gets or sets the orientation in which child controls will be layed out.
/// Gets or sets the spacing between items.
/// </summary>
[Parameter] public double? LineSpacing { get; set; }
/// <summary>
/// Gets or sets the orientation in which child controls will be laid out.
/// </summary>
[Parameter] public global::Avalonia.Layout.Orientation? Orientation { get; set; }

Expand All @@ -54,13 +66,34 @@ protected override void HandleParameter(string name, object value)
NativeControl.ItemHeight = ItemHeight ?? (double)AC.WrapPanel.ItemHeightProperty.GetDefaultValue(AC.WrapPanel.ItemHeightProperty.OwnerType);
}
break;
case nameof(ItemsAlignment):
if (!Equals(ItemsAlignment, value))
{
ItemsAlignment = (AC.WrapPanelItemsAlignment?)value;
NativeControl.ItemsAlignment = ItemsAlignment ?? (AC.WrapPanelItemsAlignment)AC.WrapPanel.ItemsAlignmentProperty.GetDefaultValue(AC.WrapPanel.ItemsAlignmentProperty.OwnerType);
}
break;
case nameof(ItemSpacing):
if (!Equals(ItemSpacing, value))
{
ItemSpacing = (double?)value;
NativeControl.ItemSpacing = ItemSpacing ?? (double)AC.WrapPanel.ItemSpacingProperty.GetDefaultValue(AC.WrapPanel.ItemSpacingProperty.OwnerType);
}
break;
case nameof(ItemWidth):
if (!Equals(ItemWidth, value))
{
ItemWidth = (double?)value;
NativeControl.ItemWidth = ItemWidth ?? (double)AC.WrapPanel.ItemWidthProperty.GetDefaultValue(AC.WrapPanel.ItemWidthProperty.OwnerType);
}
break;
case nameof(LineSpacing):
if (!Equals(LineSpacing, value))
{
LineSpacing = (double?)value;
NativeControl.LineSpacing = LineSpacing ?? (double)AC.WrapPanel.LineSpacingProperty.GetDefaultValue(AC.WrapPanel.LineSpacingProperty.OwnerType);
}
break;
case nameof(Orientation):
if (!Equals(Orientation, value))
{
Expand Down