private void OnHitsSubtracted(ResponseMessage r) { HitsSubtractedResponse response = (HitsSubtractedResponse)r; if (this.HitsSubtractedEvent != null) { this.HitsSubtractedEvent(response); } }
private void OnHitsSubtracted(HitsSubtractedResponse response) { foreach (Uri uri in response.Uris) { if (uri.Scheme != Uri.UriSchemeFile) continue; string path = uri.LocalPath; Track track = trackHash[path] as Track; if (track != null) { trackHash.Remove (path); db.RemoveTrack (track); } } }
private static void OnHitsSubtracted (HitsSubtractedResponse response) { lastQueryTime = DateTime.Now; if (! display_hits) return; foreach (Uri uri in response.Uris) { Console.WriteLine ("Subtracted Uri '{0}'", uri); Console.WriteLine (); --count; } }
private void OnHitsSubtracted (HitsSubtractedResponse response) { root.Subtract (response.Uris); UpdatePage (); }
private void OnHitsSubtracted (HitsSubtractedResponse response) { mutex.WaitOne (); List<uint> removed = new List<uint>(); Console.Error.WriteLine ("Removing some hits"); foreach (KeyValuePair<uint, Xesam.Hit> kvp in hits) { foreach (Uri uri in response.Uris) { if (kvp.Value.Uri == uri) { Console.Error.WriteLine ("-Hit: {0}", uri); removed.Add (kvp.Key); } } } foreach (uint key in removed) { hits.Remove (key); } if (HitsRemovedHandler != null) { HitsRemovedHandler (id, removed.ToArray ()); } mutex.ReleaseMutex (); }
private void OnHitsSubtracted (HitsSubtractedResponse response) { foreach (Uri uri in response.Uris) view.SubtractHit (uri); TotalMatches -= response.Uris.Count; CheckNoMatch (); }