Esempio n. 1
0
 public static void InvokeStateHasChanged(this WeakRefCollection <ComponentBase> components)
 {
     components.ForEach(component =>
     {
         var handleEvent = component as IHandleEvent;
         handleEvent?.HandleEventAsync(EventCallbackWorkItem.Empty, null);
     });
 }
Esempio n. 2
0
        public static void InvokeStateHasChanged(this WeakRefCollection <ComponentBase> components)
        {
            var stateHasChangedMethod = typeof(ComponentBase).GetMethod("StateHasChanged", BindingFlags.NonPublic | BindingFlags.Instance);

            components.ForEach(component =>
            {
                stateHasChangedMethod.Invoke(component, new object[] { });
            });
        }