private void GenerateRows(Size finalSize) { //MessageBox.Show(new System.Diagnostics.StackTrace().ToString()); if (!RowsValid && (_oldSize != finalSize || !ignoreSameSize)) { _oldSize = finalSize; if (RowPresenter == null) { return; } RowsValid = true; RowPresenter.Children.Clear(); double height = finalSize.Height; for (double i = 0; i < height; i += RowHeight) { GanttRow row = new GanttRow { ParentPanel = this, BorderBrush = this.ParentGanttChart.GanttRowBorderBrush, GapBackgroundBrush = this.GapBackgroundBrush, GapBorderBrush = this.GapBorderBrush }; this.RowPresenter.Children.Add(row); } ResetRows(); } }
private GanttRow CreateRow() { GanttRow row = new GanttRow(); row.BorderBrush = BorderBrush; row.Background = Background; row.ParentPanel = this; return(row); }
private void ResetRows() { if (RowPresenter == null) { return; } for (int i = 0; i < RowPresenter.Children.Count; i++) { GanttRow row = RowPresenter.Children[i] as GanttRow; row.BorderBrush = ParentGanttChart.GanttRowBorderBrush; row.Background = Background; row._sameSizeCnt = 1; if (i + TopNodeIndex < Nodes.Count) { row.Node = Nodes[i + TopNodeIndex]; } else { row.Node = null; } } }
private void GenerateRows(Size finalSize) { //MessageBox.Show(new System.Diagnostics.StackTrace().ToString()); if (!RowsValid && (_oldSize != finalSize || !ignoreSameSize)) { _oldSize = finalSize; if (RowPresenter == null) return; RowsValid = true; RowPresenter.Children.Clear(); double height = finalSize.Height; for (double i = 0; i < height; i += RowHeight) { GanttRow row = new GanttRow { ParentPanel = this, BorderBrush = this.ParentGanttChart.GanttRowBorderBrush, GapBackgroundBrush = this.GapBackgroundBrush, GapBorderBrush = this.GapBorderBrush }; this.RowPresenter.Children.Add(row); } ResetRows(); } }
private GanttRow CreateRow() { GanttRow row = new GanttRow(); row.BorderBrush = BorderBrush; row.Background = Background; row.ParentPanel = this; return row; }