Example #1
0
        public ReporterFormWrapper ReporterActivateShowRegisterMniTick(string typeNameShortOrFullAutodetect, bool show = true)
        {
            string   typeNameShort     = this.repository.ShrinkTypeName(typeNameShortOrFullAutodetect);
            Reporter reporterActivated = this.repository.ActivateFromTypeName(typeNameShortOrFullAutodetect);
            object   reportersSnapshot = this.FindOrCreateReportersSnapshot(reporterActivated);

            reporterActivated.Initialize(this.ChartFormManager.ChartForm.ChartControl as ChartShadow, reportersSnapshot);
            var ret = new ReporterFormWrapper(this, reporterActivated);

            //ret.Text = reporterActivated.TabText + " :: " + this.ChartFormsManager.Strategy.Name;
            ret.Text = reporterActivated.TabText + " :: " + this.ChartFormManager.ChartForm.Text;
            if (show)
            {
                ret.Show(this.ChartFormManager.MainForm.DockPanel);
            }
            this.ReporterShortNamesUserInvoked.Add(typeNameShort, reporterActivated);
            this.ChartFormManager.ReportersDumpCurrentForSerialization();
            this.MenuItemsProvider.FindMniByShortNameAndTick(typeNameShort);
            reporterActivated.BuildOnceAfterFullBlindBacktestFinished(this.ChartFormManager.Executor.Performance);
            return(ret);
        }