disable caching when using Flash Debug Player
[potlatch2.git] / net / systemeD / potlatch2 / utils / CachedDataLoader.as
index c790cc685994ccdab2f206f29ca6f5bada4e47aa..17b6c181a2dc621fb37aeecacc490b993e3c9ae7 100644 (file)
@@ -7,6 +7,7 @@ package net.systemeD.potlatch2.utils {
        import mx.graphics.codec.PNGEncoder;
 
     import net.systemeD.halcyon.ExtendedURLLoader;
+       import net.systemeD.halcyon.DebugURLRequest;
 
        public class CachedDataLoader {
 
@@ -24,12 +25,13 @@ package net.systemeD.potlatch2.utils {
                        requests = [];
                        requestsMade[url] = requests;
 
+                               var request:DebugURLRequest = new DebugURLRequest(url);
                            var loader:ExtendedURLLoader = new ExtendedURLLoader();
                    loader.info = url;
                 loader.addEventListener(Event.COMPLETE, imageLoaded);
                 loader.addEventListener(IOErrorEvent.IO_ERROR, imageLoadFailed);
                 loader.dataFormat = URLLoaderDataFormat.BINARY;
-                loader.load(new URLRequest(url));
+                loader.load(request.request);
                    }
                    requests.push(onLoadHandler);