Browse Source
Seems we weren't calling `ClearItemContainer` for `ItemIsOwnContainer` items in `PanelContainerGenerator`. Fixed that too.pull/10685/head
6 changed files with 240 additions and 2 deletions
@ -0,0 +1,20 @@ |
|||
using System; |
|||
|
|||
namespace Avalonia.Controls |
|||
{ |
|||
/// <summary>
|
|||
/// Provides data for the <see cref="ItemsControl.ContainerClearing"/> event.
|
|||
/// </summary>
|
|||
public class ContainerClearingEventArgs : EventArgs |
|||
{ |
|||
public ContainerClearingEventArgs(Control container) |
|||
{ |
|||
Container = container; |
|||
} |
|||
|
|||
/// <summary>
|
|||
/// Gets the prepared container.
|
|||
/// </summary>
|
|||
public Control Container { get; } |
|||
} |
|||
} |
|||
@ -0,0 +1,32 @@ |
|||
using System; |
|||
|
|||
namespace Avalonia.Controls |
|||
{ |
|||
/// <summary>
|
|||
/// Provides data for the <see cref="ItemsControl.ContainerIndexChanged"/> event.
|
|||
/// </summary>
|
|||
public class ContainerIndexChangedEventArgs : EventArgs |
|||
{ |
|||
public ContainerIndexChangedEventArgs(Control container, int oldIndex, int newIndex) |
|||
{ |
|||
Container = container; |
|||
OldIndex = oldIndex; |
|||
NewIndex = newIndex; |
|||
} |
|||
|
|||
/// <summary>
|
|||
/// Get the container for which the index changed.
|
|||
/// </summary>
|
|||
public Control Container { get; } |
|||
|
|||
/// <summary>
|
|||
/// Gets the index of the container after the change.
|
|||
/// </summary>
|
|||
public int NewIndex { get; } |
|||
|
|||
/// <summary>
|
|||
/// Gets the index of the container before the change.
|
|||
/// </summary>
|
|||
public int OldIndex { get; } |
|||
} |
|||
} |
|||
@ -0,0 +1,26 @@ |
|||
using System; |
|||
|
|||
namespace Avalonia.Controls |
|||
{ |
|||
/// <summary>
|
|||
/// Provides data for the <see cref="ItemsControl.ContainerPrepared"/> event.
|
|||
/// </summary>
|
|||
public class ContainerPreparedEventArgs : EventArgs |
|||
{ |
|||
public ContainerPreparedEventArgs(Control container, int index) |
|||
{ |
|||
Container = container; |
|||
Index = index; |
|||
} |
|||
|
|||
/// <summary>
|
|||
/// Gets the prepared container.
|
|||
/// </summary>
|
|||
public Control Container { get; } |
|||
|
|||
/// <summary>
|
|||
/// Gets the index of the item the container was prepared for.
|
|||
/// </summary>
|
|||
public int Index { get; } |
|||
} |
|||
} |
|||
Loading…
Reference in new issue