Browse Source

Merge pull request #2144 from jasononeil/feature/allowdispatchsubclass

Allow Dispatch to be subclassed
Nicolas Cannasse 12 years ago
parent
commit
55825902eb
1 changed files with 4 additions and 1 deletions
  1. 4 1
      std/haxe/web/Dispatch.hx

+ 4 - 1
std/haxe/web/Dispatch.hx

@@ -59,7 +59,7 @@ enum DispatchError {
 	DETooManyValues;
 }
 
-private class Redirect {
+class Redirect {
 	public function new() {
 	}
 }
@@ -258,6 +258,9 @@ class Dispatch {
 						}
 						return MRSpod(i.toString(), lock);
 					}
+					else if ( name == "haxe.web.Dispatch" ) {
+						return MRDispatch;
+					}
 					csup = csup.t.get().superClass;
 				}
 				Context.error("Unsupported dispatch type '"+i.toString()+"'",p);