File tree Expand file tree Collapse file tree 1 file changed +11
-3
lines changed Expand file tree Collapse file tree 1 file changed +11
-3
lines changed Original file line number Diff line number Diff line change 1
- using CommunityToolkit . WinUI ;
2
1
using Microsoft . UI ;
3
2
using Microsoft . UI . Xaml ;
4
3
using Microsoft . UI . Xaml . Controls ;
5
4
using Microsoft . UI . Xaml . Data ;
5
+ using Microsoft . UI . Xaml . Input ;
6
6
using Microsoft . UI . Xaml . Media ;
7
7
using Microsoft . UI . Xaml . Shapes ;
8
8
using System ;
@@ -62,7 +62,7 @@ protected override void OnApplyTemplate()
62
62
63
63
if ( GetTemplateChild ( "selectAllButton" ) is Button selectAllButton )
64
64
{
65
- selectAllButton . Tapped += delegate { TableView . SelectAllSafe ( ) ; } ;
65
+ selectAllButton . Tapped += OnSelectAllButtonClicked ;
66
66
}
67
67
68
68
if ( _selectAllCheckBox is not null )
@@ -375,12 +375,20 @@ private void SetSelectAllButtonState()
375
375
}
376
376
}
377
377
378
+ /// <summary>
379
+ /// Handles the SelectAllButton clicked event.
380
+ /// </summary>
381
+ private void OnSelectAllButtonClicked ( object sender , TappedRoutedEventArgs e )
382
+ {
383
+ TableView ? . SelectAll ( ) ;
384
+ }
385
+
378
386
/// <summary>
379
387
/// Handles the Checked event for the select all checkbox.
380
388
/// </summary>
381
389
private void OnSelectAllCheckBoxChecked ( object sender , RoutedEventArgs e )
382
390
{
383
- TableView ? . SelectAllSafe ( ) ;
391
+ TableView ? . SelectAll ( ) ;
384
392
}
385
393
386
394
/// <summary>
You can’t perform that action at this time.
0 commit comments