//private static int NextID = 0; //private readonly int ID; public TileMappingViewModel() { this.TileMapping = null; //this.ID = TileMappingViewModel.NextID++; this.VisibleRegion = new VisibleRegionInfo(0, 0, 10000, 10000, 256); this.Tiles = new ObservableCollection<TileViewModel>(); }
public TileMappingViewModel(MappingBase mapping) { //this.ID = TileMappingViewModel.NextID++; this.Tiles = new ObservableCollection<TileViewModel>(); this.TileMapping = mapping; this.VisibleRegion = new VisibleRegionInfo( new Rect(mapping.Bounds.Left, mapping.Bounds.Bottom, mapping.Bounds.Width, mapping.Bounds.Height),//Set the visible rect to include the entire mappable area mapping.AvailableLevels[mapping.AvailableLevels.Length - 1]); //Set the downsample to the highest possible value }