updated xobject , clutter base objects started
[app.Builder.js] / XObjectBase / GtkClutterActor.js
1
2 //<Script type="Text/javascript">
3
4 XObject = imports.XObject.XObject
5 GtkClutter = imports.gi.GtkClutter;
6
7 //GtkClutter.Embed..
8 // children are not added at init / but at show stage..
9 // listener is added on show..
10 // we should really add a hock to destroy it..
11
12 GtkClutterActor = {
13     
14     onConstruct : function() {
15         this.items[0].pack = false;
16         
17     },
18     
19     init : function() {
20         print ("Actor init");
21         var child = this.items[0];
22         child.init();
23         
24         child.parent = this;
25         //var contents = new Gtk.Button({ label: 'test' }); 
26         
27        // print(JSON.stringify(this.items));
28         child.el.show();
29         
30         this.el = new GtkClutter.Actor.with_contents (  child.el) ;
31         
32         XObject.prototype.init.call(this);
33         this.el.show_all();
34     }
35
36 };