Browse Source

Merge pull request #8284 from MarchingCube/fix-calendaritem-pooledlist

Fix missing PooledList usage in CalendarItem.
pull/8291/head
Dariusz Komosiński 4 years ago
committed by GitHub
parent
commit
2aba5ac40a
No known key found for this signature in database GPG Key ID: 4AEE18F83AFDEB23
  1. 2
      src/Avalonia.Controls/Calendar/CalendarItem.cs

2
src/Avalonia.Controls/Calendar/CalendarItem.cs

@ -218,7 +218,7 @@ namespace Avalonia.Controls.Primitives
if (YearView != null)
{
var childCount = Calendar.RowsPerYear * Calendar.ColumnsPerYear;
var children = new List<IControl>(childCount);
using var children = new PooledList<IControl>(childCount);
EventHandler<PointerPressedEventArgs> monthCalendarButtonMouseDown = Month_CalendarButtonMouseDown;
EventHandler<PointerReleasedEventArgs> monthCalendarButtonMouseUp = Month_CalendarButtonMouseUp;

Loading…
Cancel
Save