last refactors ...

This commit is contained in:
2024-05-18 13:21:23 +03:30
parent 8c81f649dc
commit fb4445c1d7
19 changed files with 8425 additions and 42 deletions
+14 -13
View File
@@ -20,33 +20,35 @@
#property strict
//
// START Constants ...
//
// Constants ...
#define ShortName "XAMA"
//
// XAMA Indicator States ...
// Indicator States ...
enum ENUM_X_XAMA_STATES
{
X_XAMA_BULLISH = 1,
X_XAMA_BEARISH = -1,
X_XAMA_NEUTURAL = 0,
};
//
// END Constants ...
//
//
// START Inputs ...
// Inputs ...
//
// Market ...
input group "Market";
input int length = 18; // Period
input int fastEMA = 2; // Fast EMA Period
input int slowEMA = 30; // Slow EMA Period
input int maShift = 0; // Shift
input ENUM_APPLIED_PRICE appliedTo = PRICE_CLOSE; // Applied To
//
// END Inputs ...
//
// Presentation ...
input group "Presentation";
input bool showLine = true; // Show Line
//
// Includes Common Library ...
@@ -73,7 +75,7 @@ double stateBuffer[];
#property indicator_label1 "XAMA"
#property indicator_type1 DRAW_COLOR_LINE
#property indicator_color1 clrLime, clrGray, clrRed
#property indicator_color1 clrLime, clrGray, clrRed, CLR_NONE
#property indicator_style1 STYLE_SOLID
#property indicator_width1 1
//
@@ -313,8 +315,7 @@ void CalculateBuffers(int bar_index)
candle.Init(
_Symbol,
_Period,
bar_index
);
bar_index);
//
double maValue = maBuffer[bar_index];
@@ -335,7 +336,7 @@ void CalculateBuffers(int bar_index)
//
// Set Ma Buffer Color Index ...
maColorBuffer[bar_index] = lineColorIndex;
maColorBuffer[bar_index] = showLine ? lineColorIndex : 3;
//
// Set State Buffer Value ...