コード例 #1
0
 public override void Unload()
 {
     graph.Dispose();
     graph      = null;
     controller = null;
     lineSeries = null;
 }
コード例 #2
0
        public override void Load(IServiceProvider provider)
        {
            var context          = (ITypeVisualizerContext)provider.GetService(typeof(ITypeVisualizerContext));
            var lineChartBuilder = (LineGraphBuilder)ExpressionBuilder.GetVisualizerElement(context.Source).Builder;

            controller = lineChartBuilder.Controller;

            graph      = new GraphControl();
            graph.Dock = DockStyle.Fill;

            var visualizerService = (IDialogTypeVisualizerService)provider.GetService(typeof(IDialogTypeVisualizerService));

            if (visualizerService != null)
            {
                visualizerService.AddControl(graph);
            }
        }