From 3653caed0a2db54bd05b65c5bfb0cc3d52e5d7c4 Mon Sep 17 00:00:00 2001 From: Proudust Date: Sat, 17 Dec 2022 14:16:10 +0900 Subject: [PATCH] Update README.md --- README.md | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/README.md b/README.md index 1e756ad..f0f9686 100644 --- a/README.md +++ b/README.md @@ -174,7 +174,7 @@ public partial class DataTable : ComponentBase, IDisposable WPF --- -Because of data binding in WPF, it is important that the collection is Observable. ObservableCollections high-performance `IObservableCollection` cannot be bind to WPF. Call `WithtINotifyCollectionChanged` to convert it to `INotifyCollectionChanged`. Also, although ObservableCollections and Views are thread-safe, the WPF UI does not support change notifications from different threads. `BindingOperations.EnableCollectionSynchronization` to work safely with change notifications from different threads. +Because of data binding in WPF, it is important that the collection is Observable. ObservableCollections high-performance `IObservableCollection` cannot be bind to WPF. Call `WithINotifyCollectionChanged` to convert it to `INotifyCollectionChanged`. Also, although ObservableCollections and Views are thread-safe, the WPF UI does not support change notifications from different threads. `BindingOperations.EnableCollectionSynchronization` to work safely with change notifications from different threads. ```csharp // WPF simple sample. @@ -199,7 +199,7 @@ protected override void OnClosed(EventArgs e) } ``` -> WPF can not use SoretedView beacuse SortedView can not provide sort event to INotifyCollectionChanged. +> WPF can not use SortedView because SortedView can not provide sort event to INotifyCollectionChanged. Unity --- @@ -274,7 +274,7 @@ public class SampleScript : MonoBehaviour It is also possible to manage Order by managing indexes inserted from eventArgs, but it is very difficult with many caveats. If you don't have major performance issues, you can foreach the View itself on CollectionStateChanged (like Blazor) and reorder the transforms. If you have such a architecture, you can also use SortedView. -View/SoretedView +View/SortedView --- View can create from `IObservableCollection`, it completely synchronized and thread-safe. @@ -312,7 +312,7 @@ see [filter](#filter) section. ```csharp var view = transform(value); -If (filter.IsMatch(value, view)) +if (filter.IsMatch(value, view)) { filter.WhenTrue(value, view); } @@ -338,7 +338,7 @@ public static ISynchronizedView CreateSortedView Notice: foreach ObservableCollections and Views are thread-safe but it uses lock at iterating. In other words, the obtained Enumerator must be Dispose. foreach and LINQ are guaranteed to be Dipose, but be careful when you extract the Enumerator by yourself. +> Notice: foreach ObservableCollections and Views are thread-safe but it uses lock at iterating. In other words, the obtained Enumerator must be Dispose. foreach and LINQ are guaranteed to be Dispose, but be careful when you extract the Enumerator by yourself. Filter --- @@ -403,4 +403,4 @@ public static void Sort(this ISortableSynchronizedView