From: Bellai Ádám Date: Fri, 13 Oct 2017 12:21:52 +0000 (+0000) Subject: git-tfs-id: [http://tfs.userrendszerhaz.hu:8080/tfs/DefaultCollection]$/MediaCube... X-Git-Url: http://git.useribm.hu/?a=commitdiff_plain;h=3861343889ab0d503f6df82b6d08534aab424f7c;p=mediacube.git git-tfs-id: [tfs.userrendszerhaz.hu:8080/tfs/DefaultCollection]$/MediaCube;C30616 --- diff --git a/client/Maestro/Sources/NexioRESTSource.cs b/client/Maestro/Sources/NexioRESTSource.cs index 24df6c35..68b22ecb 100644 --- a/client/Maestro/Sources/NexioRESTSource.cs +++ b/client/Maestro/Sources/NexioRESTSource.cs @@ -29,7 +29,6 @@ namespace Maestro.Sources { private Control parent; private NexioAPI dataClient; private string filter; - private Object lockObject = new Object(); public DataGridViewColumn[] Columns { get { @@ -69,8 +68,7 @@ namespace Maestro.Sources { cache.AddRange(this); filter = value; Clear(); - lock (lockObject) - cache.Where(i => i.Name.ToLower().Contains(filter.ToLower())).ToList().ForEach(i => Add(i)); + cache.Where(i => i.Name.ToLower().Contains(filter.ToLower())).ToList().ForEach(i => Add(i)); } } @@ -119,21 +117,20 @@ namespace Maestro.Sources { return; JToken d = JToken.Parse(jToken.ToString()); string action = resultObject.GetValue(NexioAPI.ACTION).ToString(); - lock (lockObject) - switch (action) { - case NexioAPI.LIST: - OnList(d); - break; - case NexioAPI.CREATE: - OnCreated(d); - break; - case NexioAPI.DELETE: - OnDeleted(d); - break; - case NexioAPI.UPDATE: - OnChanged(d); - break; - } + switch (action) { + case NexioAPI.LIST: + OnList(d); + break; + case NexioAPI.CREATE: + OnCreated(d); + break; + case NexioAPI.DELETE: + OnDeleted(d); + break; + case NexioAPI.UPDATE: + OnChanged(d); + break; + } } //private void AddItem(JToken token, Boolean highlight) {