last ...
This commit is contained in:
@@ -5017,6 +5017,39 @@ public:
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
//
|
||||||
|
void RemoveSignal(XSignal &signal)
|
||||||
|
{
|
||||||
|
//
|
||||||
|
if (!signal.IsValid())
|
||||||
|
{
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
|
//
|
||||||
|
int signalIDX = -1;
|
||||||
|
ENUM_X_POSITION_TYPES xType = ToPositionType(signal.type);
|
||||||
|
bool hasSignal = HasItem(
|
||||||
|
signal.symbol,
|
||||||
|
signal.provider,
|
||||||
|
signal.period,
|
||||||
|
xType,
|
||||||
|
signalIDX //
|
||||||
|
);
|
||||||
|
if (!hasSignal || !IsValidIndex(signalIDX))
|
||||||
|
{
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
|
//
|
||||||
|
// Remove Item From List ...
|
||||||
|
ArrayRemove(
|
||||||
|
mData,
|
||||||
|
signalIDX,
|
||||||
|
1 //
|
||||||
|
);
|
||||||
|
}
|
||||||
|
|
||||||
//
|
//
|
||||||
// Do all Protections ...
|
// Do all Protections ...
|
||||||
void HandleProtection()
|
void HandleProtection()
|
||||||
|
|||||||
@@ -636,11 +636,11 @@ bool InitialEA()
|
|||||||
eaR2R, // R2R ...
|
eaR2R, // R2R ...
|
||||||
eaSlippage,
|
eaSlippage,
|
||||||
eaMagicNumber,
|
eaMagicNumber,
|
||||||
true, // Ignore Signal Execution
|
true, // Ignore Signal Execution
|
||||||
true, // Use TP SL Point
|
eaUseFixedTPSLPoints, // Use TP SL Point
|
||||||
false, // Use Max
|
false, // Use Max
|
||||||
eaTPPoint, // TP
|
eaTPPoint, // TP
|
||||||
eaSLPoint, // SL
|
eaSLPoint, // SL
|
||||||
eaIgnoreTP,
|
eaIgnoreTP,
|
||||||
eaIgnoreSL,
|
eaIgnoreSL,
|
||||||
eaAllowLong,
|
eaAllowLong,
|
||||||
@@ -856,6 +856,8 @@ void OnSignalRecieved(
|
|||||||
);
|
);
|
||||||
if (isFiltered)
|
if (isFiltered)
|
||||||
{
|
{
|
||||||
|
//
|
||||||
|
eaTradeHandler.RemoveSignal(signal);
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -5236,10 +5236,10 @@ struct XSymbolParser
|
|||||||
string version; // Temp ...
|
string version; // Temp ...
|
||||||
|
|
||||||
//
|
//
|
||||||
// Forext ...
|
// Symbol Parsing ...
|
||||||
|
|
||||||
//
|
//
|
||||||
// Symbol Parsing ...
|
// Forext ...
|
||||||
|
|
||||||
//
|
//
|
||||||
bool IsEURUSD(string symbol)
|
bool IsEURUSD(string symbol)
|
||||||
@@ -5529,6 +5529,9 @@ struct XSymbolParser
|
|||||||
return result;
|
return result;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
//
|
||||||
|
// Indexes ...
|
||||||
|
|
||||||
//
|
//
|
||||||
bool IsDowJones(string symbol)
|
bool IsDowJones(string symbol)
|
||||||
{
|
{
|
||||||
@@ -5609,7 +5612,7 @@ struct XSymbolSessionParser
|
|||||||
}
|
}
|
||||||
|
|
||||||
//
|
//
|
||||||
ENUM_DAY_OF_WEEK dayOfWeek = (ENUM_DAY_OF_WEEK) timeStruct.day_of_week;
|
ENUM_DAY_OF_WEEK dayOfWeek = (ENUM_DAY_OF_WEEK)timeStruct.day_of_week;
|
||||||
|
|
||||||
//
|
//
|
||||||
datetime cTime = TimeCurrent();
|
datetime cTime = TimeCurrent();
|
||||||
@@ -5637,6 +5640,28 @@ struct XSymbolSessionParser
|
|||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
|
||||||
|
//
|
||||||
|
// Parsing Market Names ...
|
||||||
|
struct XMarketParser
|
||||||
|
{
|
||||||
|
//
|
||||||
|
string _version; // Temp ...
|
||||||
|
|
||||||
|
//
|
||||||
|
bool IsAMarkets(string market)
|
||||||
|
{
|
||||||
|
//
|
||||||
|
bool result = false;
|
||||||
|
|
||||||
|
//
|
||||||
|
result = IsValid(market) &&
|
||||||
|
market == "AMarkets LLC";
|
||||||
|
|
||||||
|
//
|
||||||
|
return result;
|
||||||
|
}
|
||||||
|
};
|
||||||
|
|
||||||
//
|
//
|
||||||
// Styling Buffers ...
|
// Styling Buffers ...
|
||||||
|
|
||||||
|
|||||||
+6
-1
@@ -4,5 +4,10 @@
|
|||||||
"path": "."
|
"path": "."
|
||||||
}
|
}
|
||||||
],
|
],
|
||||||
"settings": {}
|
"settings": {
|
||||||
|
"C_Cpp.default.includePath": [
|
||||||
|
"c:\\Users\\SaherElm\\AppData\\Roaming\\MetaQuotes\\Terminal\\D0E8209F77C8CF37AD8BF550E51FF075\\MQL5\\Include\\Include",
|
||||||
|
"c:\\Users\\SaherElm\\AppData\\Roaming\\MetaQuotes\\Terminal\\D0E8209F77C8CF37AD8BF550E51FF075\\MQL5\\Include"
|
||||||
|
]
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -63,7 +63,9 @@ struct XCHStartegyConditionsParser
|
|||||||
// Parsers ...
|
// Parsers ...
|
||||||
|
|
||||||
//
|
//
|
||||||
|
XSCAccount _account;
|
||||||
XSymbolParser _symbolParser;
|
XSymbolParser _symbolParser;
|
||||||
|
XMarketParser _marketParser;
|
||||||
|
|
||||||
//
|
//
|
||||||
// EURUSD ...
|
// EURUSD ...
|
||||||
@@ -905,6 +907,10 @@ struct XCHStartegyConditionsParser
|
|||||||
bool isEURCAD = _symbolParser.IsEURCAD(signal.symbol);
|
bool isEURCAD = _symbolParser.IsEURCAD(signal.symbol);
|
||||||
bool isDowJones = _symbolParser.IsDowJones(signal.symbol);
|
bool isDowJones = _symbolParser.IsDowJones(signal.symbol);
|
||||||
|
|
||||||
|
//
|
||||||
|
string market = _account.GetCompany();
|
||||||
|
bool isAMarkets = _marketParser.IsAMarkets(market);
|
||||||
|
|
||||||
//
|
//
|
||||||
if (!force)
|
if (!force)
|
||||||
{
|
{
|
||||||
@@ -1076,6 +1082,10 @@ struct XCHStartegyConditionsParser
|
|||||||
bool isEURCAD = _symbolParser.IsEURCAD(signal.symbol);
|
bool isEURCAD = _symbolParser.IsEURCAD(signal.symbol);
|
||||||
bool isDowJones = _symbolParser.IsDowJones(signal.symbol);
|
bool isDowJones = _symbolParser.IsDowJones(signal.symbol);
|
||||||
|
|
||||||
|
//
|
||||||
|
string market = _account.GetCompany();
|
||||||
|
bool isAMarkets = _marketParser.IsAMarkets(market);
|
||||||
|
|
||||||
//
|
//
|
||||||
if (!force)
|
if (!force)
|
||||||
{
|
{
|
||||||
|
|||||||
@@ -1260,23 +1260,6 @@ public:
|
|||||||
return result;
|
return result;
|
||||||
}
|
}
|
||||||
|
|
||||||
// //
|
|
||||||
// result =
|
|
||||||
// //
|
|
||||||
// (hasLong &&
|
|
||||||
// bullishTrend.IsValid())
|
|
||||||
// //
|
|
||||||
// ||
|
|
||||||
// //
|
|
||||||
// (!hasLong &&
|
|
||||||
// bearishTrend.IsValid())
|
|
||||||
// //
|
|
||||||
// ;
|
|
||||||
// if (!result)
|
|
||||||
// {
|
|
||||||
// return result;
|
|
||||||
// }
|
|
||||||
|
|
||||||
//
|
//
|
||||||
DestroyImportantAreas();
|
DestroyImportantAreas();
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user