Ticket #285 (closed defect: fixed)

Opened 4 months ago

Last modified 4 months ago

copy empty text morph sets contents to undefined, when there is a connection

Reported by: jenslincke Owned by:
Priority: major Milestone:
Component: Apps Keywords:
Cc:

Description

creating a text example: connect(this, "textString", this.get("layeredRealList"), "filterItems", {});

Change History

comment:2 Changed 4 months ago by jenslincke

fixed in 130542

solution lively.morphic.TextChunk?.addMethods({

restoreFromCacheContent: function () {

if this.storedString is undefined we dont want to print it "undefined"

this.textString = this.storedString
"";

delete this.storedString;

}});

test lively.morphic.Tests.TextMorphTests?.addMethods({

test08CopyTextWithConnection: function () {

issue 285 var m = new lively.morphic.Text(new Rectangle(0,0, 100, 20), ""); connect(m, 'textString', m, 'someOtherField') var copy = m.duplicate() this.assert(copy.textString == , 'copy is broken')

}});

comment:3 Changed 4 months ago by jenslincke

  • Status changed from new to closed
  • Resolution set to fixed
Note: See TracTickets for help on using tickets.