File tree Expand file tree Collapse file tree 2 files changed +8
-9
lines changed
CodeBeam.MudBlazor.Extensions/Components Expand file tree Collapse file tree 2 files changed +8
-9
lines changed Original file line number Diff line number Diff line change @@ -1653,7 +1653,7 @@ protected internal ValueTask ScrollToMiddleAsync(MudListItemExtended<T?>? item)
16531653 ///
16541654 /// </summary>
16551655 /// <returns></returns>
1656- protected ICollection < T ? > ? GetSearchedItems ( )
1656+ protected internal ICollection < T ? > ? GetSearchedItems ( )
16571657 {
16581658 if ( ! SearchBox || ItemCollection == null || _searchString == null )
16591659 {
Original file line number Diff line number Diff line change @@ -340,24 +340,23 @@ protected internal async Task TransferAll(bool startToEnd = true)
340340 }
341341 if ( startToEnd == true )
342342 {
343- foreach ( var item in StartCollection )
343+
344+ foreach ( var item in _startList . GetSearchedItems ( ) ?? [ ] )
344345 {
345- EndCollection . Add ( item ) ;
346+ EndCollection ? . Add ( item ) ;
347+ StartCollection ? . Remove ( item ) ;
346348 }
347- StartCollection . Clear ( ) ;
348- _startList . Clear ( ) ;
349349 OrderItems ( ) ;
350350 await EndCollectionChanged . InvokeAsync ( EndCollection ) ;
351351 await StartCollectionChanged . InvokeAsync ( StartCollection ) ;
352352 }
353353 else if ( startToEnd == false )
354354 {
355- foreach ( var item in EndCollection )
355+ foreach ( var item in _endList . GetSearchedItems ( ) ?? [ ] )
356356 {
357- StartCollection . Add ( item ) ;
357+ StartCollection ? . Add ( item ) ;
358+ EndCollection ? . Remove ( item ) ;
358359 }
359- EndCollection . Clear ( ) ;
360- _endList . Clear ( ) ;
361360 OrderItems ( ) ;
362361 await StartCollectionChanged . InvokeAsync ( StartCollection ) ;
363362 await EndCollectionChanged . InvokeAsync ( EndCollection ) ;
You can’t perform that action at this time.
0 commit comments