Browse Source
Merge pull request #4545 from maxkatz6/fixes/fix-datagrid-pointer-events
Fix datagrid columns sort/resize/reorder
debug/skia-sharp-vmem
danwalmsley
6 years ago
committed by
GitHub
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
3 changed files with
3 additions and
3 deletions
-
src/Avalonia.Controls.DataGrid/DataGridColumnHeader.cs
-
src/Avalonia.Controls.DataGrid/DataGridRow.cs
-
src/Avalonia.Controls.DataGrid/DataGridRowHeader.cs
|
|
|
@ -457,7 +457,7 @@ namespace Avalonia.Controls |
|
|
|
|
|
|
|
private void DataGridColumnHeader_PointerPressed(object sender, PointerPressedEventArgs e) |
|
|
|
{ |
|
|
|
if (OwningColumn == null || e.Handled || !IsEnabled || e.GetCurrentPoint(this).Properties.IsLeftButtonPressed) |
|
|
|
if (OwningColumn == null || e.Handled || !IsEnabled || !e.GetCurrentPoint(this).Properties.IsLeftButtonPressed) |
|
|
|
{ |
|
|
|
return; |
|
|
|
} |
|
|
|
|
|
|
|
@ -789,7 +789,7 @@ namespace Avalonia.Controls |
|
|
|
|
|
|
|
private void DataGridRow_PointerPressed(PointerPressedEventArgs e) |
|
|
|
{ |
|
|
|
if (e.GetCurrentPoint(this).Properties.IsLeftButtonPressed) |
|
|
|
if (!e.GetCurrentPoint(this).Properties.IsLeftButtonPressed) |
|
|
|
{ |
|
|
|
return; |
|
|
|
} |
|
|
|
|
|
|
|
@ -162,7 +162,7 @@ namespace Avalonia.Controls.Primitives |
|
|
|
//TODO TabStop
|
|
|
|
private void DataGridRowHeader_PointerPressed(object sender, PointerPressedEventArgs e) |
|
|
|
{ |
|
|
|
if (e.GetCurrentPoint(this).Properties.IsLeftButtonPressed) |
|
|
|
if (!e.GetCurrentPoint(this).Properties.IsLeftButtonPressed) |
|
|
|
{ |
|
|
|
return; |
|
|
|
} |
|
|
|
|