コード例 #1
0
ファイル: JSArray.cs プロジェクト: jmecosta/Neutronium
        public void UpdateEventArgsFromJavascript(Neutronium.Core.Binding.CollectionChanges.CollectionChanges iCollectionChanges)
        {
            var ilist = CValue as IList;

            if (ilist == null)
            {
                return;
            }

            iCollectionChanges.IndividualChanges.ForEach(c => ReplayChanges(c, ilist));
        }
コード例 #2
0
 private void UpdateCollection(JsArray array, object collection, CollectionChanges.CollectionChanges change, BridgeUpdater updater)
 {
     try
     {
         using (_ListenerRegister.GetColllectionSilenter(collection))
         {
             array.UpdateEventArgsFromJavascript(change, updater);
         }
         updater.CleanAfterChangesOnUiThread(_ListenerRegister.Off);
     }
     catch (Exception exception)
     {
         LogJavascriptSetException(exception);
     }
 }
コード例 #3
0
 private void UpdateCollection(JSArray array, object collection, CollectionChanges.CollectionChanges change, BridgeUpdater updater)
 {
     try
     {
         using (ReListen(updater))
             using (_ListenerRegister.GetColllectionSilenter(collection))
             {
                 array.UpdateEventArgsFromJavascript(change);
             }
     }
     catch (Exception e)
     {
         _Logger.Error(() => $"Unable to update ViewModel from View, exception raised: {e.Message}");
     }
 }