Example #1
0
        public void MoveDown()
        {
            int limit = Globals.Cols;

            for (int i = CanvasSquareList.Count() - 1; i >= limit; --i)
            {
                CanvasSquareList[i].IsFilled = CanvasSquareList[i - Globals.Cols].IsFilled;
            }
            for (int i = limit - 1; i >= 0; --i)
            {
                CanvasSquareList[i].IsFilled = false;
            }
        }
Example #2
0
        public void MoveUp()
        {
            int limit = CanvasSquareList.Count() - Globals.Cols;

            for (int i = 0; i < limit; ++i)
            {
                CanvasSquareList[i].IsFilled = CanvasSquareList[i + Globals.Cols].IsFilled;
            }
            for (int i = limit; i < CanvasSquareList.Count(); ++i)
            {
                CanvasSquareList[i].IsFilled = false;
            }
        }