Issue #87: Added event QuoteUpdate to MtApi5Client (MT5) for compatibility with MATLAB

This commit is contained in:
vdemydiuk
2018-02-19 11:49:52 +02:00
parent bdb30edee3
commit 3a4f561836
2 changed files with 6 additions and 10 deletions
+2 -1
View File
@@ -6,7 +6,6 @@ using MTApiService;
using System.Collections;
using System.ServiceModel;
using MtApi5.Requests;
using MtApi5.Responses;
using Newtonsoft.Json;
using System.Threading.Tasks;
@@ -2293,6 +2292,7 @@ namespace MtApi5
#region Events
public event QuoteHandler QuoteUpdated;
public event EventHandler<Mt5QuoteEventArgs> QuoteUpdate;
public event EventHandler<Mt5QuoteEventArgs> QuoteAdded;
public event EventHandler<Mt5QuoteEventArgs> QuoteRemoved;
public event EventHandler<Mt5ConnectionEventArgs> ConnectionStateChanged;
@@ -2476,6 +2476,7 @@ namespace MtApi5
{
if (quote != null)
{
QuoteUpdate?.Invoke(this, new Mt5QuoteEventArgs(new Mt5Quote(quote.Instrument, quote.Bid, quote.Ask)));
QuoteUpdated?.Invoke(this, quote.Instrument, quote.Bid, quote.Ask);
}
}