Пример #1
0
        public void Draw(RallyData data)
        {
            _data = data;

            Cursor.Current = Cursors.WaitCursor;

            InitializeBoxes(data.Sagas.Values);

            if (data.SagasOrder != null)
            {
                List <SagaFeature> ordered = new List <SagaFeature>();
                foreach (string fid in data.SagasOrder)
                {
                    SagaFeature sf = data.FindSaga(fid);
                    if (sf == null)
                    {
                        continue;
                    }
                    ordered.Add(sf);
                }
                DrawSagaFeatures(ordered);
            }
            else
            {
                DrawSagaFeatures(data.Sagas.Values);
            }

            DrawIterations(data.Iterations.Values);

            Cursor.Current = Cursors.Default;
        }
Пример #2
0
        private void InitializeGrid(RallyData data)
        {
            grid.Rows.Clear();

            if (data.SagasOrder != null)
            {
                foreach (string id in data.SagasOrder)
                {
                    SagaFeature sf = data.FindSaga(id);
                    if (sf == null)
                    {
                        continue;
                    }
                    AddGridRow(sf);
                }
            }
            else
            {
                foreach (SagaFeature sf in data.Sagas.Values)
                {
                    AddGridRow(sf);
                }
            }
        }