XObject.js
authorAlan Knowles <alan@akbkhome.com>
Tue, 3 Jul 2012 14:45:06 +0000 (22:45 +0800)
committerAlan Knowles <alan@akbkhome.com>
Tue, 3 Jul 2012 14:45:06 +0000 (22:45 +0800)
XObject.js

index 7ed3d1c..29cb104 100644 (file)
@@ -258,7 +258,7 @@ XObject.prototype = {
          //   XObject.registry[o.xnsid][o.id] = this;
         //}
         
-        var type = this.xtype.type ? GObject.type_name(this.xtype.type) : '';
+        var type = this.xtype && this.xtype.type ? GObject.type_name(this.xtype.type) : '';
         XObject.log("add children to " + type);
         
         var _this=this;
@@ -381,6 +381,12 @@ XObject.prototype = {
         var _li = XObject.createDelegate(fn,this);
         // private listeners that are not copied to GTk.
         
+               if (!this.el) {
+                       print('missing el?');
+                       print(JSON.stringify(this));
+               }
+               
+               
         if (typeof(Seed) != 'undefined') {
           //   Seed.print(typeof(_li));
             this.el.signal[sig].connect(_li);