Browse Source

Renamed PositionChangedEventArgs to PointEventArgs

pull/683/head
OronDF343 10 years ago
parent
commit
1071dc079c
  1. 2
      src/Avalonia.Controls/Avalonia.Controls.csproj
  2. 8
      src/Avalonia.Controls/PointEventArgs.cs
  3. 4
      src/Avalonia.Controls/TopLevel.cs

2
src/Avalonia.Controls/Avalonia.Controls.csproj

@ -56,7 +56,7 @@
<Compile Include="HotkeyManager.cs" />
<Compile Include="IApplicationLifecycle.cs" />
<Compile Include="IScrollable.cs" />
<Compile Include="PositionChangedEventArgs.cs" />
<Compile Include="PointEventArgs.cs" />
<Compile Include="WindowIcon.cs" />
<Compile Include="IPseudoClasses.cs" />
<Compile Include="DropDownItem.cs" />

8
src/Avalonia.Controls/PositionChangedEventArgs.cs → src/Avalonia.Controls/PointEventArgs.cs

@ -6,15 +6,15 @@ using System;
namespace Avalonia.Controls
{
/// <summary>
/// Provides data for the <see cref="TopLevel.PositionChanged"/> event.
/// Provides <see cref="Point"/> data for events.
/// </summary>
public class PositionChangedEventArgs : EventArgs
public class PointEventArgs : EventArgs
{
/// <summary>
/// Initializes a new instance of the <see cref="PositionChangedEventArgs"/> class.
/// Initializes a new instance of the <see cref="PointEventArgs"/> class.
/// </summary>
/// <param name="newPos">The new window position.</param>
public PositionChangedEventArgs(Point newPos)
public PointEventArgs(Point newPos)
{
NewPosition = newPos;
}

4
src/Avalonia.Controls/TopLevel.cs

@ -142,7 +142,7 @@ namespace Avalonia.Controls
/// <summary>
/// Fired when the window position is changed.
/// </summary>
public event EventHandler<PositionChangedEventArgs> PositionChanged;
public event EventHandler<PointEventArgs> PositionChanged;
/// <summary>
/// Gets or sets the client size of the window.
@ -408,7 +408,7 @@ namespace Avalonia.Controls
/// <param name="pos">The window position.</param>
private void HandlePositionChanged(Point pos)
{
PositionChanged?.Invoke(this, new PositionChangedEventArgs(pos));
PositionChanged?.Invoke(this, new PointEventArgs(pos));
}
/// <summary>

Loading…
Cancel
Save