-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathDojo.hx
41 lines (32 loc) · 987 Bytes
/
Dojo.hx
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
package ;
/**
* This is a temporary class, since I don't have all the dojo externs yet
* @author
*/
class Dojo
{
static public function require(requirment:String) {
untyped __js__("dojo.require(requirment)");
}
static public function addOnLoad(func:Void->Void) {
untyped __js__("dojo.addOnLoad(func)");
}
static public function connect(obj:Dynamic, event:String, func:Dynamic->Void) {
untyped __js__("dojo.connect(obj,event,func)");
}
static public function disconnect(handle:Dynamic) {
untyped __js__("dojo.disconnect(handle)");
}
static public function byId(id:String):Dynamic {
return untyped __js__("dojo.byId(id)");
}
static public function create(name:String):String {
return untyped __js__("dojo.create(name)");
}
static public function toJson(object:Dynamic):String {
return untyped __js__("dojo.toJson(object)");
}
static public function place(source:Dynamic,target:Dynamic) {
untyped __js__("dojo.place(source,target)");
}
}