From 54ec736d3f722f16be5be2520261a2c9d11595ad Mon Sep 17 00:00:00 2001 From: Hadi Khazaee Asl Date: Wed, 10 Sep 2025 23:03:47 +0330 Subject: [PATCH] last .... --- Classes/x-saherelm.x-trade-manager.class.mq5 | 28 ++++++++++++++++++++ 1 file changed, 28 insertions(+) diff --git a/Classes/x-saherelm.x-trade-manager.class.mq5 b/Classes/x-saherelm.x-trade-manager.class.mq5 index b741a9b3..2d42a1b9 100644 --- a/Classes/x-saherelm.x-trade-manager.class.mq5 +++ b/Classes/x-saherelm.x-trade-manager.class.mq5 @@ -856,6 +856,34 @@ class XCTradeManager : public XCBase return result; } + /** + * Check Allow Trade or not .. + * + * @param type: ENUM_POSITIO_TYPE + * + * @return ( bool ) + */ + bool AllowTrade(ENUM_POSITIO_TYPE type) + { + // + bool result = false; + + // + result = allowTrade; + if (!result) + { + return result; + } + + // + result = + (IsLong(type) && allowLongs) || + (IsShort(typ) && allowShorts); + + // + return result; + } + /** * Handle All Exists Symbol Configurations Restrictions ... */