Lively Kernel canvas
// this script is evaluated on world load
MyConsole = WorldMorph.current().submorphs.detect(function(ea){return ea.name == "MyConsole"});
if(!MyConsole) return;
MyConsole = MyConsole.component;
MyConsole.setText("-- start --");
MyConsole.log = function(s) {
this.setText(this.formalModel.getText() + "\n" + s);
};
MyConsole.log("My Console initialized!");
MyConsole.morph.resetScrollPane = function() {
var sp = this.enclosingScrollPane();
if (sp) sp.scrollToBottom();
};
// console.consumers seems to be broken... so we go the hard waz
console.log = console.log.wrap(function(proceed, s) {
MyConsole.log(s)
proceed(s)})
console.log("wrapped console for MyConsole successfully")
DraftNewModel40
Bla..16
- null
Update16
FieldValue...16
- null
Scenario:UIBuilderandPrototyping20
Morph
null-0.05549850524571683null
null3.0860941483440762null
Morph
null-0.0097084328341089null
View
- null
Model
- null
- null
null2.114374811386557null
null1.009016049843039null
View
- null
null3.1318842207556843null
Object
Object
Scenario:sharingdata...20
Priorities:20
Serialisierbar!20
connect(this,'text,'other,'text')connect(this,'text,'other,'length',function(origText){returnorigText.asNumber()})//r,g,b->Colorconnect(this,"rValue",this,"updateColor");connect(this,"gValue",this,"updateColor");connect(this,"bValue",this,"updateColor");//alternative:onChangeOfDo(obj1,['r','g','b'],function(r,g,b){obj2.setColor(r,g,b)})//Color->r,g,b?1415 Color\rconnect(this, \"rValue\", this, \"updateColor\");\rconnect(this, \"gValue\", this, \"updateColor\");\rconnect(this, \"bValue\", this, \"updateColor\");\r\r// alternative:\ronChangeOfDo(obj1, ['r', 'g', 'b'], function(r,g,b) { obj2.setColor(r,g,b) })\r\r// Color -> r,g,b ?\r\r\r"]]>
RequirementsforournewModel20
Fachgebietfragen....20
Reliable20
Understandable20
NetRequest
UserInterface...
Morph|Object20
Prototypeishere40
Examplesarehere40null44