Free cookie consent management tool by TermsFeed Policy Generator

Ignore:
Timestamp:
04/22/10 22:23:55 (14 years ago)
Author:
mkommend
Message:

minor changes in RunCollectionBubbleChartView (ticket #970)

Location:
trunk/sources/HeuristicLab.Optimization.Views/3.3
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/sources/HeuristicLab.Optimization.Views/3.3/RunCollectionBubbleChartView.Designer.cs

    r3487 r3499  
    138138      this.sizeComboBox.DropDownStyle = System.Windows.Forms.ComboBoxStyle.DropDownList;
    139139      this.sizeComboBox.FormattingEnabled = true;
    140       this.sizeComboBox.Location = new System.Drawing.Point(441, 3);
     140      this.sizeComboBox.Location = new System.Drawing.Point(439, 3);
    141141      this.sizeComboBox.Name = "sizeComboBox";
    142142      this.sizeComboBox.Size = new System.Drawing.Size(121, 21);
  • trunk/sources/HeuristicLab.Optimization.Views/3.3/RunCollectionBubbleChartView.cs

    r3487 r3499  
    141141      base.OnContentChanged();
    142142      this.categoricalMapping.Clear();
    143       this.UpdateComboBoxes();
     143      UpdateComboBoxes();
     144      UpdateDataPoints();
    144145    }
    145146    private void Content_ColumnNamesChanged(object sender, EventArgs e) {
     
    154155      this.yAxisComboBox.Items.Clear();
    155156      this.sizeComboBox.Items.Clear();
    156       this.xAxisComboBox.Items.AddRange(Matrix.ColumnNames.ToArray());
    157       this.yAxisComboBox.Items.AddRange(Matrix.ColumnNames.ToArray());
    158       this.sizeComboBox.Items.Add(constantLabel);
    159       this.sizeComboBox.Items.AddRange(Matrix.ColumnNames.ToArray());
     157      if (Content != null) {
     158        this.xAxisComboBox.Items.AddRange(Matrix.ColumnNames.ToArray());
     159        this.yAxisComboBox.Items.AddRange(Matrix.ColumnNames.ToArray());
     160        this.sizeComboBox.Items.Add(constantLabel);
     161        this.sizeComboBox.Items.AddRange(Matrix.ColumnNames.ToArray());
     162      }
    160163    }
    161164
     
    172175      Series series = this.chart.Series[0];
    173176      series.Points.Clear();
    174       foreach (IRun run in this.Content)
    175         this.AddDataPoint(run);
     177      if (Content != null) {
     178        foreach (IRun run in this.Content)
     179          this.AddDataPoint(run);
     180      }
    176181    }
    177182    private void AddDataPoint(IRun run) {
     
    358363    }
    359364
    360     private string CreateTooltip(int runIndex) {
    361       StringBuilder builder = new StringBuilder();
    362       builder.AppendLine(this.Content.ElementAt(runIndex).Name);
    363       int columnIndex = 0;
    364       foreach (string columnName in Matrix.ColumnNames) {
    365         builder.Append(columnName);
    366         builder.Append(": ");
    367         builder.AppendLine(Matrix.GetValue(runIndex, columnIndex));
    368         columnIndex++;
    369       }
    370       return builder.ToString();
    371     }
    372 
    373365    private void zoomButton_CheckedChanged(object sender, EventArgs e) {
    374366      this.isSelecting = selectButton.Checked;
     
    377369      this.chart.ChartAreas[0].AxisY.ScaleView.Zoomable = !isSelecting;
    378370    }
    379 
    380371    private void colorButton_Click(object sender, EventArgs e) {
    381372      if (colorDialog.ShowDialog(this) == DialogResult.OK) {
Note: See TracChangeset for help on using the changeset viewer.