public MapDrawer(Grid grid, int rows, int columns, Map map)
        {
            this.mapModel    = map;
            this.RowCount    = rows;
            this.ColumnCount = columns;
            fields           = new GuiMapField[rows, columns];

            for (int i = 0; i < RowCount; ++i)
            {
                for (int j = 0; j < ColumnCount; ++j)
                {
                    GuiMapField field = null;
                    if (map.IsWithinBounds(i, j))
                    {
                        field = new GuiMapField(map, map[i, j]);                       // map[i, j]);
                    }
                    else
                    {
                        field = new GuiMapField(map, null);
                    }
                    fields[i, j] = field;

                    field.SetValue(Grid.RowProperty, i);
                    field.SetValue(Grid.ColumnProperty, j);

                    grid.Children.Add(field);
                }
            }
        }
		public MapDrawer(Grid grid, int rows, int columns, Map map)
		{
			this.mapModel = map;
			this.RowCount = rows; 
			this.ColumnCount = columns;
			fields = new GuiMapField[rows, columns];

			for (int i = 0; i < RowCount; ++i)
			{
				for (int j = 0; j < ColumnCount; ++j)
				{
					GuiMapField field = null;
					if (map.IsWithinBounds(i, j))
					{
						field = new GuiMapField(map, map[i,j]);// map[i, j]);
					}
					else
					{
						field = new GuiMapField(map, null);
					}
					fields[i,j] = field;

					field.SetValue(Grid.RowProperty, i);
					field.SetValue(Grid.ColumnProperty, j);

					grid.Children.Add(field);
				}
			}
		}