コード例 #1
0
        private DriverOfftrackLine GetLine(DriverContainer driver)
        {
            DriverOfftrackLine line;

            if (!_lines.ContainsKey(driver.Driver.Id))
            {
                line                    = new DriverOfftrackLine();
                line.Driver             = driver;
                line.Line               = _chart.CreateXY();
                line.Line.IsHitTest     = true;
                line.Line.LineThickness = 2;
                line.Line.LineColor     = GetColor();
                //line.Line.LegendColor = line.Line.LineColor;
                //line.Line.Label = driver.Driver.ShortName;
                //line.Line.LegendLabel = new ColorLabel(driver.Driver.ShortName, Colors.White);

                _lines.Add(driver.Driver.Id, line);
            }
            else
            {
                line = _lines[driver.Driver.Id];
            }

            this.SetOfftrackPoints(line);

            line.Taken = true;
            return(line);
        }