diff --git a/indicators/VP.cs b/indicators/VP.cs index 6023295..f6c105d 100644 --- a/indicators/VP.cs +++ b/indicators/VP.cs @@ -112,12 +112,10 @@ namespace NinjaTrader.NinjaScript.Indicators get { return Name; } } - [NinjaScriptProperty] [Display(Name = "Profile Color", Description = "Color of the volume profile", Order = 1, GroupName = "Volume Profile")] public Brush ProfileColor { get; set; } - [NinjaScriptProperty] [Display(Name = "Max Width (Pixels)", Description = "Maximum pixel width for volume bars", Order = 2, GroupName = "Volume Profile")] public int MaxPixelWidth { @@ -125,7 +123,6 @@ namespace NinjaTrader.NinjaScript.Indicators set { maxPixelWidth = value; } } - [NinjaScriptProperty] [Display(Name = "Opacity (%)", Description = "Opacity of volume profile", Order = 3, GroupName = "Volume Profile")] public int Opacity { get; set; } @@ -139,18 +136,18 @@ namespace NinjaTrader.NinjaScript.Indicators public partial class Indicator : NinjaTrader.Gui.NinjaScript.IndicatorRenderBase { private VP[] cacheVP; - public VP VP(Brush profileColor, int maxPixelWidth, int opacity) + public VP VP() { - return VP(Input, profileColor, maxPixelWidth, opacity); + return VP(Input); } - public VP VP(ISeries input, Brush profileColor, int maxPixelWidth, int opacity) + public VP VP(ISeries input) { if (cacheVP != null) for (int idx = 0; idx < cacheVP.Length; idx++) - if (cacheVP[idx] != null && cacheVP[idx].ProfileColor == profileColor && cacheVP[idx].MaxPixelWidth == maxPixelWidth && cacheVP[idx].Opacity == opacity && cacheVP[idx].EqualsInput(input)) + if (cacheVP[idx] != null && cacheVP[idx].EqualsInput(input)) return cacheVP[idx]; - return CacheIndicator(new VP(){ ProfileColor = profileColor, MaxPixelWidth = maxPixelWidth, Opacity = opacity }, input, ref cacheVP); + return CacheIndicator(new VP(), input, ref cacheVP); } } } @@ -159,14 +156,14 @@ namespace NinjaTrader.NinjaScript.MarketAnalyzerColumns { public partial class MarketAnalyzerColumn : MarketAnalyzerColumnBase { - public Indicators.VP VP(Brush profileColor, int maxPixelWidth, int opacity) + public Indicators.VP VP() { - return indicator.VP(Input, profileColor, maxPixelWidth, opacity); + return indicator.VP(Input); } - public Indicators.VP VP(ISeries input , Brush profileColor, int maxPixelWidth, int opacity) + public Indicators.VP VP(ISeries input ) { - return indicator.VP(input, profileColor, maxPixelWidth, opacity); + return indicator.VP(input); } } } @@ -175,14 +172,14 @@ namespace NinjaTrader.NinjaScript.Strategies { public partial class Strategy : NinjaTrader.Gui.NinjaScript.StrategyRenderBase { - public Indicators.VP VP(Brush profileColor, int maxPixelWidth, int opacity) + public Indicators.VP VP() { - return indicator.VP(Input, profileColor, maxPixelWidth, opacity); + return indicator.VP(Input); } - public Indicators.VP VP(ISeries input , Brush profileColor, int maxPixelWidth, int opacity) + public Indicators.VP VP(ISeries input ) { - return indicator.VP(input, profileColor, maxPixelWidth, opacity); + return indicator.VP(input); } } }