X-Git-Url: https://mop.ddnsfree.com/gitweb/?a=blobdiff_plain;f=prova.html;h=ccac74a934980ae820a7467f3b15b35cdb41c370;hb=50efdc4b283f3cb7dadbfc032a87e85f74faa2c7;hp=bfd3f7d3689b37da4ded7abccf35f4d8c52cb453;hpb=b01ecbd33462133657a680f744a170124b5e517d;p=xynt.git diff --git a/prova.html b/prova.html index bfd3f7d..ccac74a 100644 --- a/prova.html +++ b/prova.html @@ -127,6 +127,11 @@ Summo.prototype = { name: "Summo", s_attr: null, + c_func: function() + { + console.log("c_func overwrited"); + }, + s_func: function() { this.a_func(); @@ -143,7 +148,7 @@ function Extends(sub) var supers = []; thinF = function(){}; - tmp = new thinF(); + inh = new thinF(); console.log("INIZIO EXT"); @@ -153,7 +158,7 @@ function Extends(sub) for (var f in proto) { console.log("LOOP: "+f); - if( f != "constructor" && typeof(proto[f]) == "function" && is_last){ + if( f != "constructor" && typeof(proto[f]) == "function" && !is_last){ console.log("PR: "+proto['name']+" F: "+f); // sub[f] = proto[f]; sub[f] = function(){ @@ -170,11 +175,11 @@ function Extends(sub) for( var i=1; i < arguments.length ; i++){ console.log("INIZIO LOOP"); - multi(tmp, arguments[i], false); + multi(inh, arguments[i], false); supers.push(arguments[i].prototype); } - multi(tmp, sub, true); - sub.prototype = tmp; + multi(inh, sub, true); + sub.prototype = inh; } s_ist = new Summo();