{"id":0,"registry":{"0":{"submorphs":[{"__isSmartRef__":true,"id":1}],"scripts":[],"id":"35401CB0-4E04-4239-B9FF-E923F329A369","shape":{"__isSmartRef__":true,"id":16},"droppingEnabled":true,"halosEnabled":true,"registeredForMouseEvents":true,"showsHalos":false,"partsBinMetaInfo":{"__isSmartRef__":true,"id":17},"__layered_draggingEnabled__":true,"attributeConnections":[{"__isSmartRef__":true,"id":29}],"doNotSerialize":["$$name"],"doNotCopyProperties":["$$name"],"_traitConfig_":[{"__isSmartRef__":true,"id":30}],"eventHandler":{"__isSmartRef__":true,"id":32},"scriptAnnotations":{"__isSmartRef__":true,"id":33},"name":"PhysicsBehavior","derivationIds":[96],"_ClipMode":"visible","_Rotation":0,"_Scale":1,"icon":{"__isSmartRef__":true,"id":36},"__serializedExpressions__":["_Position","dropColor"],"__serializedLivelyClosures__":{"__isSmartRef__":true,"id":288},"__LivelyClassName__":"lively.morphic.Box","__SourceModuleName__":"Global.lively.morphic.Core","_Position":"lively.pt(0.0,0.0)","dropColor":"Color.rgb(0,79,152)"},"1":{"submorphs":[],"scripts":[],"id":"B50EF154-E04B-40B0-8460-786994FB6E51","shape":{"__isSmartRef__":true,"id":2},"grabbingEnabled":false,"droppingEnabled":false,"halosEnabled":true,"fixedWidth":true,"fixedHeight":false,"allowsInput":true,"_OverflowMode":"visible","_FontFamily":"Arial, sans-serif","registeredForMouseEvents":true,"_MaxTextWidth":93.8018403394826,"_MaxTextHeight":null,"showsHalos":false,"_FontSize":8,"name":"NameLabel","partsBinMetaInfo":{"__isSmartRef__":true,"id":3},"textChunks":[{"__isSmartRef__":true,"id":4}],"charsReplaced":"Grr","lastFindLoc":-3,"prevScroll":[0,0],"attributeConnections":[{"__isSmartRef__":true,"id":6},{"__isSmartRef__":true,"id":7}],"doNotSerialize":["$$owner","$$savedTextString"],"doNotCopyProperties":["$$owner","$$savedTextString"],"oldOwner":{"__isSmartRef__":true,"id":0},"isInputLine":true,"eventsAreIgnored":true,"eventHandler":{"__isSmartRef__":true,"id":8},"_HandStyle":"default","_PointerEvents":"none","owner":{"__isSmartRef__":true,"id":0},"savedTextString":"TopLeft","derivationIds":[97],"_WhiteSpaceHandling":"pre-wrap","_ClipMode":"visible","_Rotation":0,"_Scale":1.0030060100150207,"__serializedExpressions__":["_Position","textColor","distanceToDragEvent"],"__serializedLivelyClosures__":{"__isSmartRef__":true,"id":9},"__LivelyClassName__":"lively.morphic.Text","__SourceModuleName__":"Global.lively.morphic.TextCore","_Position":"lively.pt(14.0,11.0)","textColor":"Color.rgb(0,0,0)","distanceToDragEvent":"lively.pt(78.0,-15.0)"},"2":{"fill":null,"_BorderWidth":0,"__serializedExpressions__":["_Position","_Extent","_BorderColor","_Padding"],"__LivelyClassName__":"lively.morphic.Shapes.Rectangle","__SourceModuleName__":"Global.lively.morphic.Shapes","_Position":"lively.pt(0.0,0.0)","_Extent":"lively.pt(93.8,14.0)","_BorderColor":"Color.rgb(0,0,0)","_Padding":"lively.rect(0,0,0,0)"},"3":{"partsSpaceName":"PartsBin/NewWorld","migrationLevel":2,"comment":"Label that shows the name of a morph. Updates automatically.","__LivelyClassName__":"lively.PartsBin.PartsBinMetaInfo","__SourceModuleName__":"Global.lively.PartsBin"},"4":{"style":{"__isSmartRef__":true,"id":5},"chunkOwner":{"__isSmartRef__":true,"id":1},"_id":"_1331","storedString":"PhysicsBehavior","__LivelyClassName__":"lively.morphic.TextChunk","__SourceModuleName__":"Global.lively.morphic.TextCore"},"5":{"__LivelyClassName__":"lively.morphic.TextEmphasis","__SourceModuleName__":"Global.lively.morphic.TextCore"},"6":{"sourceObj":{"__isSmartRef__":true,"id":1},"sourceAttrName":"owner","targetObj":{"__isSmartRef__":true,"id":1},"targetMethodName":"updateLabel","converterString":null,"updaterString":null,"__LivelyClassName__":"AttributeConnection","__SourceModuleName__":"Global.lively.bindings.Core"},"7":{"sourceObj":{"__isSmartRef__":true,"id":1},"sourceAttrName":"savedTextString","targetObj":{"__isSmartRef__":true,"id":1},"targetMethodName":"renameOwner","__LivelyClassName__":"AttributeConnection","__SourceModuleName__":"Global.lively.bindings.Core"},"8":{"morph":{"__isSmartRef__":true,"id":1},"__LivelyClassName__":"lively.morphic.EventHandler","__SourceModuleName__":"Global.lively.morphic.Events"},"9":{"updateLabel":{"__isSmartRef__":true,"id":10},"renameOwner":{"__isSmartRef__":true,"id":13}},"10":{"varMapping":{"__isSmartRef__":true,"id":11},"source":"function updateLabel() {\n\t// observe name changes in owner\n\tif (this.owner !== this.oldOwner) {\n\t\tif (this.oldOwner)\n\t\t\tdisconnect(this.oldOwner, 'name', this, 'updateLabel')\n\t\tif (this.owner)\n\t\t\tconnect(this.owner, 'name', this, 'updateLabel')\n\t\tthis.oldOwner = this.owner\n\t}\n\tvar name = (this.owner ? this.owner.name : \"no owner\")\n\tif (this.textString != name)\n\tthis.setTextString(name)\n}","funcProperties":{"__isSmartRef__":true,"id":12},"__LivelyClassName__":"lively.Closure","__SourceModuleName__":"Global.lively.lang.Closure"},"11":{"this":{"__isSmartRef__":true,"id":1}},"12":{},"13":{"varMapping":{"__isSmartRef__":true,"id":14},"source":"function renameOwner(name) {\n\tif (this.owner && this.owner.name != name) {\n\t\talertOK(\"renamed \" + this.owner + \" to \" + name)\n\t\tthis.owner.setName(name);\n\t}\n}","funcProperties":{"__isSmartRef__":true,"id":15},"__LivelyClassName__":"lively.Closure","__SourceModuleName__":"Global.lively.lang.Closure"},"14":{"this":{"__isSmartRef__":true,"id":1}},"15":{},"16":{"_BorderWidth":0,"_BorderRadius":20.71,"__serializedExpressions__":["position","_Extent","_BorderColor","_Fill","_Padding"],"__LivelyClassName__":"lively.morphic.Shapes.Rectangle","__SourceModuleName__":"Global.lively.morphic.Shapes","position":"lively.pt(0.0,0.0)","_Extent":"lively.pt(110.0,34.0)","_BorderColor":"Color.rgb(28,0,153)","_Fill":"Color.rgb(214,214,214)","_Padding":"lively.rect(0,0,0,0)"},"17":{"partsSpaceName":"PartsBin/DroppableBehaviors/","comment":"Droppable behavior which sets up a Box2D canvas and creates facilities for adding physics to objects.","migrationLevel":8,"partName":"PhysicsBehavior","changes":[{"__isSmartRef__":true,"id":18},{"__isSmartRef__":true,"id":19},{"__isSmartRef__":true,"id":20},{"__isSmartRef__":true,"id":21},{"__isSmartRef__":true,"id":22},{"__isSmartRef__":true,"id":23},{"__isSmartRef__":true,"id":24},{"__isSmartRef__":true,"id":25},{"__isSmartRef__":true,"id":26},{"__isSmartRef__":true,"id":27},{"__isSmartRef__":true,"id":28}],"__serializedExpressions__":["lastModifiedDate"],"__LivelyClassName__":"lively.PartsBin.PartsBinMetaInfo","__SourceModuleName__":"Global.lively.PartsBin","lastModifiedDate":"new Date(\"Thu Aug 29 2013 15:50:06 GMT-0700 (Pacific Daylight Time)\")"},"18":{"author":"MatthewGoldberg","message":"no comment","id":"651E9219-15ED-4B68-A1E9-D2464BE4CA23","__serializedExpressions__":["date"],"date":"new Date(\"Tue Aug 27 2013 10:08:52 GMT-0700 (Pacific Daylight Time)\")"},"19":{"author":"MatthewGoldberg","message":"no comment","id":"5CB50CA6-45E7-4B8F-BE7A-AAB1C08310E2","__serializedExpressions__":["date"],"date":"new Date(\"Tue Aug 27 2013 10:13:37 GMT-0700 (Pacific Daylight Time)\")"},"20":{"author":"MatthewGoldberg","message":"no comment","id":"D083015B-8A46-428F-A49D-8DA9FEFE0B66","__serializedExpressions__":["date"],"date":"new Date(\"Tue Aug 27 2013 11:17:47 GMT-0700 (Pacific Daylight Time)\")"},"21":{"author":"MatthewGoldberg","message":"no comment","id":"2A7D1BBC-E9EA-4D1B-8F4C-9C859BD9A9E7","__serializedExpressions__":["date"],"date":"new Date(\"Tue Aug 27 2013 11:20:09 GMT-0700 (Pacific Daylight Time)\")"},"22":{"author":"MatthewGoldberg","message":"no comment","id":"720A26F3-9F2B-46A2-8816-583124B0C258","__serializedExpressions__":["date"],"date":"new Date(\"Tue Aug 27 2013 11:42:20 GMT-0700 (Pacific Daylight Time)\")"},"23":{"author":"MatthewGoldberg","message":"no comment","id":"1B2FAC41-2C15-4DC8-A55C-A636B34325A2","__serializedExpressions__":["date"],"date":"new Date(\"Tue Aug 27 2013 11:42:26 GMT-0700 (Pacific Daylight Time)\")"},"24":{"author":"MatthewGoldberg","message":"no comment","id":"0BC89D9C-07CB-401C-9C8A-2309260E31D7","__serializedExpressions__":["date"],"date":"new Date(\"Tue Aug 27 2013 11:44:19 GMT-0700 (Pacific Daylight Time)\")"},"25":{"author":"MatthewGoldberg","message":"no comment","id":"EC7B3F04-40AB-4CE3-8A22-0C3D89BBF08C","__serializedExpressions__":["date"],"date":"new Date(\"Thu Aug 29 2013 14:53:10 GMT-0700 (Pacific Daylight Time)\")"},"26":{"author":"MatthewGoldberg","message":"no comment","id":"59C5C4AC-43E3-4970-8486-DF6B9E1964BE","__serializedExpressions__":["date"],"date":"new Date(\"Thu Aug 29 2013 14:57:33 GMT-0700 (Pacific Daylight Time)\")"},"27":{"__serializedExpressions__":["date"],"author":"MatthewGoldberg","message":"no comment","id":"3002F495-B9A5-4361-B2E4-8C5D1DD7676E","date":"new Date(\"Thu Aug 29 2013 15:49:58 GMT-0700 (Pacific Daylight Time)\")"},"28":{"__serializedExpressions__":["date"],"author":"MatthewGoldberg","message":"no comment","id":"33F0A4FC-8F1C-495B-9C95-00299716ED5B","date":"new Date(\"Thu Aug 29 2013 16:10:43 GMT-0700 (Pacific Daylight Time)\")"},"29":{"sourceObj":{"__isSmartRef__":true,"id":0},"sourceAttrName":"name","targetObj":{"__isSmartRef__":true,"id":1},"targetMethodName":"updateLabel","converterString":null,"updaterString":null,"__LivelyClassName__":"AttributeConnection","__SourceModuleName__":"Global.lively.bindings.Core"},"30":{"traitName":"lively.morphic.DraggableBehavior","options":{"__isSmartRef__":true,"id":31}},"31":{"override":["onDragStart","onDragEnd"]},"32":{"morph":{"__isSmartRef__":true,"id":0},"__LivelyClassName__":"lively.morphic.EventHandler","__SourceModuleName__":"Global.lively.morphic.Events"},"33":{"applyTo":{"__isSmartRef__":true,"id":34},"reset":{"__isSmartRef__":true,"id":35}},"34":{"user":"robertkrahn","__serializedExpressions__":["time"],"time":"new Date(\"Fri Jul 01 2011 18:24:39 GMT-0700 (Pacific Daylight Time)\")"},"35":{"user":"robertkrahn","__serializedExpressions__":["time"],"time":"new Date(\"Fri Jul 01 2011 18:24:47 GMT-0700 (Pacific Daylight Time)\")"},"36":{"submorphs":[{"__isSmartRef__":true,"id":37}],"scripts":[],"id":"EB40276A-F487-4E7C-B65A-BD9C50AF44FA","shape":{"__isSmartRef__":true,"id":52},"droppingEnabled":true,"halosEnabled":true,"registeredForMouseEvents":true,"showsHalos":false,"partsBinMetaInfo":{"__isSmartRef__":true,"id":53},"__layered_draggingEnabled__":true,"attributeConnections":[{"__isSmartRef__":true,"id":54}],"doNotSerialize":["$$name"],"doNotCopyProperties":["$$name"],"_traitConfig_":[{"__isSmartRef__":true,"id":55}],"eventHandler":{"__isSmartRef__":true,"id":57},"scriptAnnotations":{"__isSmartRef__":true,"id":58},"name":"PhysicsBehavior1","derivationIds":[96,"35401CB0-4E04-4239-B9FF-E923F329A369"],"_ClipMode":"visible","icon":{"__isSmartRef__":true,"id":61},"owner":null,"_Rotation":0,"_Scale":1,"__serializedExpressions__":["_Position","dropColor","previousPosition"],"__serializedLivelyClosures__":{"__isSmartRef__":true,"id":271},"__LivelyClassName__":"lively.morphic.Box","__SourceModuleName__":"Global.lively.morphic.Core","_Position":"lively.pt(-65.0,-22.0)","dropColor":"Color.rgb(0,79,152)","previousPosition":"lively.pt(-65.0,-22.0)"},"37":{"submorphs":[],"scripts":[],"id":"770DCFB5-EB5F-4AB9-BE1D-E2E5BAE1F27B","shape":{"__isSmartRef__":true,"id":38},"grabbingEnabled":false,"droppingEnabled":false,"halosEnabled":true,"fixedWidth":true,"fixedHeight":false,"allowsInput":true,"_OverflowMode":"visible","_FontFamily":"Arial, sans-serif","registeredForMouseEvents":true,"_MaxTextWidth":93.8018403394826,"_MaxTextHeight":null,"showsHalos":false,"_FontSize":8,"name":"NameLabel","partsBinMetaInfo":{"__isSmartRef__":true,"id":39},"textChunks":[{"__isSmartRef__":true,"id":40}],"charsReplaced":"Grr","lastFindLoc":-3,"prevScroll":[0,0],"attributeConnections":[{"__isSmartRef__":true,"id":42},{"__isSmartRef__":true,"id":43}],"doNotSerialize":["$$owner","$$savedTextString"],"doNotCopyProperties":["$$owner","$$savedTextString"],"oldOwner":{"__isSmartRef__":true,"id":36},"isInputLine":true,"eventsAreIgnored":true,"eventHandler":{"__isSmartRef__":true,"id":44},"_HandStyle":"default","_PointerEvents":"none","owner":{"__isSmartRef__":true,"id":36},"savedTextString":"TopLeft","derivationIds":[97,"B50EF154-E04B-40B0-8460-786994FB6E51"],"_WhiteSpaceHandling":"pre-wrap","_ClipMode":"visible","_Rotation":0,"_Scale":1.0030060100150207,"__serializedExpressions__":["_Position","textColor","distanceToDragEvent"],"__serializedLivelyClosures__":{"__isSmartRef__":true,"id":45},"__LivelyClassName__":"lively.morphic.Text","__SourceModuleName__":"Global.lively.morphic.TextCore","_Position":"lively.pt(14.0,11.0)","textColor":"Color.rgb(0,0,0)","distanceToDragEvent":"lively.pt(78.0,-15.0)"},"38":{"fill":null,"_BorderWidth":0,"__serializedExpressions__":["_Position","_Extent","_BorderColor","_Padding"],"__LivelyClassName__":"lively.morphic.Shapes.Rectangle","__SourceModuleName__":"Global.lively.morphic.Shapes","_Position":"lively.pt(0.0,0.0)","_Extent":"lively.pt(93.8,14.0)","_BorderColor":"Color.rgb(0,0,0)","_Padding":"lively.rect(0,0,0,0)"},"39":{"partsSpaceName":"PartsBin/NewWorld","migrationLevel":2,"comment":"Label that shows the name of a morph. Updates automatically.","__LivelyClassName__":"lively.PartsBin.PartsBinMetaInfo","__SourceModuleName__":"Global.lively.PartsBin"},"40":{"style":{"__isSmartRef__":true,"id":41},"chunkOwner":{"__isSmartRef__":true,"id":37},"_id":"_841","storedString":"PhysicsBehavior1","__LivelyClassName__":"lively.morphic.TextChunk","__SourceModuleName__":"Global.lively.morphic.TextCore"},"41":{"__LivelyClassName__":"lively.morphic.TextEmphasis","__SourceModuleName__":"Global.lively.morphic.TextCore"},"42":{"sourceObj":{"__isSmartRef__":true,"id":37},"sourceAttrName":"owner","targetObj":{"__isSmartRef__":true,"id":37},"targetMethodName":"updateLabel","converterString":null,"updaterString":null,"__LivelyClassName__":"AttributeConnection","__SourceModuleName__":"Global.lively.bindings.Core"},"43":{"sourceObj":{"__isSmartRef__":true,"id":37},"sourceAttrName":"savedTextString","targetObj":{"__isSmartRef__":true,"id":37},"targetMethodName":"renameOwner","__LivelyClassName__":"AttributeConnection","__SourceModuleName__":"Global.lively.bindings.Core"},"44":{"morph":{"__isSmartRef__":true,"id":37},"__LivelyClassName__":"lively.morphic.EventHandler","__SourceModuleName__":"Global.lively.morphic.Events"},"45":{"updateLabel":{"__isSmartRef__":true,"id":46},"renameOwner":{"__isSmartRef__":true,"id":49}},"46":{"varMapping":{"__isSmartRef__":true,"id":47},"source":"function updateLabel() {\n\t// observe name changes in owner\n\tif (this.owner !== this.oldOwner) {\n\t\tif (this.oldOwner)\n\t\t\tdisconnect(this.oldOwner, 'name', this, 'updateLabel')\n\t\tif (this.owner)\n\t\t\tconnect(this.owner, 'name', this, 'updateLabel')\n\t\tthis.oldOwner = this.owner\n\t}\n\tvar name = (this.owner ? this.owner.name : \"no owner\")\n\tif (this.textString != name)\n\tthis.setTextString(name)\n}","funcProperties":{"__isSmartRef__":true,"id":48},"__LivelyClassName__":"lively.Closure","__SourceModuleName__":"Global.lively.lang.Closure"},"47":{"this":{"__isSmartRef__":true,"id":37}},"48":{},"49":{"varMapping":{"__isSmartRef__":true,"id":50},"source":"function renameOwner(name) {\n\tif (this.owner && this.owner.name != name) {\n\t\talertOK(\"renamed \" + this.owner + \" to \" + name)\n\t\tthis.owner.setName(name);\n\t}\n}","funcProperties":{"__isSmartRef__":true,"id":51},"__LivelyClassName__":"lively.Closure","__SourceModuleName__":"Global.lively.lang.Closure"},"50":{"this":{"__isSmartRef__":true,"id":37}},"51":{},"52":{"_BorderWidth":0,"_BorderRadius":20.71,"__serializedExpressions__":["position","_Extent","_BorderColor","_Fill","_Padding"],"__LivelyClassName__":"lively.morphic.Shapes.Rectangle","__SourceModuleName__":"Global.lively.morphic.Shapes","position":"lively.pt(0.0,0.0)","_Extent":"lively.pt(110.0,34.0)","_BorderColor":"Color.rgb(28,0,153)","_Fill":"Color.rgb(214,214,214)","_Padding":"lively.rect(0,0,0,0)"},"53":{"partsSpaceName":"PartsBin/DroppableBehaviors/","comment":"A simple box morph","migrationLevel":4,"partName":"ThrobbingBehavior","__serializedExpressions__":["lastModifiedDate"],"__LivelyClassName__":"lively.PartsBin.PartsBinMetaInfo","__SourceModuleName__":"Global.lively.PartsBin","lastModifiedDate":"new Date(\"Wed Sep 05 2012 16:01:35 GMT-0700 (Pacific Daylight Time)\")"},"54":{"sourceObj":{"__isSmartRef__":true,"id":36},"sourceAttrName":"name","targetObj":{"__isSmartRef__":true,"id":37},"targetMethodName":"updateLabel","converterString":null,"updaterString":null,"__LivelyClassName__":"AttributeConnection","__SourceModuleName__":"Global.lively.bindings.Core"},"55":{"traitName":"lively.morphic.DraggableBehavior","options":{"__isSmartRef__":true,"id":56}},"56":{"override":["onDragStart","onDragEnd"]},"57":{"morph":{"__isSmartRef__":true,"id":36},"__LivelyClassName__":"lively.morphic.EventHandler","__SourceModuleName__":"Global.lively.morphic.Events"},"58":{"applyTo":{"__isSmartRef__":true,"id":59},"reset":{"__isSmartRef__":true,"id":60}},"59":{"user":"robertkrahn","__serializedExpressions__":["time"],"time":"new Date(\"Fri Jul 01 2011 18:24:39 GMT-0700 (Pacific Daylight Time)\")"},"60":{"user":"robertkrahn","__serializedExpressions__":["time"],"time":"new Date(\"Fri Jul 01 2011 18:24:47 GMT-0700 (Pacific Daylight Time)\")"},"61":{"submorphs":[{"__isSmartRef__":true,"id":62}],"scripts":[],"id":"19434CF9-C0CC-4048-AF16-6EBDD63A6E75","shape":{"__isSmartRef__":true,"id":77},"droppingEnabled":true,"halosEnabled":true,"registeredForMouseEvents":true,"showsHalos":false,"partsBinMetaInfo":{"__isSmartRef__":true,"id":78},"__layered_draggingEnabled__":true,"attributeConnections":[{"__isSmartRef__":true,"id":79}],"doNotSerialize":["$$name"],"doNotCopyProperties":["$$name"],"_traitConfig_":[{"__isSmartRef__":true,"id":80}],"eventHandler":{"__isSmartRef__":true,"id":82},"scriptAnnotations":{"__isSmartRef__":true,"id":83},"name":"PhysicsBehavior1","derivationIds":[96,"35401CB0-4E04-4239-B9FF-E923F329A369"],"_ClipMode":"visible","icon":{"__isSmartRef__":true,"id":86},"owner":null,"_Rotation":0,"_Scale":1,"__serializedExpressions__":["_Position","dropColor","previousPosition"],"__serializedLivelyClosures__":{"__isSmartRef__":true,"id":254},"__LivelyClassName__":"lively.morphic.Box","__SourceModuleName__":"Global.lively.morphic.Core","_Position":"lively.pt(-87.0,-15.0)","dropColor":"Color.rgb(0,79,152)","previousPosition":"lively.pt(-87.0,-15.0)"},"62":{"submorphs":[],"scripts":[],"id":"F7D1D38B-1500-4927-A72D-54DE650F0EF1","shape":{"__isSmartRef__":true,"id":63},"grabbingEnabled":false,"droppingEnabled":false,"halosEnabled":true,"fixedWidth":true,"fixedHeight":false,"allowsInput":true,"_OverflowMode":"visible","_FontFamily":"Arial, sans-serif","registeredForMouseEvents":true,"_MaxTextWidth":93.8018403394826,"_MaxTextHeight":null,"showsHalos":false,"_FontSize":8,"name":"NameLabel","partsBinMetaInfo":{"__isSmartRef__":true,"id":64},"textChunks":[{"__isSmartRef__":true,"id":65}],"charsReplaced":"Grr","lastFindLoc":-3,"prevScroll":[0,0],"attributeConnections":[{"__isSmartRef__":true,"id":67},{"__isSmartRef__":true,"id":68}],"doNotSerialize":["$$owner","$$savedTextString"],"doNotCopyProperties":["$$owner","$$savedTextString"],"oldOwner":{"__isSmartRef__":true,"id":61},"isInputLine":true,"eventsAreIgnored":true,"eventHandler":{"__isSmartRef__":true,"id":69},"_HandStyle":"default","_PointerEvents":"none","owner":{"__isSmartRef__":true,"id":61},"savedTextString":"TopLeft","derivationIds":[97,"B50EF154-E04B-40B0-8460-786994FB6E51"],"_WhiteSpaceHandling":"pre-wrap","_ClipMode":"visible","_Rotation":0,"_Scale":1.0030060100150207,"__serializedExpressions__":["_Position","textColor","distanceToDragEvent"],"__serializedLivelyClosures__":{"__isSmartRef__":true,"id":70},"__LivelyClassName__":"lively.morphic.Text","__SourceModuleName__":"Global.lively.morphic.TextCore","_Position":"lively.pt(14.0,11.0)","textColor":"Color.rgb(0,0,0)","distanceToDragEvent":"lively.pt(78.0,-15.0)"},"63":{"fill":null,"_BorderWidth":0,"__serializedExpressions__":["_Position","_Extent","_BorderColor","_Padding"],"__LivelyClassName__":"lively.morphic.Shapes.Rectangle","__SourceModuleName__":"Global.lively.morphic.Shapes","_Position":"lively.pt(0.0,0.0)","_Extent":"lively.pt(93.8,14.0)","_BorderColor":"Color.rgb(0,0,0)","_Padding":"lively.rect(0,0,0,0)"},"64":{"partsSpaceName":"PartsBin/NewWorld","migrationLevel":2,"comment":"Label that shows the name of a morph. Updates automatically.","__LivelyClassName__":"lively.PartsBin.PartsBinMetaInfo","__SourceModuleName__":"Global.lively.PartsBin"},"65":{"style":{"__isSmartRef__":true,"id":66},"chunkOwner":{"__isSmartRef__":true,"id":62},"_id":"_513","storedString":"PhysicsBehavior1","__LivelyClassName__":"lively.morphic.TextChunk","__SourceModuleName__":"Global.lively.morphic.TextCore"},"66":{"__LivelyClassName__":"lively.morphic.TextEmphasis","__SourceModuleName__":"Global.lively.morphic.TextCore"},"67":{"sourceObj":{"__isSmartRef__":true,"id":62},"sourceAttrName":"owner","targetObj":{"__isSmartRef__":true,"id":62},"targetMethodName":"updateLabel","converterString":null,"updaterString":null,"__LivelyClassName__":"AttributeConnection","__SourceModuleName__":"Global.lively.bindings.Core"},"68":{"sourceObj":{"__isSmartRef__":true,"id":62},"sourceAttrName":"savedTextString","targetObj":{"__isSmartRef__":true,"id":62},"targetMethodName":"renameOwner","__LivelyClassName__":"AttributeConnection","__SourceModuleName__":"Global.lively.bindings.Core"},"69":{"morph":{"__isSmartRef__":true,"id":62},"__LivelyClassName__":"lively.morphic.EventHandler","__SourceModuleName__":"Global.lively.morphic.Events"},"70":{"updateLabel":{"__isSmartRef__":true,"id":71},"renameOwner":{"__isSmartRef__":true,"id":74}},"71":{"varMapping":{"__isSmartRef__":true,"id":72},"source":"function updateLabel() {\n\t// observe name changes in owner\n\tif (this.owner !== this.oldOwner) {\n\t\tif (this.oldOwner)\n\t\t\tdisconnect(this.oldOwner, 'name', this, 'updateLabel')\n\t\tif (this.owner)\n\t\t\tconnect(this.owner, 'name', this, 'updateLabel')\n\t\tthis.oldOwner = this.owner\n\t}\n\tvar name = (this.owner ? this.owner.name : \"no owner\")\n\tif (this.textString != name)\n\tthis.setTextString(name)\n}","funcProperties":{"__isSmartRef__":true,"id":73},"__LivelyClassName__":"lively.Closure","__SourceModuleName__":"Global.lively.lang.Closure"},"72":{"this":{"__isSmartRef__":true,"id":62}},"73":{},"74":{"varMapping":{"__isSmartRef__":true,"id":75},"source":"function renameOwner(name) {\n\tif (this.owner && this.owner.name != name) {\n\t\talertOK(\"renamed \" + this.owner + \" to \" + name)\n\t\tthis.owner.setName(name);\n\t}\n}","funcProperties":{"__isSmartRef__":true,"id":76},"__LivelyClassName__":"lively.Closure","__SourceModuleName__":"Global.lively.lang.Closure"},"75":{"this":{"__isSmartRef__":true,"id":62}},"76":{},"77":{"_BorderWidth":0,"_BorderRadius":20.71,"__serializedExpressions__":["position","_Extent","_BorderColor","_Fill","_Padding"],"__LivelyClassName__":"lively.morphic.Shapes.Rectangle","__SourceModuleName__":"Global.lively.morphic.Shapes","position":"lively.pt(0.0,0.0)","_Extent":"lively.pt(122.0,34.0)","_BorderColor":"Color.rgb(28,0,153)","_Fill":"Color.rgb(214,214,214)","_Padding":"lively.rect(0,0,0,0)"},"78":{"partsSpaceName":"PartsBin/DroppableBehaviors/","comment":"A simple box morph","migrationLevel":4,"partName":"ThrobbingBehavior","__serializedExpressions__":["lastModifiedDate"],"__LivelyClassName__":"lively.PartsBin.PartsBinMetaInfo","__SourceModuleName__":"Global.lively.PartsBin","lastModifiedDate":"new Date(\"Wed Sep 05 2012 16:01:35 GMT-0700 (Pacific Daylight Time)\")"},"79":{"sourceObj":{"__isSmartRef__":true,"id":61},"sourceAttrName":"name","targetObj":{"__isSmartRef__":true,"id":62},"targetMethodName":"updateLabel","converterString":null,"updaterString":null,"__LivelyClassName__":"AttributeConnection","__SourceModuleName__":"Global.lively.bindings.Core"},"80":{"traitName":"lively.morphic.DraggableBehavior","options":{"__isSmartRef__":true,"id":81}},"81":{"override":["onDragStart","onDragEnd"]},"82":{"morph":{"__isSmartRef__":true,"id":61},"__LivelyClassName__":"lively.morphic.EventHandler","__SourceModuleName__":"Global.lively.morphic.Events"},"83":{"applyTo":{"__isSmartRef__":true,"id":84},"reset":{"__isSmartRef__":true,"id":85}},"84":{"user":"robertkrahn","__serializedExpressions__":["time"],"time":"new Date(\"Fri Jul 01 2011 18:24:39 GMT-0700 (Pacific Daylight Time)\")"},"85":{"user":"robertkrahn","__serializedExpressions__":["time"],"time":"new Date(\"Fri Jul 01 2011 18:24:47 GMT-0700 (Pacific Daylight Time)\")"},"86":{"submorphs":[{"__isSmartRef__":true,"id":87}],"scripts":[],"id":"1E1386EF-6986-4D07-A995-C36A23FE3052","shape":{"__isSmartRef__":true,"id":102},"droppingEnabled":true,"halosEnabled":true,"registeredForMouseEvents":true,"showsHalos":false,"partsBinMetaInfo":{"__isSmartRef__":true,"id":103},"__layered_draggingEnabled__":true,"attributeConnections":[{"__isSmartRef__":true,"id":104}],"doNotSerialize":["$$name"],"doNotCopyProperties":["$$name"],"_traitConfig_":[{"__isSmartRef__":true,"id":105}],"eventHandler":{"__isSmartRef__":true,"id":107},"scriptAnnotations":{"__isSmartRef__":true,"id":108},"name":"PhysicsBehavior1","derivationIds":[96,"35401CB0-4E04-4239-B9FF-E923F329A369"],"_ClipMode":"visible","icon":{"__isSmartRef__":true,"id":111},"owner":null,"_Rotation":0,"_Scale":1,"__serializedExpressions__":["_Position","dropColor","previousPosition"],"__serializedLivelyClosures__":{"__isSmartRef__":true,"id":237},"__LivelyClassName__":"lively.morphic.Box","__SourceModuleName__":"Global.lively.morphic.Core","_Position":"lively.pt(-109.0,-19.0)","dropColor":"Color.rgb(0,79,152)","previousPosition":"lively.pt(-109.0,-19.0)"},"87":{"submorphs":[],"scripts":[],"id":"33F07B76-A05A-4CE1-A4B9-73E6BF83C278","shape":{"__isSmartRef__":true,"id":88},"grabbingEnabled":false,"droppingEnabled":false,"halosEnabled":true,"fixedWidth":true,"fixedHeight":false,"allowsInput":true,"_OverflowMode":"visible","_FontFamily":"Arial, sans-serif","registeredForMouseEvents":true,"_MaxTextWidth":93.8018403394826,"_MaxTextHeight":null,"showsHalos":false,"_FontSize":8,"name":"NameLabel","partsBinMetaInfo":{"__isSmartRef__":true,"id":89},"textChunks":[{"__isSmartRef__":true,"id":90}],"charsReplaced":"Grr","lastFindLoc":-3,"prevScroll":[0,0],"attributeConnections":[{"__isSmartRef__":true,"id":92},{"__isSmartRef__":true,"id":93}],"doNotSerialize":["$$owner","$$savedTextString"],"doNotCopyProperties":["$$owner","$$savedTextString"],"oldOwner":{"__isSmartRef__":true,"id":86},"isInputLine":true,"eventsAreIgnored":true,"eventHandler":{"__isSmartRef__":true,"id":94},"_HandStyle":"default","_PointerEvents":"none","owner":{"__isSmartRef__":true,"id":86},"savedTextString":"TopLeft","derivationIds":[97,"B50EF154-E04B-40B0-8460-786994FB6E51"],"_WhiteSpaceHandling":"pre-wrap","_ClipMode":"visible","_Rotation":0,"_Scale":1.0030060100150207,"__serializedExpressions__":["_Position","textColor","distanceToDragEvent"],"__serializedLivelyClosures__":{"__isSmartRef__":true,"id":95},"__LivelyClassName__":"lively.morphic.Text","__SourceModuleName__":"Global.lively.morphic.TextCore","_Position":"lively.pt(14.0,11.0)","textColor":"Color.rgb(0,0,0)","distanceToDragEvent":"lively.pt(78.0,-15.0)"},"88":{"fill":null,"_BorderWidth":0,"__serializedExpressions__":["_Position","_Extent","_BorderColor","_Padding"],"__LivelyClassName__":"lively.morphic.Shapes.Rectangle","__SourceModuleName__":"Global.lively.morphic.Shapes","_Position":"lively.pt(0.0,0.0)","_Extent":"lively.pt(93.8,14.0)","_BorderColor":"Color.rgb(0,0,0)","_Padding":"lively.rect(0,0,0,0)"},"89":{"partsSpaceName":"PartsBin/NewWorld","migrationLevel":2,"comment":"Label that shows the name of a morph. Updates automatically.","__LivelyClassName__":"lively.PartsBin.PartsBinMetaInfo","__SourceModuleName__":"Global.lively.PartsBin"},"90":{"style":{"__isSmartRef__":true,"id":91},"chunkOwner":{"__isSmartRef__":true,"id":87},"_id":"_1371","storedString":"PhysicsBehavior1","__LivelyClassName__":"lively.morphic.TextChunk","__SourceModuleName__":"Global.lively.morphic.TextCore"},"91":{"__LivelyClassName__":"lively.morphic.TextEmphasis","__SourceModuleName__":"Global.lively.morphic.TextCore"},"92":{"sourceObj":{"__isSmartRef__":true,"id":87},"sourceAttrName":"owner","targetObj":{"__isSmartRef__":true,"id":87},"targetMethodName":"updateLabel","converterString":null,"updaterString":null,"__LivelyClassName__":"AttributeConnection","__SourceModuleName__":"Global.lively.bindings.Core"},"93":{"sourceObj":{"__isSmartRef__":true,"id":87},"sourceAttrName":"savedTextString","targetObj":{"__isSmartRef__":true,"id":87},"targetMethodName":"renameOwner","__LivelyClassName__":"AttributeConnection","__SourceModuleName__":"Global.lively.bindings.Core"},"94":{"morph":{"__isSmartRef__":true,"id":87},"__LivelyClassName__":"lively.morphic.EventHandler","__SourceModuleName__":"Global.lively.morphic.Events"},"95":{"updateLabel":{"__isSmartRef__":true,"id":96},"renameOwner":{"__isSmartRef__":true,"id":99}},"96":{"varMapping":{"__isSmartRef__":true,"id":97},"source":"function updateLabel() {\n\t// observe name changes in owner\n\tif (this.owner !== this.oldOwner) {\n\t\tif (this.oldOwner)\n\t\t\tdisconnect(this.oldOwner, 'name', this, 'updateLabel')\n\t\tif (this.owner)\n\t\t\tconnect(this.owner, 'name', this, 'updateLabel')\n\t\tthis.oldOwner = this.owner\n\t}\n\tvar name = (this.owner ? this.owner.name : \"no owner\")\n\tif (this.textString != name)\n\tthis.setTextString(name)\n}","funcProperties":{"__isSmartRef__":true,"id":98},"__LivelyClassName__":"lively.Closure","__SourceModuleName__":"Global.lively.lang.Closure"},"97":{"this":{"__isSmartRef__":true,"id":87}},"98":{},"99":{"varMapping":{"__isSmartRef__":true,"id":100},"source":"function renameOwner(name) {\n\tif (this.owner && this.owner.name != name) {\n\t\talertOK(\"renamed \" + this.owner + \" to \" + name)\n\t\tthis.owner.setName(name);\n\t}\n}","funcProperties":{"__isSmartRef__":true,"id":101},"__LivelyClassName__":"lively.Closure","__SourceModuleName__":"Global.lively.lang.Closure"},"100":{"this":{"__isSmartRef__":true,"id":87}},"101":{},"102":{"_BorderWidth":0,"_BorderRadius":20.71,"__serializedExpressions__":["position","_Extent","_BorderColor","_Fill","_Padding"],"__LivelyClassName__":"lively.morphic.Shapes.Rectangle","__SourceModuleName__":"Global.lively.morphic.Shapes","position":"lively.pt(0.0,0.0)","_Extent":"lively.pt(122.0,34.0)","_BorderColor":"Color.rgb(28,0,153)","_Fill":"Color.rgb(214,214,214)","_Padding":"lively.rect(0,0,0,0)"},"103":{"partsSpaceName":"PartsBin/DroppableBehaviors/","comment":"A simple box morph","migrationLevel":4,"partName":"ThrobbingBehavior","__serializedExpressions__":["lastModifiedDate"],"__LivelyClassName__":"lively.PartsBin.PartsBinMetaInfo","__SourceModuleName__":"Global.lively.PartsBin","lastModifiedDate":"new Date(\"Wed Sep 05 2012 16:01:35 GMT-0700 (Pacific Daylight Time)\")"},"104":{"sourceObj":{"__isSmartRef__":true,"id":86},"sourceAttrName":"name","targetObj":{"__isSmartRef__":true,"id":87},"targetMethodName":"updateLabel","converterString":null,"updaterString":null,"__LivelyClassName__":"AttributeConnection","__SourceModuleName__":"Global.lively.bindings.Core"},"105":{"traitName":"lively.morphic.DraggableBehavior","options":{"__isSmartRef__":true,"id":106}},"106":{"override":["onDragStart","onDragEnd"]},"107":{"morph":{"__isSmartRef__":true,"id":86},"__LivelyClassName__":"lively.morphic.EventHandler","__SourceModuleName__":"Global.lively.morphic.Events"},"108":{"applyTo":{"__isSmartRef__":true,"id":109},"reset":{"__isSmartRef__":true,"id":110}},"109":{"user":"robertkrahn","__serializedExpressions__":["time"],"time":"new Date(\"Fri Jul 01 2011 18:24:39 GMT-0700 (Pacific Daylight Time)\")"},"110":{"user":"robertkrahn","__serializedExpressions__":["time"],"time":"new Date(\"Fri Jul 01 2011 18:24:47 GMT-0700 (Pacific Daylight Time)\")"},"111":{"submorphs":[{"__isSmartRef__":true,"id":112}],"scripts":[],"id":"55A21474-E64A-4675-A976-BE8B518DA3C6","shape":{"__isSmartRef__":true,"id":127},"droppingEnabled":true,"halosEnabled":true,"registeredForMouseEvents":true,"showsHalos":false,"partsBinMetaInfo":{"__isSmartRef__":true,"id":128},"__layered_draggingEnabled__":true,"attributeConnections":[{"__isSmartRef__":true,"id":129}],"doNotSerialize":["$$name"],"doNotCopyProperties":["$$name"],"_traitConfig_":[{"__isSmartRef__":true,"id":130}],"eventHandler":{"__isSmartRef__":true,"id":132},"scriptAnnotations":{"__isSmartRef__":true,"id":133},"name":"PhysicsBehavior1","derivationIds":[96,"35401CB0-4E04-4239-B9FF-E923F329A369"],"_ClipMode":"visible","icon":{"__isSmartRef__":true,"id":136},"owner":null,"_Rotation":0,"_Scale":1,"__serializedExpressions__":["_Position","dropColor","previousPosition"],"__serializedLivelyClosures__":{"__isSmartRef__":true,"id":220},"__LivelyClassName__":"lively.morphic.Box","__SourceModuleName__":"Global.lively.morphic.Core","_Position":"lively.pt(-106.0,-16.0)","dropColor":"Color.rgb(0,79,152)","previousPosition":"lively.pt(-106.0,-16.0)"},"112":{"submorphs":[],"scripts":[],"id":"C65CA62E-A2C2-4ADA-82F1-1CAC681742F8","shape":{"__isSmartRef__":true,"id":113},"grabbingEnabled":false,"droppingEnabled":false,"halosEnabled":true,"fixedWidth":true,"fixedHeight":false,"allowsInput":true,"_OverflowMode":"visible","_FontFamily":"Arial, sans-serif","registeredForMouseEvents":true,"_MaxTextWidth":93.8018403394826,"_MaxTextHeight":null,"showsHalos":false,"_FontSize":8,"name":"NameLabel","partsBinMetaInfo":{"__isSmartRef__":true,"id":114},"textChunks":[{"__isSmartRef__":true,"id":115}],"charsReplaced":"Grr","lastFindLoc":-3,"prevScroll":[0,0],"attributeConnections":[{"__isSmartRef__":true,"id":117},{"__isSmartRef__":true,"id":118}],"doNotSerialize":["$$owner","$$savedTextString"],"doNotCopyProperties":["$$owner","$$savedTextString"],"oldOwner":{"__isSmartRef__":true,"id":111},"isInputLine":true,"eventsAreIgnored":true,"eventHandler":{"__isSmartRef__":true,"id":119},"_HandStyle":"default","_PointerEvents":"none","owner":{"__isSmartRef__":true,"id":111},"savedTextString":"TopLeft","derivationIds":[97,"B50EF154-E04B-40B0-8460-786994FB6E51"],"_WhiteSpaceHandling":"pre-wrap","_ClipMode":"visible","_Rotation":0,"_Scale":1.0030060100150207,"__serializedExpressions__":["_Position","textColor","distanceToDragEvent"],"__serializedLivelyClosures__":{"__isSmartRef__":true,"id":120},"__LivelyClassName__":"lively.morphic.Text","__SourceModuleName__":"Global.lively.morphic.TextCore","_Position":"lively.pt(14.0,11.0)","textColor":"Color.rgb(0,0,0)","distanceToDragEvent":"lively.pt(78.0,-15.0)"},"113":{"fill":null,"_BorderWidth":0,"__serializedExpressions__":["_Position","_Extent","_BorderColor","_Padding"],"__LivelyClassName__":"lively.morphic.Shapes.Rectangle","__SourceModuleName__":"Global.lively.morphic.Shapes","_Position":"lively.pt(0.0,0.0)","_Extent":"lively.pt(93.8,14.0)","_BorderColor":"Color.rgb(0,0,0)","_Padding":"lively.rect(0,0,0,0)"},"114":{"partsSpaceName":"PartsBin/NewWorld","migrationLevel":2,"comment":"Label that shows the name of a morph. Updates automatically.","__LivelyClassName__":"lively.PartsBin.PartsBinMetaInfo","__SourceModuleName__":"Global.lively.PartsBin"},"115":{"style":{"__isSmartRef__":true,"id":116},"chunkOwner":{"__isSmartRef__":true,"id":112},"_id":"_1361","storedString":"PhysicsBehavior1","__LivelyClassName__":"lively.morphic.TextChunk","__SourceModuleName__":"Global.lively.morphic.TextCore"},"116":{"__LivelyClassName__":"lively.morphic.TextEmphasis","__SourceModuleName__":"Global.lively.morphic.TextCore"},"117":{"sourceObj":{"__isSmartRef__":true,"id":112},"sourceAttrName":"owner","targetObj":{"__isSmartRef__":true,"id":112},"targetMethodName":"updateLabel","converterString":null,"updaterString":null,"__LivelyClassName__":"AttributeConnection","__SourceModuleName__":"Global.lively.bindings.Core"},"118":{"sourceObj":{"__isSmartRef__":true,"id":112},"sourceAttrName":"savedTextString","targetObj":{"__isSmartRef__":true,"id":112},"targetMethodName":"renameOwner","__LivelyClassName__":"AttributeConnection","__SourceModuleName__":"Global.lively.bindings.Core"},"119":{"morph":{"__isSmartRef__":true,"id":112},"__LivelyClassName__":"lively.morphic.EventHandler","__SourceModuleName__":"Global.lively.morphic.Events"},"120":{"updateLabel":{"__isSmartRef__":true,"id":121},"renameOwner":{"__isSmartRef__":true,"id":124}},"121":{"varMapping":{"__isSmartRef__":true,"id":122},"source":"function updateLabel() {\n\t// observe name changes in owner\n\tif (this.owner !== this.oldOwner) {\n\t\tif (this.oldOwner)\n\t\t\tdisconnect(this.oldOwner, 'name', this, 'updateLabel')\n\t\tif (this.owner)\n\t\t\tconnect(this.owner, 'name', this, 'updateLabel')\n\t\tthis.oldOwner = this.owner\n\t}\n\tvar name = (this.owner ? this.owner.name : \"no owner\")\n\tif (this.textString != name)\n\tthis.setTextString(name)\n}","funcProperties":{"__isSmartRef__":true,"id":123},"__LivelyClassName__":"lively.Closure","__SourceModuleName__":"Global.lively.lang.Closure"},"122":{"this":{"__isSmartRef__":true,"id":112}},"123":{},"124":{"varMapping":{"__isSmartRef__":true,"id":125},"source":"function renameOwner(name) {\n\tif (this.owner && this.owner.name != name) {\n\t\talertOK(\"renamed \" + this.owner + \" to \" + name)\n\t\tthis.owner.setName(name);\n\t}\n}","funcProperties":{"__isSmartRef__":true,"id":126},"__LivelyClassName__":"lively.Closure","__SourceModuleName__":"Global.lively.lang.Closure"},"125":{"this":{"__isSmartRef__":true,"id":112}},"126":{},"127":{"_BorderWidth":0,"_BorderRadius":20.71,"__serializedExpressions__":["position","_Extent","_BorderColor","_Fill","_Padding"],"__LivelyClassName__":"lively.morphic.Shapes.Rectangle","__SourceModuleName__":"Global.lively.morphic.Shapes","position":"lively.pt(0.0,0.0)","_Extent":"lively.pt(122.0,34.0)","_BorderColor":"Color.rgb(28,0,153)","_Fill":"Color.rgb(214,214,214)","_Padding":"lively.rect(0,0,0,0)"},"128":{"partsSpaceName":"PartsBin/DroppableBehaviors/","comment":"A simple box morph","migrationLevel":4,"partName":"ThrobbingBehavior","__serializedExpressions__":["lastModifiedDate"],"__LivelyClassName__":"lively.PartsBin.PartsBinMetaInfo","__SourceModuleName__":"Global.lively.PartsBin","lastModifiedDate":"new Date(\"Wed Sep 05 2012 16:01:35 GMT-0700 (Pacific Daylight Time)\")"},"129":{"sourceObj":{"__isSmartRef__":true,"id":111},"sourceAttrName":"name","targetObj":{"__isSmartRef__":true,"id":112},"targetMethodName":"updateLabel","converterString":null,"updaterString":null,"__LivelyClassName__":"AttributeConnection","__SourceModuleName__":"Global.lively.bindings.Core"},"130":{"traitName":"lively.morphic.DraggableBehavior","options":{"__isSmartRef__":true,"id":131}},"131":{"override":["onDragStart","onDragEnd"]},"132":{"morph":{"__isSmartRef__":true,"id":111},"__LivelyClassName__":"lively.morphic.EventHandler","__SourceModuleName__":"Global.lively.morphic.Events"},"133":{"applyTo":{"__isSmartRef__":true,"id":134},"reset":{"__isSmartRef__":true,"id":135}},"134":{"user":"robertkrahn","__serializedExpressions__":["time"],"time":"new Date(\"Fri Jul 01 2011 18:24:39 GMT-0700 (Pacific Daylight Time)\")"},"135":{"user":"robertkrahn","__serializedExpressions__":["time"],"time":"new Date(\"Fri Jul 01 2011 18:24:47 GMT-0700 (Pacific Daylight Time)\")"},"136":{"submorphs":[{"__isSmartRef__":true,"id":137}],"scripts":[],"id":"5368BB9E-E229-4856-AB84-927C1FD72743","shape":{"__isSmartRef__":true,"id":152},"droppingEnabled":true,"halosEnabled":true,"registeredForMouseEvents":true,"showsHalos":false,"partsBinMetaInfo":{"__isSmartRef__":true,"id":153},"__layered_draggingEnabled__":true,"attributeConnections":[{"__isSmartRef__":true,"id":154}],"doNotSerialize":["$$name"],"doNotCopyProperties":["$$name"],"_traitConfig_":[{"__isSmartRef__":true,"id":155}],"eventHandler":{"__isSmartRef__":true,"id":157},"scriptAnnotations":{"__isSmartRef__":true,"id":158},"name":"PhysicsBehavior1","derivationIds":[96,"35401CB0-4E04-4239-B9FF-E923F329A369"],"_ClipMode":"visible","icon":{"__isSmartRef__":true,"id":161},"owner":null,"_Rotation":0,"_Scale":1,"__serializedExpressions__":["_Position","dropColor","previousPosition"],"__serializedLivelyClosures__":{"__isSmartRef__":true,"id":203},"__LivelyClassName__":"lively.morphic.Box","__SourceModuleName__":"Global.lively.morphic.Core","_Position":"lively.pt(-106.0,-20.0)","dropColor":"Color.rgb(0,79,152)","previousPosition":"lively.pt(-106.0,-20.0)"},"137":{"submorphs":[],"scripts":[],"id":"2D6A5CB3-50D3-42B5-90C3-876B5A619A87","shape":{"__isSmartRef__":true,"id":138},"grabbingEnabled":false,"droppingEnabled":false,"halosEnabled":true,"fixedWidth":true,"fixedHeight":false,"allowsInput":true,"_OverflowMode":"visible","_FontFamily":"Arial, sans-serif","registeredForMouseEvents":true,"_MaxTextWidth":93.8018403394826,"_MaxTextHeight":null,"showsHalos":false,"_FontSize":8,"name":"NameLabel","partsBinMetaInfo":{"__isSmartRef__":true,"id":139},"textChunks":[{"__isSmartRef__":true,"id":140}],"charsReplaced":"Grr","lastFindLoc":-3,"prevScroll":[0,0],"attributeConnections":[{"__isSmartRef__":true,"id":142},{"__isSmartRef__":true,"id":143}],"doNotSerialize":["$$owner","$$savedTextString"],"doNotCopyProperties":["$$owner","$$savedTextString"],"oldOwner":{"__isSmartRef__":true,"id":136},"isInputLine":true,"eventsAreIgnored":true,"eventHandler":{"__isSmartRef__":true,"id":144},"_HandStyle":"default","_PointerEvents":"none","owner":{"__isSmartRef__":true,"id":136},"savedTextString":"TopLeft","derivationIds":[97,"B50EF154-E04B-40B0-8460-786994FB6E51"],"_WhiteSpaceHandling":"pre-wrap","_ClipMode":"visible","_Rotation":0,"_Scale":1.0030060100150207,"__serializedExpressions__":["_Position","textColor","distanceToDragEvent"],"__serializedLivelyClosures__":{"__isSmartRef__":true,"id":145},"__LivelyClassName__":"lively.morphic.Text","__SourceModuleName__":"Global.lively.morphic.TextCore","_Position":"lively.pt(14.0,11.0)","textColor":"Color.rgb(0,0,0)","distanceToDragEvent":"lively.pt(78.0,-15.0)"},"138":{"fill":null,"_BorderWidth":0,"__serializedExpressions__":["_Position","_Extent","_BorderColor","_Padding"],"__LivelyClassName__":"lively.morphic.Shapes.Rectangle","__SourceModuleName__":"Global.lively.morphic.Shapes","_Position":"lively.pt(0.0,0.0)","_Extent":"lively.pt(93.8,14.0)","_BorderColor":"Color.rgb(0,0,0)","_Padding":"lively.rect(0,0,0,0)"},"139":{"partsSpaceName":"PartsBin/NewWorld","migrationLevel":2,"comment":"Label that shows the name of a morph. Updates automatically.","__LivelyClassName__":"lively.PartsBin.PartsBinMetaInfo","__SourceModuleName__":"Global.lively.PartsBin"},"140":{"style":{"__isSmartRef__":true,"id":141},"chunkOwner":{"__isSmartRef__":true,"id":137},"_id":"_1355","storedString":"PhysicsBehavior1","__LivelyClassName__":"lively.morphic.TextChunk","__SourceModuleName__":"Global.lively.morphic.TextCore"},"141":{"__LivelyClassName__":"lively.morphic.TextEmphasis","__SourceModuleName__":"Global.lively.morphic.TextCore"},"142":{"sourceObj":{"__isSmartRef__":true,"id":137},"sourceAttrName":"owner","targetObj":{"__isSmartRef__":true,"id":137},"targetMethodName":"updateLabel","converterString":null,"updaterString":null,"__LivelyClassName__":"AttributeConnection","__SourceModuleName__":"Global.lively.bindings.Core"},"143":{"sourceObj":{"__isSmartRef__":true,"id":137},"sourceAttrName":"savedTextString","targetObj":{"__isSmartRef__":true,"id":137},"targetMethodName":"renameOwner","__LivelyClassName__":"AttributeConnection","__SourceModuleName__":"Global.lively.bindings.Core"},"144":{"morph":{"__isSmartRef__":true,"id":137},"__LivelyClassName__":"lively.morphic.EventHandler","__SourceModuleName__":"Global.lively.morphic.Events"},"145":{"updateLabel":{"__isSmartRef__":true,"id":146},"renameOwner":{"__isSmartRef__":true,"id":149}},"146":{"varMapping":{"__isSmartRef__":true,"id":147},"source":"function updateLabel() {\n\t// observe name changes in owner\n\tif (this.owner !== this.oldOwner) {\n\t\tif (this.oldOwner)\n\t\t\tdisconnect(this.oldOwner, 'name', this, 'updateLabel')\n\t\tif (this.owner)\n\t\t\tconnect(this.owner, 'name', this, 'updateLabel')\n\t\tthis.oldOwner = this.owner\n\t}\n\tvar name = (this.owner ? this.owner.name : \"no owner\")\n\tif (this.textString != name)\n\tthis.setTextString(name)\n}","funcProperties":{"__isSmartRef__":true,"id":148},"__LivelyClassName__":"lively.Closure","__SourceModuleName__":"Global.lively.lang.Closure"},"147":{"this":{"__isSmartRef__":true,"id":137}},"148":{},"149":{"varMapping":{"__isSmartRef__":true,"id":150},"source":"function renameOwner(name) {\n\tif (this.owner && this.owner.name != name) {\n\t\talertOK(\"renamed \" + this.owner + \" to \" + name)\n\t\tthis.owner.setName(name);\n\t}\n}","funcProperties":{"__isSmartRef__":true,"id":151},"__LivelyClassName__":"lively.Closure","__SourceModuleName__":"Global.lively.lang.Closure"},"150":{"this":{"__isSmartRef__":true,"id":137}},"151":{},"152":{"_BorderWidth":0,"_BorderRadius":20.71,"__serializedExpressions__":["position","_Extent","_BorderColor","_Fill","_Padding"],"__LivelyClassName__":"lively.morphic.Shapes.Rectangle","__SourceModuleName__":"Global.lively.morphic.Shapes","position":"lively.pt(0.0,0.0)","_Extent":"lively.pt(122.0,34.0)","_BorderColor":"Color.rgb(28,0,153)","_Fill":"Color.rgb(214,214,214)","_Padding":"lively.rect(0,0,0,0)"},"153":{"partsSpaceName":"PartsBin/DroppableBehaviors/","comment":"A simple box morph","migrationLevel":4,"partName":"ThrobbingBehavior","__serializedExpressions__":["lastModifiedDate"],"__LivelyClassName__":"lively.PartsBin.PartsBinMetaInfo","__SourceModuleName__":"Global.lively.PartsBin","lastModifiedDate":"new Date(\"Wed Sep 05 2012 16:01:35 GMT-0700 (Pacific Daylight Time)\")"},"154":{"sourceObj":{"__isSmartRef__":true,"id":136},"sourceAttrName":"name","targetObj":{"__isSmartRef__":true,"id":137},"targetMethodName":"updateLabel","converterString":null,"updaterString":null,"__LivelyClassName__":"AttributeConnection","__SourceModuleName__":"Global.lively.bindings.Core"},"155":{"traitName":"lively.morphic.DraggableBehavior","options":{"__isSmartRef__":true,"id":156}},"156":{"override":["onDragStart","onDragEnd"]},"157":{"morph":{"__isSmartRef__":true,"id":136},"__LivelyClassName__":"lively.morphic.EventHandler","__SourceModuleName__":"Global.lively.morphic.Events"},"158":{"applyTo":{"__isSmartRef__":true,"id":159},"reset":{"__isSmartRef__":true,"id":160}},"159":{"user":"robertkrahn","__serializedExpressions__":["time"],"time":"new Date(\"Fri Jul 01 2011 18:24:39 GMT-0700 (Pacific Daylight Time)\")"},"160":{"user":"robertkrahn","__serializedExpressions__":["time"],"time":"new Date(\"Fri Jul 01 2011 18:24:47 GMT-0700 (Pacific Daylight Time)\")"},"161":{"submorphs":[{"__isSmartRef__":true,"id":162}],"scripts":[],"id":"FAEEDDD5-EEC7-4456-80D9-DB08782AFEF4","shape":{"__isSmartRef__":true,"id":177},"droppingEnabled":true,"halosEnabled":true,"registeredForMouseEvents":true,"showsHalos":false,"partsBinMetaInfo":{"__isSmartRef__":true,"id":178},"__layered_draggingEnabled__":true,"attributeConnections":[{"__isSmartRef__":true,"id":179}],"doNotSerialize":["$$name"],"doNotCopyProperties":["$$name"],"_traitConfig_":[{"__isSmartRef__":true,"id":180}],"eventHandler":{"__isSmartRef__":true,"id":182},"scriptAnnotations":{"__isSmartRef__":true,"id":183},"name":"PhysicsBehavior1","derivationIds":[96,"35401CB0-4E04-4239-B9FF-E923F329A369"],"_ClipMode":"visible","owner":null,"_Rotation":0,"_Scale":1,"__serializedExpressions__":["_Position","dropColor","previousPosition"],"__serializedLivelyClosures__":{"__isSmartRef__":true,"id":186},"__LivelyClassName__":"lively.morphic.Box","__SourceModuleName__":"Global.lively.morphic.Core","_Position":"lively.pt(-93.0,-6.0)","dropColor":"Color.rgb(0,79,152)","previousPosition":"lively.pt(-93.0,-6.0)"},"162":{"submorphs":[],"scripts":[],"id":"8BF9072B-0342-425F-B057-045BC56F1B4A","shape":{"__isSmartRef__":true,"id":163},"grabbingEnabled":false,"droppingEnabled":false,"halosEnabled":true,"fixedWidth":true,"fixedHeight":false,"allowsInput":true,"_OverflowMode":"visible","_FontFamily":"Arial, sans-serif","registeredForMouseEvents":true,"_MaxTextWidth":93.8018403394826,"_MaxTextHeight":null,"showsHalos":false,"_FontSize":8,"name":"NameLabel","partsBinMetaInfo":{"__isSmartRef__":true,"id":164},"textChunks":[{"__isSmartRef__":true,"id":165}],"charsReplaced":"Grr","lastFindLoc":-3,"prevScroll":[0,0],"attributeConnections":[{"__isSmartRef__":true,"id":167},{"__isSmartRef__":true,"id":168}],"doNotSerialize":["$$owner","$$savedTextString"],"doNotCopyProperties":["$$owner","$$savedTextString"],"oldOwner":{"__isSmartRef__":true,"id":161},"isInputLine":true,"eventsAreIgnored":true,"eventHandler":{"__isSmartRef__":true,"id":169},"_HandStyle":"default","_PointerEvents":"none","owner":{"__isSmartRef__":true,"id":161},"savedTextString":"TopLeft","derivationIds":[97,"B50EF154-E04B-40B0-8460-786994FB6E51"],"_WhiteSpaceHandling":"pre-wrap","_ClipMode":"visible","_Rotation":0,"_Scale":1.0030060100150207,"__serializedExpressions__":["_Position","textColor","distanceToDragEvent"],"__serializedLivelyClosures__":{"__isSmartRef__":true,"id":170},"__LivelyClassName__":"lively.morphic.Text","__SourceModuleName__":"Global.lively.morphic.TextCore","_Position":"lively.pt(14.0,11.0)","textColor":"Color.rgb(0,0,0)","distanceToDragEvent":"lively.pt(78.0,-15.0)"},"163":{"fill":null,"_BorderWidth":0,"__serializedExpressions__":["_Position","_Extent","_BorderColor","_Padding"],"__LivelyClassName__":"lively.morphic.Shapes.Rectangle","__SourceModuleName__":"Global.lively.morphic.Shapes","_Position":"lively.pt(0.0,0.0)","_Extent":"lively.pt(93.8,14.0)","_BorderColor":"Color.rgb(0,0,0)","_Padding":"lively.rect(0,0,0,0)"},"164":{"partsSpaceName":"PartsBin/NewWorld","migrationLevel":2,"comment":"Label that shows the name of a morph. Updates automatically.","__LivelyClassName__":"lively.PartsBin.PartsBinMetaInfo","__SourceModuleName__":"Global.lively.PartsBin"},"165":{"style":{"__isSmartRef__":true,"id":166},"chunkOwner":{"__isSmartRef__":true,"id":162},"_id":"_1342","storedString":"PhysicsBehavior1","__LivelyClassName__":"lively.morphic.TextChunk","__SourceModuleName__":"Global.lively.morphic.TextCore"},"166":{"__LivelyClassName__":"lively.morphic.TextEmphasis","__SourceModuleName__":"Global.lively.morphic.TextCore"},"167":{"sourceObj":{"__isSmartRef__":true,"id":162},"sourceAttrName":"owner","targetObj":{"__isSmartRef__":true,"id":162},"targetMethodName":"updateLabel","converterString":null,"updaterString":null,"__LivelyClassName__":"AttributeConnection","__SourceModuleName__":"Global.lively.bindings.Core"},"168":{"sourceObj":{"__isSmartRef__":true,"id":162},"sourceAttrName":"savedTextString","targetObj":{"__isSmartRef__":true,"id":162},"targetMethodName":"renameOwner","__LivelyClassName__":"AttributeConnection","__SourceModuleName__":"Global.lively.bindings.Core"},"169":{"morph":{"__isSmartRef__":true,"id":162},"__LivelyClassName__":"lively.morphic.EventHandler","__SourceModuleName__":"Global.lively.morphic.Events"},"170":{"updateLabel":{"__isSmartRef__":true,"id":171},"renameOwner":{"__isSmartRef__":true,"id":174}},"171":{"varMapping":{"__isSmartRef__":true,"id":172},"source":"function updateLabel() {\n\t// observe name changes in owner\n\tif (this.owner !== this.oldOwner) {\n\t\tif (this.oldOwner)\n\t\t\tdisconnect(this.oldOwner, 'name', this, 'updateLabel')\n\t\tif (this.owner)\n\t\t\tconnect(this.owner, 'name', this, 'updateLabel')\n\t\tthis.oldOwner = this.owner\n\t}\n\tvar name = (this.owner ? this.owner.name : \"no owner\")\n\tif (this.textString != name)\n\tthis.setTextString(name)\n}","funcProperties":{"__isSmartRef__":true,"id":173},"__LivelyClassName__":"lively.Closure","__SourceModuleName__":"Global.lively.lang.Closure"},"172":{"this":{"__isSmartRef__":true,"id":162}},"173":{},"174":{"varMapping":{"__isSmartRef__":true,"id":175},"source":"function renameOwner(name) {\n\tif (this.owner && this.owner.name != name) {\n\t\talertOK(\"renamed \" + this.owner + \" to \" + name)\n\t\tthis.owner.setName(name);\n\t}\n}","funcProperties":{"__isSmartRef__":true,"id":176},"__LivelyClassName__":"lively.Closure","__SourceModuleName__":"Global.lively.lang.Closure"},"175":{"this":{"__isSmartRef__":true,"id":162}},"176":{},"177":{"_BorderWidth":0,"_BorderRadius":20.71,"__serializedExpressions__":["position","_Extent","_BorderColor","_Fill","_Padding"],"__LivelyClassName__":"lively.morphic.Shapes.Rectangle","__SourceModuleName__":"Global.lively.morphic.Shapes","position":"lively.pt(0.0,0.0)","_Extent":"lively.pt(122.0,34.0)","_BorderColor":"Color.rgb(28,0,153)","_Fill":"Color.rgb(214,214,214)","_Padding":"lively.rect(0,0,0,0)"},"178":{"partsSpaceName":"PartsBin/DroppableBehaviors/","comment":"A simple box morph","migrationLevel":4,"partName":"ThrobbingBehavior","__serializedExpressions__":["lastModifiedDate"],"__LivelyClassName__":"lively.PartsBin.PartsBinMetaInfo","__SourceModuleName__":"Global.lively.PartsBin","lastModifiedDate":"new Date(\"Wed Sep 05 2012 16:01:35 GMT-0700 (Pacific Daylight Time)\")"},"179":{"sourceObj":{"__isSmartRef__":true,"id":161},"sourceAttrName":"name","targetObj":{"__isSmartRef__":true,"id":162},"targetMethodName":"updateLabel","converterString":null,"updaterString":null,"__LivelyClassName__":"AttributeConnection","__SourceModuleName__":"Global.lively.bindings.Core"},"180":{"traitName":"lively.morphic.DraggableBehavior","options":{"__isSmartRef__":true,"id":181}},"181":{"override":["onDragStart","onDragEnd"]},"182":{"morph":{"__isSmartRef__":true,"id":161},"__LivelyClassName__":"lively.morphic.EventHandler","__SourceModuleName__":"Global.lively.morphic.Events"},"183":{"applyTo":{"__isSmartRef__":true,"id":184},"reset":{"__isSmartRef__":true,"id":185}},"184":{"user":"robertkrahn","__serializedExpressions__":["time"],"time":"new Date(\"Fri Jul 01 2011 18:24:39 GMT-0700 (Pacific Daylight Time)\")"},"185":{"user":"robertkrahn","__serializedExpressions__":["time"],"time":"new Date(\"Fri Jul 01 2011 18:24:47 GMT-0700 (Pacific Daylight Time)\")"},"186":{"applyTo":{"__isSmartRef__":true,"id":187},"reset":{"__isSmartRef__":true,"id":190},"setupConnections":{"__isSmartRef__":true,"id":193},"onLoadFromPartsBin":{"__isSmartRef__":true,"id":196}},"187":{"varMapping":{"__isSmartRef__":true,"id":188},"source":"function applyTo(morph) {\n    morph.addScript(function throb() {\n        this.scaleBy(this.getScale() <= 1 ? 2 : 0.9);\n    });\n    morph.startStepping(100, 'throb');\n}","funcProperties":{"__isSmartRef__":true,"id":189},"__LivelyClassName__":"lively.Closure","__SourceModuleName__":"Global.lively.lang.Closure"},"188":{"this":{"__isSmartRef__":true,"id":161}},"189":{},"190":{"varMapping":{"__isSmartRef__":true,"id":191},"source":"function reset() {\n\tthis.applyStyle({enableDragging: true})\n}","funcProperties":{"__isSmartRef__":true,"id":192},"__LivelyClassName__":"lively.Closure","__SourceModuleName__":"Global.lively.lang.Closure"},"191":{"this":{"__isSmartRef__":true,"id":161}},"192":{},"193":{"varMapping":{"__isSmartRef__":true,"id":194},"source":"function setupConnections() {\n}","funcProperties":{"__isSmartRef__":true,"id":195},"__LivelyClassName__":"lively.Closure","__SourceModuleName__":"Global.lively.lang.Closure"},"194":{"this":{"__isSmartRef__":true,"id":161}},"195":{},"196":{"varMapping":{"__isSmartRef__":true,"id":197},"source":"function onLoadFromPartsBin() {\n\t$super();\n\tTrait('lively.morphic.DraggableBehavior').applyTo(this, {override: ['onDragStart', 'onDragEnd']});\n}","funcProperties":{"__isSmartRef__":true,"id":202},"__LivelyClassName__":"lively.Closure","__SourceModuleName__":"Global.lively.lang.Closure"},"197":{"this":{"__isSmartRef__":true,"id":161},"__serializedLivelyClosures__":{"__isSmartRef__":true,"id":198}},"198":{"$super":{"__isSmartRef__":true,"id":199}},"199":{"varMapping":{"__isSmartRef__":true,"id":200},"source":"function () {\n\t\t\t\ttry {\n\t\t\t\t\treturn obj.constructor.prototype[name].apply(obj, arguments)\n\t\t\t\t} catch(e) {\n\t\t\t\t\talert('Error in $super call: ' + e + '\\n' + e.stack);\n\t\t\t\t\treturn null;\n\t\t\t\t}\n\t\t\t}","funcProperties":{"__isSmartRef__":true,"id":201},"__LivelyClassName__":"lively.Closure","__SourceModuleName__":"Global.lively.lang.Closure"},"200":{"obj":{"__isSmartRef__":true,"id":161},"name":"onLoadFromPartsBin"},"201":{},"202":{},"203":{"applyTo":{"__isSmartRef__":true,"id":204},"reset":{"__isSmartRef__":true,"id":207},"setupConnections":{"__isSmartRef__":true,"id":210},"onLoadFromPartsBin":{"__isSmartRef__":true,"id":213}},"204":{"varMapping":{"__isSmartRef__":true,"id":205},"source":"function applyTo(morph) {\n    morph.addScript(function throb() {\n        this.scaleBy(this.getScale() <= 1 ? 2 : 0.9);\n    });\n    morph.startStepping(100, 'throb');\n}","funcProperties":{"__isSmartRef__":true,"id":206},"__LivelyClassName__":"lively.Closure","__SourceModuleName__":"Global.lively.lang.Closure"},"205":{"this":{"__isSmartRef__":true,"id":136}},"206":{},"207":{"varMapping":{"__isSmartRef__":true,"id":208},"source":"function reset() {\n\tthis.applyStyle({enableDragging: true})\n}","funcProperties":{"__isSmartRef__":true,"id":209},"__LivelyClassName__":"lively.Closure","__SourceModuleName__":"Global.lively.lang.Closure"},"208":{"this":{"__isSmartRef__":true,"id":136}},"209":{},"210":{"varMapping":{"__isSmartRef__":true,"id":211},"source":"function setupConnections() {\n}","funcProperties":{"__isSmartRef__":true,"id":212},"__LivelyClassName__":"lively.Closure","__SourceModuleName__":"Global.lively.lang.Closure"},"211":{"this":{"__isSmartRef__":true,"id":136}},"212":{},"213":{"varMapping":{"__isSmartRef__":true,"id":214},"source":"function onLoadFromPartsBin() {\n\t$super();\n\tTrait('lively.morphic.DraggableBehavior').applyTo(this, {override: ['onDragStart', 'onDragEnd']});\n}","funcProperties":{"__isSmartRef__":true,"id":219},"__LivelyClassName__":"lively.Closure","__SourceModuleName__":"Global.lively.lang.Closure"},"214":{"this":{"__isSmartRef__":true,"id":136},"__serializedLivelyClosures__":{"__isSmartRef__":true,"id":215}},"215":{"$super":{"__isSmartRef__":true,"id":216}},"216":{"varMapping":{"__isSmartRef__":true,"id":217},"source":"function () {\n\t\t\t\ttry {\n\t\t\t\t\treturn obj.constructor.prototype[name].apply(obj, arguments)\n\t\t\t\t} catch(e) {\n\t\t\t\t\talert('Error in $super call: ' + e + '\\n' + e.stack);\n\t\t\t\t\treturn null;\n\t\t\t\t}\n\t\t\t}","funcProperties":{"__isSmartRef__":true,"id":218},"__LivelyClassName__":"lively.Closure","__SourceModuleName__":"Global.lively.lang.Closure"},"217":{"obj":{"__isSmartRef__":true,"id":136},"name":"onLoadFromPartsBin"},"218":{},"219":{},"220":{"applyTo":{"__isSmartRef__":true,"id":221},"reset":{"__isSmartRef__":true,"id":224},"setupConnections":{"__isSmartRef__":true,"id":227},"onLoadFromPartsBin":{"__isSmartRef__":true,"id":230}},"221":{"varMapping":{"__isSmartRef__":true,"id":222},"source":"function applyTo(morph) {\n    morph.addScript(function throb() {\n        this.scaleBy(this.getScale() <= 1 ? 2 : 0.9);\n    });\n    morph.startStepping(100, 'throb');\n}","funcProperties":{"__isSmartRef__":true,"id":223},"__LivelyClassName__":"lively.Closure","__SourceModuleName__":"Global.lively.lang.Closure"},"222":{"this":{"__isSmartRef__":true,"id":111}},"223":{},"224":{"varMapping":{"__isSmartRef__":true,"id":225},"source":"function reset() {\n\tthis.applyStyle({enableDragging: true})\n}","funcProperties":{"__isSmartRef__":true,"id":226},"__LivelyClassName__":"lively.Closure","__SourceModuleName__":"Global.lively.lang.Closure"},"225":{"this":{"__isSmartRef__":true,"id":111}},"226":{},"227":{"varMapping":{"__isSmartRef__":true,"id":228},"source":"function setupConnections() {\n}","funcProperties":{"__isSmartRef__":true,"id":229},"__LivelyClassName__":"lively.Closure","__SourceModuleName__":"Global.lively.lang.Closure"},"228":{"this":{"__isSmartRef__":true,"id":111}},"229":{},"230":{"varMapping":{"__isSmartRef__":true,"id":231},"source":"function onLoadFromPartsBin() {\n\t$super();\n\tTrait('lively.morphic.DraggableBehavior').applyTo(this, {override: ['onDragStart', 'onDragEnd']});\n}","funcProperties":{"__isSmartRef__":true,"id":236},"__LivelyClassName__":"lively.Closure","__SourceModuleName__":"Global.lively.lang.Closure"},"231":{"this":{"__isSmartRef__":true,"id":111},"__serializedLivelyClosures__":{"__isSmartRef__":true,"id":232}},"232":{"$super":{"__isSmartRef__":true,"id":233}},"233":{"varMapping":{"__isSmartRef__":true,"id":234},"source":"function () {\n\t\t\t\ttry {\n\t\t\t\t\treturn obj.constructor.prototype[name].apply(obj, arguments)\n\t\t\t\t} catch(e) {\n\t\t\t\t\talert('Error in $super call: ' + e + '\\n' + e.stack);\n\t\t\t\t\treturn null;\n\t\t\t\t}\n\t\t\t}","funcProperties":{"__isSmartRef__":true,"id":235},"__LivelyClassName__":"lively.Closure","__SourceModuleName__":"Global.lively.lang.Closure"},"234":{"obj":{"__isSmartRef__":true,"id":111},"name":"onLoadFromPartsBin"},"235":{},"236":{},"237":{"applyTo":{"__isSmartRef__":true,"id":238},"reset":{"__isSmartRef__":true,"id":241},"setupConnections":{"__isSmartRef__":true,"id":244},"onLoadFromPartsBin":{"__isSmartRef__":true,"id":247}},"238":{"varMapping":{"__isSmartRef__":true,"id":239},"source":"function applyTo(morph) {\n    morph.addScript(function throb() {\n        this.scaleBy(this.getScale() <= 1 ? 2 : 0.9);\n    });\n    morph.startStepping(100, 'throb');\n}","funcProperties":{"__isSmartRef__":true,"id":240},"__LivelyClassName__":"lively.Closure","__SourceModuleName__":"Global.lively.lang.Closure"},"239":{"this":{"__isSmartRef__":true,"id":86}},"240":{},"241":{"varMapping":{"__isSmartRef__":true,"id":242},"source":"function reset() {\n\tthis.applyStyle({enableDragging: true})\n}","funcProperties":{"__isSmartRef__":true,"id":243},"__LivelyClassName__":"lively.Closure","__SourceModuleName__":"Global.lively.lang.Closure"},"242":{"this":{"__isSmartRef__":true,"id":86}},"243":{},"244":{"varMapping":{"__isSmartRef__":true,"id":245},"source":"function setupConnections() {\n}","funcProperties":{"__isSmartRef__":true,"id":246},"__LivelyClassName__":"lively.Closure","__SourceModuleName__":"Global.lively.lang.Closure"},"245":{"this":{"__isSmartRef__":true,"id":86}},"246":{},"247":{"varMapping":{"__isSmartRef__":true,"id":248},"source":"function onLoadFromPartsBin() {\n\t$super();\n\tTrait('lively.morphic.DraggableBehavior').applyTo(this, {override: ['onDragStart', 'onDragEnd']});\n}","funcProperties":{"__isSmartRef__":true,"id":253},"__LivelyClassName__":"lively.Closure","__SourceModuleName__":"Global.lively.lang.Closure"},"248":{"this":{"__isSmartRef__":true,"id":86},"__serializedLivelyClosures__":{"__isSmartRef__":true,"id":249}},"249":{"$super":{"__isSmartRef__":true,"id":250}},"250":{"varMapping":{"__isSmartRef__":true,"id":251},"source":"function () {\n\t\t\t\ttry {\n\t\t\t\t\treturn obj.constructor.prototype[name].apply(obj, arguments)\n\t\t\t\t} catch(e) {\n\t\t\t\t\talert('Error in $super call: ' + e + '\\n' + e.stack);\n\t\t\t\t\treturn null;\n\t\t\t\t}\n\t\t\t}","funcProperties":{"__isSmartRef__":true,"id":252},"__LivelyClassName__":"lively.Closure","__SourceModuleName__":"Global.lively.lang.Closure"},"251":{"obj":{"__isSmartRef__":true,"id":86},"name":"onLoadFromPartsBin"},"252":{},"253":{},"254":{"applyTo":{"__isSmartRef__":true,"id":255},"reset":{"__isSmartRef__":true,"id":258},"setupConnections":{"__isSmartRef__":true,"id":261},"onLoadFromPartsBin":{"__isSmartRef__":true,"id":264}},"255":{"varMapping":{"__isSmartRef__":true,"id":256},"source":"function applyTo(morph) {\n    morph.addScript(function name() { }); // Ytbd\n}","funcProperties":{"__isSmartRef__":true,"id":257},"__LivelyClassName__":"lively.Closure","__SourceModuleName__":"Global.lively.lang.Closure"},"256":{"this":{"__isSmartRef__":true,"id":61}},"257":{"user":"MatthewGoldberg","tags":[],"__serializedExpressions__":["timestamp"],"timestamp":"new Date(\"Thu Aug 22 2013 12:11:37 GMT-0700 (Pacific Daylight Time)\")"},"258":{"varMapping":{"__isSmartRef__":true,"id":259},"source":"function reset() {\n\tthis.applyStyle({enableDragging: true})\n}","funcProperties":{"__isSmartRef__":true,"id":260},"__LivelyClassName__":"lively.Closure","__SourceModuleName__":"Global.lively.lang.Closure"},"259":{"this":{"__isSmartRef__":true,"id":61}},"260":{},"261":{"varMapping":{"__isSmartRef__":true,"id":262},"source":"function setupConnections() {\n}","funcProperties":{"__isSmartRef__":true,"id":263},"__LivelyClassName__":"lively.Closure","__SourceModuleName__":"Global.lively.lang.Closure"},"262":{"this":{"__isSmartRef__":true,"id":61}},"263":{},"264":{"varMapping":{"__isSmartRef__":true,"id":265},"source":"function onLoadFromPartsBin() {\n\t$super();\n\tTrait('lively.morphic.DraggableBehavior').applyTo(this, {override: ['onDragStart', 'onDragEnd']});\n}","funcProperties":{"__isSmartRef__":true,"id":270},"__LivelyClassName__":"lively.Closure","__SourceModuleName__":"Global.lively.lang.Closure"},"265":{"this":{"__isSmartRef__":true,"id":61},"__serializedLivelyClosures__":{"__isSmartRef__":true,"id":266}},"266":{"$super":{"__isSmartRef__":true,"id":267}},"267":{"varMapping":{"__isSmartRef__":true,"id":268},"source":"function () {\n\t\t\t\ttry {\n\t\t\t\t\treturn obj.constructor.prototype[name].apply(obj, arguments)\n\t\t\t\t} catch(e) {\n\t\t\t\t\talert('Error in $super call: ' + e + '\\n' + e.stack);\n\t\t\t\t\treturn null;\n\t\t\t\t}\n\t\t\t}","funcProperties":{"__isSmartRef__":true,"id":269},"__LivelyClassName__":"lively.Closure","__SourceModuleName__":"Global.lively.lang.Closure"},"268":{"obj":{"__isSmartRef__":true,"id":61},"name":"onLoadFromPartsBin"},"269":{},"270":{},"271":{"applyTo":{"__isSmartRef__":true,"id":272},"reset":{"__isSmartRef__":true,"id":275},"setupConnections":{"__isSmartRef__":true,"id":278},"onLoadFromPartsBin":{"__isSmartRef__":true,"id":281}},"272":{"varMapping":{"__isSmartRef__":true,"id":273},"source":"function applyTo(morph) {\n    morph.addScript(function connectBox2D() {\n    this.getGrabShadow = function(){ return new lively.morphic.Morph; }\n    this.box2dWorld = this.world().box2dWorld;\n    var ext = this.getExtent();   \n    this.adjustOrigin(pt(ext.x/2, ext.y/2));\n    this.recreatePhysicsVersion(ext);\n    connect(this, \"rotation\", this.physicsVersion, \"SetAngle\");\n    connect(this, \"extent\", this, \"recreatePhysicsVersion\");\n    });\n}","funcProperties":{"__isSmartRef__":true,"id":274},"__LivelyClassName__":"lively.Closure","__SourceModuleName__":"Global.lively.lang.Closure"},"273":{"this":{"__isSmartRef__":true,"id":36}},"274":{"user":"MatthewGoldberg","tags":[],"__serializedExpressions__":["timestamp"],"timestamp":"new Date(\"Mon Aug 26 2013 15:38:56 GMT-0700 (Pacific Daylight Time)\")"},"275":{"varMapping":{"__isSmartRef__":true,"id":276},"source":"function reset() {\n\tthis.applyStyle({enableDragging: true})\n}","funcProperties":{"__isSmartRef__":true,"id":277},"__LivelyClassName__":"lively.Closure","__SourceModuleName__":"Global.lively.lang.Closure"},"276":{"this":{"__isSmartRef__":true,"id":36}},"277":{},"278":{"varMapping":{"__isSmartRef__":true,"id":279},"source":"function setupConnections() {\n}","funcProperties":{"__isSmartRef__":true,"id":280},"__LivelyClassName__":"lively.Closure","__SourceModuleName__":"Global.lively.lang.Closure"},"279":{"this":{"__isSmartRef__":true,"id":36}},"280":{},"281":{"varMapping":{"__isSmartRef__":true,"id":282},"source":"function onLoadFromPartsBin() {\n\t$super();\n\tTrait('lively.morphic.DraggableBehavior').applyTo(this, {override: ['onDragStart', 'onDragEnd']});\n}","funcProperties":{"__isSmartRef__":true,"id":287},"__LivelyClassName__":"lively.Closure","__SourceModuleName__":"Global.lively.lang.Closure"},"282":{"this":{"__isSmartRef__":true,"id":36},"__serializedLivelyClosures__":{"__isSmartRef__":true,"id":283}},"283":{"$super":{"__isSmartRef__":true,"id":284}},"284":{"varMapping":{"__isSmartRef__":true,"id":285},"source":"function () {\n\t\t\t\ttry {\n\t\t\t\t\treturn obj.constructor.prototype[name].apply(obj, arguments)\n\t\t\t\t} catch(e) {\n\t\t\t\t\talert('Error in $super call: ' + e + '\\n' + e.stack);\n\t\t\t\t\treturn null;\n\t\t\t\t}\n\t\t\t}","funcProperties":{"__isSmartRef__":true,"id":286},"__LivelyClassName__":"lively.Closure","__SourceModuleName__":"Global.lively.lang.Closure"},"285":{"obj":{"__isSmartRef__":true,"id":36},"name":"onLoadFromPartsBin"},"286":{},"287":{},"288":{"applyTo":{"__isSmartRef__":true,"id":289},"reset":{"__isSmartRef__":true,"id":292},"setupConnections":{"__isSmartRef__":true,"id":295},"onLoadFromPartsBin":{"__isSmartRef__":true,"id":298}},"289":{"varMapping":{"__isSmartRef__":true,"id":290},"source":"function applyTo(morph) {\n    morph.addScript(function connectBox2D() {\n    this.getGrabShadow = function(){ return new lively.morphic.Morph; }\n    this.box2dWorld = this.world().box2dWorld;\n    var ext = this.getExtent();   \n    this.adjustOrigin(pt(ext.x/2, ext.y/2));\n    this.recreatePhysicsVersion(ext);\n    connect(this, \"rotation\", this.physicsVersion, \"SetAngle\");\n    connect(this, \"extent\", this, \"recreatePhysicsVersion\");\n    connect(this, \"owner\", this, \"onOwnerChange\");    \n    });\n    \n    morph.addScript(function disconnectBox2D() {\n    disconnect(this, \"rotation\", this.physicsVersion, \"SetAngle\");\n    disconnect(this, \"extent\", this, \"recreatePhysicsVersion\");  \n    this.box2dWorld = null;\n    this.physicsVersion = null;\n    });\n    \n    morph.addScript(function onDrag(evt) {\n    if (!(this.box2dWorld && this.world().running))\n        return;\n    \n    var b2Vec2 = Box2D.Common.Math.b2Vec2\n        , b2AABB = Box2D.Collision.b2AABB\n        , b2BodyDef = Box2D.Dynamics.b2BodyDef\n        , b2Body = Box2D.Dynamics.b2Body\n        , b2MouseJointDef =  Box2D.Dynamics.Joints.b2MouseJointDef\n        , p = new b2Vec2(evt.x, evt.y);\n    \n    if(this.mousePressed && !this.mouseJoint)\n    {    \n        var def = new b2MouseJointDef();\n        def.bodyA = this.world().walls[0];\n        def.bodyB = this.physicsVersion;;\n        def.target = p;\n        def.collideConnected = true;\n        def.maxForce = 100000 * this.physicsVersion.GetMass();\n        def.dampingRatio = 0;\n        \n        this.mouseJoint = this.box2dWorld.CreateJoint(def);\n        this.physicsVersion.SetAwake(true);\n    }\n    if(this.mouseJoint)\n        this.mouseJoint.SetTarget(p);\n    });\n    \n    morph.addScript(function onDragEnd() {\n    this.mousePressed = false;\n    \n    if (this.mouseJoint)\n    {\n        this.box2dWorld.DestroyJoint(this.mouseJoint);\n        this.mouseJoint = false;\n    }\n    });\n\n    morph.addScript(function onDragStart() {\n    this.mousePressed = true;\n    });\n    \n    morph.addScript(function onOwnerChange() {\n    var morphArr = lively.morphic.World.current().morphCollection;\n    if (!this.owner)\n    {\n        this.box2dWorld.DestroyBody(this.physicsVersion);\n        disconnect(this.physicsVersion.m_xf.position, \"y\", this, \"setPosition\");    \n        disconnect(this.physicsVersion.m_xf.R.col1, \"y\", this, \"setRotation\");\n        morphArr.splice(morphArr.indexOf(this), 1);\n    }\n    else if (this.owner === lively.morphic.World.current())\n    {\n        morphArr.push(this);\n        var thisName = this.name;\n        setTimeout(function(){lively.morphic.World.current().get(thisName).recreatePhysicsVersion(lively.morphic.World.current().get(thisName).getExtent());}, 20);    \n    }\n    });\n    \n    morph.addScript(function recreatePhysicsVersion(ext) {\n    var pos = this.getPosition();  \n    var replacement = null;\n    if (this.getShape().constructor.type === \"lively.morphic.Shapes.Rectangle\")\n        replacement = this.world().createBox(pos.x, pos.y, ext.x/2, ext.y/2, Box2D.Dynamics.b2Body.b2_dynamicBody, this.box2dWorld);\n    replacement.m_mass /= 100; // allows easier throwing\n    replacement.SetAngle(this.getRotation());\n    if (this.physicsVersion)\n    {\n        replacement.SetLinearVelocity(this.physicsVersion.GetLinearVelocity());\n        this.box2dWorld.DestroyBody(this.physicsVersion);\n    }\n    this.physicsVersion = replacement;\n    if (this.physicsVersion)\n    {    \n        connect(this.physicsVersion.m_xf.position, \"y\", this, \"setPosition\", {converter:\n    \t    function converter(value) {\n            return pt(this.sourceObj.x, value);\n        }});    \n        connect(this.physicsVersion.m_xf.R.col1, \"y\", this, \"setRotation\", {converter:\n    \t    function converter(value) {\n            return Math.atan2(value, this.sourceObj.x);\n        }});\n    }\n    });\n    \n    morph.world().morphCollection.push(morph);\n    morph.disconnectBox2D();\n    morph.connectBox2D();    \n}","funcProperties":{"__isSmartRef__":true,"id":291},"__LivelyClassName__":"lively.Closure","__SourceModuleName__":"Global.lively.lang.Closure"},"290":{"this":{"__isSmartRef__":true,"id":0}},"291":{"__serializedExpressions__":["timestamp"],"user":"MatthewGoldberg","tags":[],"timestamp":"new Date(\"Thu Aug 29 2013 16:10:03 GMT-0700 (Pacific Daylight Time)\")"},"292":{"varMapping":{"__isSmartRef__":true,"id":293},"source":"function reset() {\n\tthis.applyStyle({enableDragging: true})\n}","funcProperties":{"__isSmartRef__":true,"id":294},"__LivelyClassName__":"lively.Closure","__SourceModuleName__":"Global.lively.lang.Closure"},"293":{"this":{"__isSmartRef__":true,"id":0}},"294":{"__serializedExpressions__":["timestamp"],"user":"MatthewGoldberg","tags":[],"timestamp":"new Date(\"Mon Aug 26 2013 16:26:28 GMT-0700 (Pacific Daylight Time)\")"},"295":{"varMapping":{"__isSmartRef__":true,"id":296},"source":"function setupConnections() {\n}","funcProperties":{"__isSmartRef__":true,"id":297},"__LivelyClassName__":"lively.Closure","__SourceModuleName__":"Global.lively.lang.Closure"},"296":{"this":{"__isSmartRef__":true,"id":0}},"297":{"__serializedExpressions__":["timestamp"],"user":"MatthewGoldberg","tags":[],"timestamp":"new Date(\"Mon Aug 26 2013 16:26:28 GMT-0700 (Pacific Daylight Time)\")"},"298":{"varMapping":{"__isSmartRef__":true,"id":299},"source":"function onLoadFromPartsBin() {\n\t$super();\n\tTrait('lively.morphic.DraggableBehavior').applyTo(this, {override: ['onDragStart', 'onDragEnd']});\n\t\n\tvar targetWorld = lively.morphic.World.current();\n\t\n\ttargetWorld.addScript(function animate() {\n    if (!this.running)\n        return;\n\n \trequestAnimationFrame(this.animate.bind(this));\n \t\n    var world = this.box2dWorld;\n    world.Step(1/60,  10,  10);\n    world.DrawDebugData();\n    world.ClearForces();\n    });\n    \n    targetWorld.addScript(function createBox(x, y, width, height, bodyType, world) {\n    var   b2BodyDef = Box2D.Dynamics.b2BodyDef\n        , b2FixtureDef = Box2D.Dynamics.b2FixtureDef\n        , b2PolygonShape = Box2D.Collision.Shapes.b2PolygonShape;\n\n    var fixDef = new b2FixtureDef;\n    fixDef.density = 1.0;\n    fixDef.friction = 0.5;\n    fixDef.restitution = 0.2;\n    var bodyDef = new b2BodyDef;\n    bodyDef.type = bodyType;  \n    fixDef.shape = new b2PolygonShape();\n    fixDef.shape.SetAsBox(width, height);\n    bodyDef.position.x = x;\n    bodyDef.position.y = y;\n    var a = world.CreateBody(bodyDef);\n    a.CreateFixture(fixDef);\n    return a;\n    });\n    \n    targetWorld.addScript(function onLoad() {\n    this.startBox2D();\n    });\n    \n    targetWorld.addScript(function startBox2D() {\n    var b2Canvas = document.createElement('canvas');\n    b2Canvas.id = 'box2dCanvas';\n    b2Canvas.width = this.world().windowBounds().width;\n    b2Canvas.height = this.world().windowBounds().height;\n    b2Canvas.style.backgroundColor = '#f0f0f0';\n    this.renderContext().shapeNode.appendChild(b2Canvas);\n    this.box2dCanvas = b2Canvas;\n\n    var     b2Vec2 = Box2D.Common.Math.b2Vec2\n     \t,\tb2Body = Box2D.Dynamics.b2Body\n     \t,\tb2World = Box2D.Dynamics.b2World\n     \t,\tb2DebugDraw = Box2D.Dynamics.b2DebugDraw;\n    var world = new b2World(new b2Vec2(0, 10), true);\n    \n    this.mousePressed = false;\n    this.mouseJoint = false;\n    \n    var debugDraw = new b2DebugDraw();\n\t\tdebugDraw.SetSprite(b2Canvas.getContext(\"2d\"));\n\t\tdebugDraw.SetFillAlpha(0.3);\n\t\tdebugDraw.SetLineThickness(1.0);\n\t\tdebugDraw.SetFlags(b2DebugDraw.e_shapeBit | b2DebugDraw.e_jointBit     );\n\tworld.SetDebugDraw(debugDraw);\n\n    this.walls = [];\n    var bounds = this.world().windowBounds();\n    this.walls.push(this.createBox(bounds.width/2, bounds.height + 1, bounds.width, 1, b2Body.b2_staticBody, world));\n    this.walls.push(this.createBox(bounds.width/2, 0, bounds.width, 1, b2Body.b2_staticBody, world));\n    this.walls.push(this.createBox(0, bounds.height/2, 1, bounds.height, b2Body.b2_staticBody, world));\n    this.walls.push(this.createBox(bounds.width + 1, bounds.height/2, 1, bounds.height, b2Body.b2_staticBody, world));\n\n    this.box2dWorld = world;\n    \n    if (!this.morphCollection)\n        this.morphCollection = [];\n    \n    for (var i = 0; i < this.morphCollection.length; i++)\n    {\n        this.morphCollection[i].disconnectBox2D();        \n        this.morphCollection[i].connectBox2D();\n    }\n    \n    this.running = true;\n    this.animate();\n    });\n    \n    require('lib.box2dWeb.Box2dWeb21a3.js').toRun(function() {\n        targetWorld.startBox2D()\n        alertOK('Box2D canvas has been created');    \n    });\n}","funcProperties":{"__isSmartRef__":true,"id":304},"__LivelyClassName__":"lively.Closure","__SourceModuleName__":"Global.lively.lang.Closure"},"299":{"this":{"__isSmartRef__":true,"id":0},"__serializedLivelyClosures__":{"__isSmartRef__":true,"id":300}},"300":{"$super":{"__isSmartRef__":true,"id":301}},"301":{"varMapping":{"__isSmartRef__":true,"id":302},"source":"function () {\n                    try {\n                        return obj.constructor.prototype[name].apply(obj, arguments)\n                    } catch (e) {\n                        if ($world)\n                            $world.logError(e, 'Error in $super call')\n                        else\n                            alert('Error in $super call: ' + e + '\\n' + e.stack);\n                        return null;\n                    }\n                }","funcProperties":{"__isSmartRef__":true,"id":303},"__LivelyClassName__":"lively.Closure","__SourceModuleName__":"Global.lively.lang.Closure"},"302":{"obj":{"__isSmartRef__":true,"id":0},"name":"onLoadFromPartsBin"},"303":{},"304":{"__serializedExpressions__":["timestamp"],"user":"MatthewGoldberg","tags":[],"timestamp":"new Date(\"Wed Aug 28 2013 10:22:38 GMT-0700 (Pacific Daylight Time)\")"},"isSimplifiedRegistry":true}}