Example #1
0
        public override void BeginLoadImage(TileIndex id)
        {
            string imagePath = GetImagePath(id);

            ImageLoader loader = BeginLoadImageAsync;

            if (CanRunRequest)
            {
                runningRequests++;
                Statistics.IntValues["ImagesLoaded"]++;
                loader.BeginInvoke(id, OnImageLoadedAsync, new AsyncInfo {
                    ID = id, Loader = loader
                });
            }
            else
            {
                requests.Push(id);
            }
        }