fixes
This commit is contained in:
@@ -54,8 +54,8 @@ class BaseMediaLoader<T> extends BaseLoader<T> {
|
|||||||
private function buildLoaderContext():LoaderContext {
|
private function buildLoaderContext():LoaderContext {
|
||||||
return switch (Security.sandboxType) {
|
return switch (Security.sandboxType) {
|
||||||
case Security.REMOTE:
|
case Security.REMOTE:
|
||||||
null;
|
//null;
|
||||||
//new LoaderContext(true, ApplicationDomain.currentDomain, SecurityDomain.currentDomain);
|
new LoaderContext(true, ApplicationDomain.currentDomain, SecurityDomain.currentDomain);
|
||||||
case Security.APPLICATION:
|
case Security.APPLICATION:
|
||||||
var loaderContext:LoaderContext = new LoaderContext();
|
var loaderContext:LoaderContext = new LoaderContext();
|
||||||
loaderContext.allowLoadBytesCodeExecution = true;
|
loaderContext.allowLoadBytesCodeExecution = true;
|
||||||
|
|||||||
@@ -76,7 +76,7 @@ class OrderSupplier implements IOrderSupplier {
|
|||||||
private function buildLoader<T>(clazz:Class<T>):ILoader<T> {
|
private function buildLoader<T>(clazz:Class<T>):ILoader<T> {
|
||||||
var c:Class<Dynamic> = clazz;
|
var c:Class<Dynamic> = clazz;
|
||||||
return if (c == BitmapData) {
|
return if (c == BitmapData) {
|
||||||
var loader:ILoader<T> = untyped new ExternalImageLoader();
|
var loader:ILoader<T> = untyped new ImageLoader();
|
||||||
loader.timeout = 5000; //ToDo: hardcode timeout for loading images
|
loader.timeout = 5000; //ToDo: hardcode timeout for loading images
|
||||||
loader;
|
loader;
|
||||||
} else {
|
} else {
|
||||||
|
|||||||
@@ -16,6 +16,20 @@ class UrlUtil {
|
|||||||
return result;
|
return result;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public static function parseParamsDynamic(url:String):Dynamic {
|
||||||
|
var result:Dynamic = {}
|
||||||
|
var tmp:String = url == null ? null : url.split("?")[1];
|
||||||
|
if (tmp != null) {
|
||||||
|
var tmpArr:Array<String> = tmp.split("&");
|
||||||
|
for (item in tmpArr) {
|
||||||
|
var itemArr:Array<String> = item.split("=");
|
||||||
|
Reflect.setField(result, itemArr[0], itemArr[1]);
|
||||||
|
}
|
||||||
|
result;
|
||||||
|
}
|
||||||
|
return result;
|
||||||
|
}
|
||||||
|
|
||||||
public static function mergeParams(params1:Map<String, String>, params2:Map<String, String>):Void {
|
public static function mergeParams(params1:Map<String, String>, params2:Map<String, String>):Void {
|
||||||
for (key in params2.keys()) {
|
for (key in params2.keys()) {
|
||||||
params1.set(key, params2.get(key));
|
params1.set(key, params2.get(key));
|
||||||
|
|||||||
Reference in New Issue
Block a user