diff --git a/src/Avalonia.Controls/DateTimePickers/TimePickerPresenter.cs b/src/Avalonia.Controls/DateTimePickers/TimePickerPresenter.cs index 082117ac6bd..9970efb9005 100644 --- a/src/Avalonia.Controls/DateTimePickers/TimePickerPresenter.cs +++ b/src/Avalonia.Controls/DateTimePickers/TimePickerPresenter.cs @@ -28,7 +28,6 @@ namespace Avalonia.Controls [TemplatePart("PART_PeriodSelector", typeof(DateTimePickerPanel), IsRequired = true)] [TemplatePart("PART_PeriodUpButton", typeof(RepeatButton))] [TemplatePart("PART_PickerContainer", typeof(Grid), IsRequired = true)] - [TemplatePart("PART_FirstSpacer", typeof(Rectangle), IsRequired = true)] [TemplatePart("PART_SecondSpacer", typeof(Rectangle), IsRequired = true)] [TemplatePart("PART_ThirdSpacer", typeof(Rectangle), IsRequired = true)] public class TimePickerPresenter : PickerPresenterBase diff --git a/tests/Avalonia.Controls.UnitTests/TimePickerTests.cs b/tests/Avalonia.Controls.UnitTests/TimePickerTests.cs index 221889eb10f..fdef8933205 100644 --- a/tests/Avalonia.Controls.UnitTests/TimePickerTests.cs +++ b/tests/Avalonia.Controls.UnitTests/TimePickerTests.cs @@ -433,11 +433,6 @@ private static IControlTemplate CreatePickerTemplate() Name = "PART_PickerContainer" }.RegisterInNameScope(scope); - var firstSpacer = new Rectangle - { - Name = "PART_FirstSpacer" - }.RegisterInNameScope(scope); - var secondSpacer = new Rectangle { Name = "PART_SecondSpacer" @@ -449,7 +444,7 @@ private static IControlTemplate CreatePickerTemplate() }.RegisterInNameScope(scope); var contentPanel = new StackPanel(); - contentPanel.Children.AddRange(new Control[] { acceptButton, hourSelector, minuteSelector, secondHost, secondSelector, periodHost, periodSelector, pickerContainer, firstSpacer, secondSpacer, thirdSpacer }); + contentPanel.Children.AddRange(new Control[] { acceptButton, hourSelector, minuteSelector, secondHost, secondSelector, periodHost, periodSelector, pickerContainer, secondSpacer, thirdSpacer }); return contentPanel; }); }