{"id":0,"registry":{"0":{"submorphs":[{"__isSmartRef__":true,"id":1},{"__isSmartRef__":true,"id":16},{"__isSmartRef__":true,"id":87},{"__isSmartRef__":true,"id":127},{"__isSmartRef__":true,"id":148}],"scripts":[],"id":"082E9AA9-F8AA-4852-A659-8ABCB997C063","shape":{"__isSmartRef__":true,"id":172},"droppingEnabled":true,"halosEnabled":true,"registeredForMouseEvents":true,"showsHalos":false,"name":"SnippedWithLog","partsBinMetaInfo":{"__isSmartRef__":true,"id":173},"eventHandler":{"__isSmartRef__":true,"id":196},"derivationIds":[127,"F0291F62-F100-480C-AEBF-0230398F7983","AE8B5ED7-E305-45BC-BE4A-1C28A49EE12B","39BA345C-17FA-45A0-BAC2-F0CF5654ACF8","FE91EA31-D8AE-461B-8A49-95DA5FBAE5B4","F38439A3-2F4E-4AC2-BF73-2633C00B1393","6748F5B5-2284-4748-A6EE-F1A261CBAD0B","BBAFB862-93AE-4F89-BCFF-9F1C67B7FE4C","7EC17E78-593A-4CC8-B7E3-859BCBBFE785","BD8BECDB-A9A1-4009-B433-C925F0AFCCFC","F2677A9D-5855-4DF2-B248-94545B34B762","D52188B3-7DC0-410E-96B1-50892AC00A37"],"partTests":{"__isSmartRef__":true,"id":197},"_ClipMode":"visible","moved":true,"layout":{"__isSmartRef__":true,"id":202},"isBeingDragged":false,"isCopyMorphRef":true,"morphRefId":1,"__serializedExpressions__":["_Position","distanceToDragEvent"],"_Rotation":0,"_Scale":1,"__serializedLivelyClosures__":{"__isSmartRef__":true,"id":203},"__LivelyClassName__":"lively.morphic.Box","__SourceModuleName__":"Global.lively.morphic.Core","_Position":"lively.pt(0.0,0.0)","distanceToDragEvent":"lively.pt(645.3,-30.8)"},"1":{"submorphs":[],"scripts":[],"id":"9CFF4261-8DB1-4FEC-9B8A-10552DF7F5B9","shape":{"__isSmartRef__":true,"id":2},"grabbingEnabled":false,"droppingEnabled":false,"halosEnabled":true,"fixedWidth":true,"fixedHeight":true,"allowsInput":true,"_FontFamily":"Courier","registeredForMouseEvents":true,"_MaxTextWidth":120.695652,"_MaxTextHeight":null,"showsHalos":false,"_FontSize":9,"name":"Log","partsBinMetaInfo":{"__isSmartRef__":true,"id":3},"textChunks":[{"__isSmartRef__":true,"id":12}],"charsReplaced":"\n    \"sectionGroupsUrl\": \"https://www","lastFindLoc":214,"prevScroll":[0,0],"eventHandler":{"__isSmartRef__":true,"id":14},"_ClipMode":"scroll","derivationIds":[355,"1EB1674F-8BF2-419B-B054-86129ED70335","63698904-DC05-4341-A9B6-5CC4A219CD04","F6A714BA-4735-41ED-8A2A-45CB153FBDF8","F1D26890-7392-487D-B5DE-97C772B4E79E","59440FC5-E676-4B9B-A828-C150A05765C0"],"_WhiteSpaceHandling":"pre-wrap","_MinTextWidth":120.695652,"_MinTextHeight":null,"isBeingDragged":false,"moved":true,"layout":{"__isSmartRef__":true,"id":15},"owner":{"__isSmartRef__":true,"id":0},"__serializedExpressions__":["_Position","textColor","_Padding","distanceToDragEvent"],"_Rotation":0,"_Scale":1,"__LivelyClassName__":"lively.morphic.Text","__SourceModuleName__":"Global.lively.morphic.TextCore","_Position":"lively.pt(519.0,23.0)","textColor":"Color.rgb(0,0,0)","_Padding":"lively.rect(5,5,0,0)","distanceToDragEvent":"lively.pt(236.0,-4.8)"},"2":{"fill":null,"_BorderWidth":0,"_ClipMode":"visible","_BorderRadius":0,"_Opacity":1,"_BorderStyle":"solid","_AppearanceStylingMode":false,"_BorderStylingMode":false,"__serializedExpressions__":["_Fill","_Position","_Extent","_BorderColor","_Padding"],"__LivelyClassName__":"lively.morphic.Shapes.Rectangle","__SourceModuleName__":"Global.lively.morphic.Shapes","_Fill":"Color.rgb(230,230,230)","_Position":"lively.pt(0.0,0.0)","_Extent":"lively.pt(363.7,153.6)","_BorderColor":"Color.rgb(0,0,0)","_Padding":"lively.rect(4,2,0,0)"},"3":{"partsSpaceName":"PartsBin/Basic","migrationLevel":8,"comment":"a simple text morph","partName":"Text","changes":[{"__isSmartRef__":true,"id":4},{"__isSmartRef__":true,"id":5},{"__isSmartRef__":true,"id":6},{"__isSmartRef__":true,"id":7},{"__isSmartRef__":true,"id":8},{"__isSmartRef__":true,"id":9},{"__isSmartRef__":true,"id":10},{"__isSmartRef__":true,"id":11}],"__serializedExpressions__":["lastModifiedDate"],"__LivelyClassName__":"lively.PartsBin.PartsBinMetaInfo","__SourceModuleName__":"Global.lively.PartsBin","lastModifiedDate":"new Date(\"Sat Apr 05 2014 10:51:52 GMT+0200 (W. Europe Daylight Time)\")"},"4":{"author":"jenslincke","message":"no comment","id":"A3BA0C1E-7E83-43BF-9EC6-4F4BB3835D62","__serializedExpressions__":["date"],"date":"new Date(\"Tue Mar 12 2013 17:31:56 GMT+0100 (W. Europe Standard Time)\")"},"5":{"author":"timfelgentreff","message":"better text","id":"B904F9AC-6EA0-4A8A-83C9-AFC85AADC194","__serializedExpressions__":["date"],"date":"new Date(\"Tue May 08 2012 14:18:18 GMT+0200 (W. Europe Daylight Time)\")"},"6":{"author":"tessi","message":"TextBubble calls its disappear() function after showBubbleTime() milliseconds now","id":"785D95BD-7858-43EB-90E6-A1C085E2F2B9","__serializedExpressions__":["date"],"date":"new Date(\"Sat Apr 21 2012 07:32:09 GMT+0200 (W. Europe Daylight Time)\")"},"7":{"author":"tessi","message":"TextBubble calls its disappear() function after showBubbleTime() milliseconds now","id":"0F4DE333-A551-4961-B29D-70270977EBEF","__serializedExpressions__":["date"],"date":"new Date(\"Sat Apr 21 2012 07:31:43 GMT+0200 (W. Europe Daylight Time)\")"},"8":{"author":"undefined","message":"Set the inset as: this.setPadding(Rectangle.inset(4,2)).  This gives it a more pleasing appearance with a border, and also makes it easier to select near the bounds.","id":"BD5B0E4C-4830-4863-A013-35BB66D5AD6F","__serializedExpressions__":["date"],"date":"new Date(\"Mon Feb 27 2012 06:20:38 GMT+0100 (W. Europe Standard Time)\")"},"9":{"author":"robertkrahn","message":"text click was broken?","id":"9D065E14-9653-4B2A-9A2E-3AD84EBBC3E0","__serializedExpressions__":["date"],"date":"new Date(\"Sat Apr 21 2012 16:30:30 GMT+0200 (W. Europe Daylight Time)\")"},"10":{"author":"jenslincke","message":"no comment","id":"9E495E1B-6E6D-4A89-9F9E-85AF618DC598","__serializedExpressions__":["date"],"date":"new Date(\"Tue Mar 12 2013 18:36:22 GMT+0100 (W. Europe Standard Time)\")"},"11":{"author":"robertkrahn","message":"resizeWidth = true","id":"E402462A-7AB2-487B-82BD-A3369C1C1F75","__serializedExpressions__":["date"],"date":"new Date(\"Sat Apr 05 2014 10:58:52 GMT+0200 (W. Europe Daylight Time)\")"},"12":{"style":{"__isSmartRef__":true,"id":13},"chunkOwner":{"__isSmartRef__":true,"id":1},"_id":"_5099","storedString":"[\r\n  {\r\n    \"id\": \"0-D333AEE656452F8B!101398\",\r\n    \"name\": \"Games\"\r\n  },\r\n  {\r\n    \"id\": \"0-D333AEE656452F8B!2051\",\r\n    \"name\": \"GTD\"\r\n  },\r\n  {\r\n    \"id\": \"0-D333AEE656452F8B!1805\",\r\n    \"name\": \"Journal\"\r\n  },\r\n  {\r\n    \"id\": \"0-D333AEE656452F8B!2062\",\r\n    \"name\": \"Lists\"\r\n  },\r\n  {\r\n    \"id\": \"0-D333AEE656452F8B!1867\",\r\n    \"name\": \"Lively\"\r\n  },\r\n  {\r\n    \"id\": \"0-D333AEE656452F8B!894\",\r\n    \"name\": \"Notes\"\r\n  },\r\n  {\r\n    \"id\": \"0-D333AEE656452F8B!2206\",\r\n    \"name\": \"Notizbuch von Jens\"\r\n  },\r\n  {\r\n    \"id\": \"0-D333AEE656452F8B!1494\",\r\n    \"name\": \"SWA\"\r\n  },\r\n  {\r\n    \"id\": \"0-D333AEE656452F8B!1501\",\r\n    \"name\": \"Thesis\"\r\n  }\r\n]\nundefined\n","__LivelyClassName__":"lively.morphic.TextChunk","__SourceModuleName__":"Global.lively.morphic.TextCore"},"13":{"__LivelyClassName__":"lively.morphic.TextEmphasis","__SourceModuleName__":"Global.lively.morphic.TextCore"},"14":{"morph":{"__isSmartRef__":true,"id":1},"__LivelyClassName__":"lively.morphic.EventHandler","__SourceModuleName__":"Global.lively.morphic.Events"},"15":{"resizeWidth":false,"resizeHeight":true,"moveHorizontal":true},"16":{"storedTextString":"module('lively.net.OneNote').load(true);\n\nr = lively.net.OneNote.get(\"notebooks?select=name,id\", 'application/json', true);\nif (r.content) notebooks = JSON.parse(r.content);\nthis.log(r.content)\n\n","submorphs":[],"scripts":[],"shape":{"__isSmartRef__":true,"id":17},"derivationIds":[],"id":"B17BBDCC-8B4D-4E7D-AD56-826EC5ECFE13","grabbingEnabled":false,"halosEnabled":true,"_FontSize":12,"doNotSerialize":[],"_ShowGutter":false,"_TextMode":"javascript","_Theme":"","_LineWrapping":false,"_ShowInvisibles":false,"_ShowPrintMargin":false,"_ShowIndents":true,"_ShowActiveLine":false,"_SoftTabs":true,"_AutocompletionEnabled":true,"_BehaviorsEnabled":true,"_ShowWarnings":true,"_ShowErrors":true,"_TabSize":4,"allowInput":true,"evalEnabled":true,"layout":{"__isSmartRef__":true,"id":18},"name":"workspace","state":{"__isSmartRef__":true,"id":19},"doNotCopyProperties":[],"_Rotation":0,"_Scale":1,"owner":{"__isSmartRef__":true,"id":0},"eventHandler":{"__isSmartRef__":true,"id":21},"_isFocused":false,"showsHalos":false,"prevScroll":[0,0],"doitContext":{"__isSmartRef__":true,"id":0},"__serializedExpressions__":["_Position","distanceToDragEvent"],"__serializedLivelyClosures__":{"__isSmartRef__":true,"id":22},"__LivelyClassName__":"lively.morphic.CodeEditor","__SourceModuleName__":"Global.lively.ide.CodeEditor","_Position":"lively.pt(-0.3,23.9)","distanceToDragEvent":"lively.pt(350.6,-7.7)"},"17":{"_BorderWidth":2,"_BorderStyle":"solid","_BorderRadius":5,"_Opacity":1,"_BorderStylingMode":false,"__serializedExpressions__":["_BorderColor","_Fill","_Extent","extent"],"__LivelyClassName__":"lively.morphic.CodeEditorShape","__SourceModuleName__":"Global.lively.ide.CodeEditor","_BorderColor":"Color.rgb(200,200,200)","_Fill":"Color.rgb(240,240,240)","_Extent":"lively.pt(516.0,150.0)","extent":"lively.pt(516.0,150.0)"},"18":{"resizeHeight":true,"resizeWidth":true},"19":{"depth":1,"doNotSerialize":["workspaceVars"],"defRanges":{"__isSmartRef__":true,"id":20}},"20":{},"21":{"morph":{"__isSmartRef__":true,"id":16},"__LivelyClassName__":"lively.morphic.EventHandler","__SourceModuleName__":"Global.lively.morphic.Events"},"22":{"onWindowGetsFocus":{"__isSmartRef__":true,"id":23},"animatedSetBounds":{"__isSmartRef__":true,"id":30},"sourceNameForEval":{"__isSmartRef__":true,"id":33},"getVarValue":{"__isSmartRef__":true,"id":40},"hideVariableArea":{"__isSmartRef__":true,"id":43},"onLoad":{"__isSmartRef__":true,"id":46},"onFromBuildSpecCreated":{"__isSmartRef__":true,"id":53},"rerender":{"__isSmartRef__":true,"id":60},"reset":{"__isSmartRef__":true,"id":63},"resetState":{"__isSmartRef__":true,"id":66},"selectVarDef":{"__isSmartRef__":true,"id":69},"showVariableArea":{"__isSmartRef__":true,"id":72},"showVars":{"__isSmartRef__":true,"id":75},"toggleVarArea":{"__isSmartRef__":true,"id":78},"updateToggleVarsButton":{"__isSmartRef__":true,"id":81},"varAreaIsHidden":{"__isSmartRef__":true,"id":84}},"23":{"varMapping":{"__isSmartRef__":true,"id":24},"source":"function onWindowGetsFocus() { this.focus(); }","funcProperties":{"__isSmartRef__":true,"id":29},"__LivelyClassName__":"lively.Closure"},"24":{"this":{"__isSmartRef__":true,"id":16},"__serializedLivelyClosures__":{"__isSmartRef__":true,"id":25}},"25":{"$super":{"__isSmartRef__":true,"id":26}},"26":{"varMapping":{"__isSmartRef__":true,"id":27},"source":"function () {\n        try {\n          // FIXME super is supposed to be static\n          return Object.getPrototypeOf(obj)[name].apply(obj, arguments);\n        } catch (e) {\n          if (typeof $world !== undefined) $world.logError(e, 'Error in $super call')\n          else alert('Error in $super call: ' + e + '\\n' + e.stack);\n          return null;\n        }\n      }","funcProperties":{"__isSmartRef__":true,"id":28},"__LivelyClassName__":"lively.Closure"},"27":{"obj":{"__isSmartRef__":true,"id":16},"name":"onWindowGetsFocus"},"28":{},"29":{"user":"jenslincke","__serializedExpressions__":["timestamp"],"timestamp":"new Date(\"Tue Jun 02 2015 18:14:32 GMT+0200 (W. Europe Daylight Time)\")"},"30":{"varMapping":{"__isSmartRef__":true,"id":31},"source":"function animatedSetBounds(morph, bounds) {\n        // this.setBounds(newEditorBounds);\n        // this.animatedSetBounds(this, this.bounds().withExtent(this.getExtent().addXY(10,0)));\n        var morphBounds = morph.bounds();\n        var posDiff = bounds.topLeft().subPt(morphBounds.topLeft());\n        var extentDiff = bounds.extent().subPt(morphBounds.extent());\n\n        var time = 400; // ms\n        var steps = 10;\n        var stepMove = posDiff.scaleBy(1/steps);\n        var stepResize = extentDiff.scaleBy(1/steps);\n        animatedScale(steps);\n\n        function animatedScale(step) {\n            if (step === 0) { morph.setBounds(bounds); return; }\n            morph.moveBy(stepMove);\n            morph.resizeBy(stepResize);\n            animatedScale.curry(step-1).delay(time/steps / 1000);\n        }\n\n    }","funcProperties":{"__isSmartRef__":true,"id":32},"__LivelyClassName__":"lively.Closure"},"31":{"this":{"__isSmartRef__":true,"id":16}},"32":{"user":"jenslincke","__serializedExpressions__":["timestamp"],"timestamp":"new Date(\"Tue Jun 02 2015 18:14:32 GMT+0200 (W. Europe Daylight Time)\")"},"33":{"varMapping":{"__isSmartRef__":true,"id":34},"source":"function sourceNameForEval() {\n      return (this.getWindow() ? this.getWindow().getTitle() : \"JS-workspace\") + \"-\" + Date.now();\n    }","funcProperties":{"__isSmartRef__":true,"id":39},"__LivelyClassName__":"lively.Closure"},"34":{"this":{"__isSmartRef__":true,"id":16},"__serializedLivelyClosures__":{"__isSmartRef__":true,"id":35}},"35":{"$super":{"__isSmartRef__":true,"id":36}},"36":{"varMapping":{"__isSmartRef__":true,"id":37},"source":"function () {\n        try {\n          // FIXME super is supposed to be static\n          return Object.getPrototypeOf(obj)[name].apply(obj, arguments);\n        } catch (e) {\n          if (typeof $world !== undefined) $world.logError(e, 'Error in $super call')\n          else alert('Error in $super call: ' + e + '\\n' + e.stack);\n          return null;\n        }\n      }","funcProperties":{"__isSmartRef__":true,"id":38},"__LivelyClassName__":"lively.Closure"},"37":{"obj":{"__isSmartRef__":true,"id":16},"name":"sourceNameForEval"},"38":{},"39":{"user":"jenslincke","__serializedExpressions__":["timestamp"],"timestamp":"new Date(\"Tue Jun 02 2015 18:14:32 GMT+0200 (W. Europe Daylight Time)\")"},"40":{"varMapping":{"__isSmartRef__":true,"id":41},"source":"function setVarValue(varName, val) {\n        if (!this.state.workspaceVars) this.state.workspaceVars = {};\n        return this.state.workspaceVars[varName] = val;\n    }","funcProperties":{"__isSmartRef__":true,"id":42},"__LivelyClassName__":"lively.Closure"},"41":{"this":{"__isSmartRef__":true,"id":16}},"42":{"user":"jenslincke","__serializedExpressions__":["timestamp"],"timestamp":"new Date(\"Tue Jun 02 2015 18:14:32 GMT+0200 (W. Europe Daylight Time)\")"},"43":{"varMapping":{"__isSmartRef__":true,"id":44},"source":"function hideVariableArea() {\n        var newEditorBounds = rect(pt(3,22), this.get(\"listContainer\").bounds().bottomRight());\n        // this.setBounds(newEditorBounds);\n        this.updateToggleVarsButton(newEditorBounds);\n        this.animatedSetBounds(this, newEditorBounds);\n        this.stopStepping();\n    }","funcProperties":{"__isSmartRef__":true,"id":45},"__LivelyClassName__":"lively.Closure"},"44":{"this":{"__isSmartRef__":true,"id":16}},"45":{"user":"jenslincke","__serializedExpressions__":["timestamp"],"timestamp":"new Date(\"Tue Jun 02 2015 18:14:32 GMT+0200 (W. Europe Daylight Time)\")"},"46":{"varMapping":{"__isSmartRef__":true,"id":47},"source":"function onLoad() {\n            $super();\n            // FIXME...\n            this.getWindow().addMorphBack(this.get(\"listContainer\"));\n        }","funcProperties":{"__isSmartRef__":true,"id":52},"__LivelyClassName__":"lively.Closure"},"47":{"this":{"__isSmartRef__":true,"id":16},"__serializedLivelyClosures__":{"__isSmartRef__":true,"id":48}},"48":{"$super":{"__isSmartRef__":true,"id":49}},"49":{"varMapping":{"__isSmartRef__":true,"id":50},"source":"function () {\n        try {\n          // FIXME super is supposed to be static\n          return Object.getPrototypeOf(obj)[name].apply(obj, arguments);\n        } catch (e) {\n          if (typeof $world !== undefined) $world.logError(e, 'Error in $super call')\n          else alert('Error in $super call: ' + e + '\\n' + e.stack);\n          return null;\n        }\n      }","funcProperties":{"__isSmartRef__":true,"id":51},"__LivelyClassName__":"lively.Closure"},"50":{"obj":{"__isSmartRef__":true,"id":16},"name":"onLoad"},"51":{},"52":{"user":"jenslincke","__serializedExpressions__":["timestamp"],"timestamp":"new Date(\"Tue Jun 02 2015 18:14:32 GMT+0200 (W. Europe Daylight Time)\")"},"53":{"varMapping":{"__isSmartRef__":true,"id":54},"source":"function onFromBuildSpecCreated() {\n            $super();\n            this.getWindow().addMorphBack(this.get(\"listContainer\"));\n            this.resetState();\n        }","funcProperties":{"__isSmartRef__":true,"id":59},"__LivelyClassName__":"lively.Closure"},"54":{"this":{"__isSmartRef__":true,"id":16},"__serializedLivelyClosures__":{"__isSmartRef__":true,"id":55}},"55":{"$super":{"__isSmartRef__":true,"id":56}},"56":{"varMapping":{"__isSmartRef__":true,"id":57},"source":"function () {\n        try {\n          // FIXME super is supposed to be static\n          return Object.getPrototypeOf(obj)[name].apply(obj, arguments);\n        } catch (e) {\n          if (typeof $world !== undefined) $world.logError(e, 'Error in $super call')\n          else alert('Error in $super call: ' + e + '\\n' + e.stack);\n          return null;\n        }\n      }","funcProperties":{"__isSmartRef__":true,"id":58},"__LivelyClassName__":"lively.Closure"},"57":{"obj":{"__isSmartRef__":true,"id":16},"name":"onFromBuildSpecCreated"},"58":{},"59":{"user":"jenslincke","__serializedExpressions__":["timestamp"],"timestamp":"new Date(\"Tue Jun 02 2015 18:14:32 GMT+0200 (W. Europe Daylight Time)\")"},"60":{"varMapping":{"__isSmartRef__":true,"id":61},"source":"function rerender() {\n            var obs = this.get('workspaceVarObserver');\n            obs.setList([]);\n            this.showVars();\n        }","funcProperties":{"__isSmartRef__":true,"id":62},"__LivelyClassName__":"lively.Closure"},"61":{"this":{"__isSmartRef__":true,"id":16}},"62":{"user":"jenslincke","__serializedExpressions__":["timestamp"],"timestamp":"new Date(\"Tue Jun 02 2015 18:14:32 GMT+0200 (W. Europe Daylight Time)\")"},"63":{"varMapping":{"__isSmartRef__":true,"id":64},"source":"function reset() {\n        this.setStyleSheet('.list-item { font-size: 9pt; }')\n        this.state = {\n            doNotSerialize: ['workspaceVars'],\n            workspaceVars: {},\n            depth: 1\n        };\n        this.showVars();\n        this.textString = '';\n        lively.bindings.connect(this.get(\"toggleVarsButton\"), 'fire', this, 'toggleVarArea');\n    }","funcProperties":{"__isSmartRef__":true,"id":65},"__LivelyClassName__":"lively.Closure"},"64":{"this":{"__isSmartRef__":true,"id":16}},"65":{"user":"jenslincke","__serializedExpressions__":["timestamp"],"timestamp":"new Date(\"Tue Jun 02 2015 18:14:32 GMT+0200 (W. Europe Daylight Time)\")"},"66":{"varMapping":{"__isSmartRef__":true,"id":67},"source":"function resetState() {\n        this.owner.targetMorph = this;\n        this.state = {\n            depth: 1,\n            doNotSerialize: [\"workspaceVars\"],\n            workspaceVars: {},\n            defRanges: {}\n        }\n        this.showVars();\n        lively.bindings.connect(this.get(\"workspaceVarObserver\"), \"selection\", this, \"selectVarDef\");\n    }","funcProperties":{"__isSmartRef__":true,"id":68},"__LivelyClassName__":"lively.Closure"},"67":{"this":{"__isSmartRef__":true,"id":16}},"68":{"user":"jenslincke","__serializedExpressions__":["timestamp"],"timestamp":"new Date(\"Tue Jun 02 2015 18:14:32 GMT+0200 (W. Europe Daylight Time)\")"},"69":{"varMapping":{"__isSmartRef__":true,"id":70},"source":"function selectVarDef(selection) {\n        if (!selection) return;\n        var name = selection.item.value.key\n        var defRanges = this.state.defRanges[name];\n        if (!defRanges || !defRanges.length) return;\n        var range = defRanges.last();\n        this.setSelectionRange(range.start, range.end, true);\n    }","funcProperties":{"__isSmartRef__":true,"id":71},"__LivelyClassName__":"lively.Closure"},"70":{"this":{"__isSmartRef__":true,"id":16}},"71":{"user":"jenslincke","__serializedExpressions__":["timestamp"],"timestamp":"new Date(\"Tue Jun 02 2015 18:14:32 GMT+0200 (W. Europe Daylight Time)\")"},"72":{"varMapping":{"__isSmartRef__":true,"id":73},"source":"function showVariableArea() {\n        var border = 2,\n            varAreaWidth = 220,\n            varList = this.get(\"listContainer\"),\n            newEditorBounds = rect(\n                pt(3,22),\n                varList.bounds().bottomRight().addXY(-3 - varAreaWidth - border, 0));\n    \n        varList.setExtent(varList.getExtent().withX(varAreaWidth));\n        varList.align(varList.bounds().topRight(), this.getWindow().innerBounds().topRight().addXY(-3,22));\n    \n        this.updateToggleVarsButton(newEditorBounds);\n    \n        this.animatedSetBounds(this, newEditorBounds);\n        this.startStepping(1000, \"showVars\");\n    }","funcProperties":{"__isSmartRef__":true,"id":74},"__LivelyClassName__":"lively.Closure"},"73":{"this":{"__isSmartRef__":true,"id":16}},"74":{"user":"jenslincke","__serializedExpressions__":["timestamp"],"timestamp":"new Date(\"Tue Jun 02 2015 18:14:32 GMT+0200 (W. Europe Daylight Time)\")"},"75":{"varMapping":{"__isSmartRef__":true,"id":76},"source":"function showVars() {\n            // this.startStepping(1000, 'showVars')\n            // obs.setList([]);\n\n            var style = {\n                allowInput: false,\n                fixedHeight: false, fixedWidth: true,\n                whiteSpaceHandling: 'pre',\n                cssStylingMode: true\n            };\n\n            var s = this.state;\n            var vars = s.workspaceVars || {};\n            var keys = Object.keys(vars);\n\n            var obs = this.get('workspaceVarObserver');\n            var list = obs.getList() || [];\n\n            var preexistingItems = list.filter(function(item) {\n                    return keys.include(item.value.key); })\n                .map(function(ea) {\n                    ea.value = {key: ea.value.key, value: vars[ea.value.key]};\n                    ea.morph = render(ea.value.key, ea.value.value, ea.morph);\n                    return ea\n                });\n\n            var newItems = keys\n                .withoutAll(preexistingItems.pluck('value').pluck('key'))\n                .map(function(k) {\n                    var morph = render(k, vars[k]),\n                        item = {morph: morph, isListItem: true, string: 'foo', value: {key: k, value: vars[k]}};\n                    morph.item = item;\n                    return item; });\n\n            var items = preexistingItems.concat(newItems);\n\n            obs.setList(items);\n            obs.applyLayout();\n\n            // -=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-\n\n            function render(key, val, optListItemMorph) {\n                var morph = optListItemMorph || createListItemMorph();\n\n                var valString = stringifyObj(val);\n                var string = key + ': ' + valString;\n                if (morph.textString !== string) {\n                    morph.setClipMode('visible');\n                    morph.textString = string;\n                    morph.fitThenDo(function() { morph.setClipMode(\"hidden\"); });\n                };\n\n                return morph;\n            }\n\n            function createListItemMorph() {\n                var morph = new lively.morphic.Text(\n                    obs.getExtent()\n                        .addXY(-2 * obs.layout.layouter.borderSize, 0)\n                        .extentAsRectangle(), '');\n\n                morph.applyStyle(style);\n\n                morph.addStyleClassName('list-item');\n\n                morph.addScript(function showControls() {\n                    var resetButton = new lively.morphic.Button(this.innerBounds());\n                    resetButton.align(resetButton.getPosition(), this.innerBounds().bottomLeft());\n                    this.controls = [\n                        this.addMorph(resetButton)\n                    ];\n                    this.cachedBounds = null;\n                    this.owner.applyLayout();\n                });\n\n                morph.addScript(function hideControls() {\n                    this.controls.invoke('remove');\n                    this.controls.length = 0;\n                    this.owner.applyLayout();\n                })\n\n                morph.addScript(function onHoverIn(evt) {\n                    this.showControls();\n                });\n\n                morph.addScript(function onHoverOut(evt) {\n                    this.hideControls();\n                });\n\n                morph.addScript(function onMouseMove(evt) {\n                    if (this.thereIsAHandInMe) return false;\n                    this.thereIsAHandInMe = true;\n                    this.onHoverIn(evt);\n                });\n\n                morph.addScript(function onMouseOut(evt) {\n                    var wasHovered = !!this.thereIsAHandInMe;\n                    var hoverInMorph = evt.relatedTarget && lively.$(evt.relatedTarget).parents('.morphNode').data('morph');\n                    if (hoverInMorph && (hoverInMorph === this || hoverInMorph.ownerChain().include(this))) return;\n                    this.thereIsAHandInMe = false;\n                    wasHovered && this.onHoverOut(evt);\n                });\n\n                return morph;\n            }\n\n            function stringifyObj(obj) {\n                var string = String(obj);\n                return string.truncate(250);\n                var string;\n                if (obj && obj.isMorph) {\n                    string = obj.toString();\n                } else {\n                     string = Objects.inspect(obj, {maxDepth: s.depth});\n                }\n                return string.truncate(250);\n            }\n        }","funcProperties":{"__isSmartRef__":true,"id":77},"__LivelyClassName__":"lively.Closure"},"76":{"this":{"__isSmartRef__":true,"id":16}},"77":{"user":"jenslincke","__serializedExpressions__":["timestamp"],"timestamp":"new Date(\"Tue Jun 02 2015 18:14:32 GMT+0200 (W. Europe Daylight Time)\")"},"78":{"varMapping":{"__isSmartRef__":true,"id":79},"source":"function toggleVarArea() {\n        this[this.varAreaIsHidden() ? \"showVariableArea\" : \"hideVariableArea\"]();\n    }","funcProperties":{"__isSmartRef__":true,"id":80},"__LivelyClassName__":"lively.Closure"},"79":{"this":{"__isSmartRef__":true,"id":16}},"80":{"user":"jenslincke","__serializedExpressions__":["timestamp"],"timestamp":"new Date(\"Tue Jun 02 2015 18:14:32 GMT+0200 (W. Europe Daylight Time)\")"},"81":{"varMapping":{"__isSmartRef__":true,"id":82},"source":"function updateToggleVarsButton(bnds) {\n        var btn = this.get(\"toggleVarsButton\");\n        bnds = bnds || this.bounds();\n\n        var newButtonBounds = btn.bounds().withTopRight(bnds.topRight().addXY(-4,4))\n        this.animatedSetBounds(btn, newButtonBounds);\n\n        var hidden = this.varAreaIsHidden();\n        var label = hidden ? \"hide vars\" : \"show vars\";\n        btn.setLabel(label);\n        if (this.owner.submorphs.indexOf(btn) < this.owner.submorphs.indexOf(this))\n            this.owner.addMorph(this, btn);\n    }","funcProperties":{"__isSmartRef__":true,"id":83},"__LivelyClassName__":"lively.Closure"},"82":{"this":{"__isSmartRef__":true,"id":16}},"83":{"user":"jenslincke","__serializedExpressions__":["timestamp"],"timestamp":"new Date(\"Tue Jun 02 2015 18:14:32 GMT+0200 (W. Europe Daylight Time)\")"},"84":{"varMapping":{"__isSmartRef__":true,"id":85},"source":"function varAreaIsHidden() {\n        this.cachedBounds = null;\n        this.aceEditor.resize(true)\n        var varsAreVisible = this.getWindow().getExtent().x - this.bounds().width > 30;\n        return !varsAreVisible\n    }","funcProperties":{"__isSmartRef__":true,"id":86},"__LivelyClassName__":"lively.Closure"},"85":{"this":{"__isSmartRef__":true,"id":16}},"86":{"user":"jenslincke","__serializedExpressions__":["timestamp"],"timestamp":"new Date(\"Tue Jun 02 2015 18:14:32 GMT+0200 (W. Europe Daylight Time)\")"},"87":{"submorphs":[],"scripts":[],"id":"50778028-878A-415C-BA19-109DC087E3E7","shape":{"__isSmartRef__":true,"id":88},"droppingEnabled":true,"halosEnabled":true,"registeredForMouseEvents":true,"showsHalos":false,"name":"ResizeCorner","partsBinMetaInfo":{"__isSmartRef__":true,"id":89},"draggingEnabled":true,"dragStartPoint":null,"originalTargetExtent":null,"eventHandler":{"__isSmartRef__":true,"id":90},"originalTargetInnerBounds":null,"isResizeCorner":true,"relativeOrigin":null,"derivationIds":[7147,"16E962DF-21E9-4FE6-8B9B-953F0E908113","ADD0B5C0-0DC6-4D8E-9C2A-0EC7E3C71F21"],"moved":true,"attributeConnections":[{"__isSmartRef__":true,"id":91}],"doNotSerialize":["$$cornerName"],"doNotCopyProperties":["$$cornerName"],"originalTargetBounds":null,"cornerName":"bottomRight","_ClipMode":"visible","owner":{"__isSmartRef__":true,"id":0},"__serializedExpressions__":["_Position","originalExtent"],"_Rotation":0,"_Scale":1,"__serializedLivelyClosures__":{"__isSmartRef__":true,"id":92},"__LivelyClassName__":"lively.morphic.Box","__SourceModuleName__":"Global.lively.morphic.Core","_Position":"lively.pt(872.7,166.6)","originalExtent":"lively.pt(239.0,138.0)"},"88":{"_BorderWidth":0,"_ClipMode":"visible","__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(10.0,10.0)","_BorderColor":"Color.rgb(145,145,145)","_Fill":"Color.rgb(66,66,66)","_Padding":"lively.rect(0,0,0,0)"},"89":{"partsSpaceName":"PartsBin/Widgets/","migrationLevel":2,"comment":"Resize an object without using halos.","partName":"ResizeCorner","__serializedExpressions__":["lastModifiedDate"],"__LivelyClassName__":"lively.PartsBin.PartsBinMetaInfo","__SourceModuleName__":"Global.lively.PartsBin","lastModifiedDate":"new Date(\"Thu Sep 06 2012 01:01:36 GMT+0200 (W. Europe Daylight Time)\")"},"90":{"morph":{"__isSmartRef__":true,"id":87},"__LivelyClassName__":"lively.morphic.EventHandler","__SourceModuleName__":"Global.lively.morphic.Events"},"91":{"sourceObj":{"__isSmartRef__":true,"id":87},"sourceAttrName":"cornerName","targetObj":{"__isSmartRef__":true,"id":87},"targetMethodName":"alignToOwner","__LivelyClassName__":"AttributeConnection","__SourceModuleName__":"Global.lively.bindings.Core"},"92":{"onDrag":{"__isSmartRef__":true,"id":93},"onDragEnd":{"__isSmartRef__":true,"id":100},"onDragStart":{"__isSmartRef__":true,"id":107},"reset":{"__isSmartRef__":true,"id":114},"morphMenuItems":{"__isSmartRef__":true,"id":117},"alignToOwner":{"__isSmartRef__":true,"id":124}},"93":{"varMapping":{"__isSmartRef__":true,"id":94},"source":"function onDrag(evt) {\n    // alert(\"onDrag\")\n    // this.owner.setPosition(pt(0,0))\n    // this.owner.setOrigin(pt(0,0))\n    var moveDelta = evt.mousePoint.subPt(this.dragStartPoint)\n    \n    // moveDelta = moveDelta.maxPt(pt(0,0))\n    var ownerExtent = this.owner.getExtent();\n\n    // TODO does not work\n    if (evt.isShiftDown()) {\n        var maxDelta = Math.max(moveDelta.x, moveDelta.y);\n        if (maxDelta == 0) return;\n        var factor = ownerExtent.x /  ownerExtent.y\n        moveDelta = pt(maxDelta * factor, maxDelta )\n    }\n    var accessor = \"with\" + this.cornerName.charAt(0).toUpperCase() + this.cornerName.substring(1);\n\n    var newCorner = this.originalTargetBounds[this.cornerName]().addPt(moveDelta);\n    var newBounds = this.originalTargetBounds[accessor ](newCorner);\n\n    this.owner.setBounds(newBounds);\n   \n    // var newExtent = this.originalTargetExtent.addPt(moveDelta)\n    // alertOK(\"new extent\" + newExtent)\n    // this.owner.setExtent(newExtent);\n    this.owner.submorphs.select(function(ea) {\n        return ea.isResizeCorner\n    }).invoke('alignToOwner');\n    if (this.owner.halos) {\n        this.owner.halos.invoke('alignAtTarget')\n    }\n    // alertOK(\"relative \" + this.relativeOrigin)\n    var newOrigin =  pt(0,0).extent(this.owner.getExtent()).relativeToAbsPoint(this.relativeOrigin)\n\n    // TODO IMPLEMENT updating the origin does not work yet\n    // this.owner.setOrigin(newOrigin);\n    // alertOK(\"new origin \" + newOrigin)\n\n}","funcProperties":{"__isSmartRef__":true,"id":99},"__LivelyClassName__":"lively.Closure"},"94":{"this":{"__isSmartRef__":true,"id":87},"__serializedLivelyClosures__":{"__isSmartRef__":true,"id":95}},"95":{"$super":{"__isSmartRef__":true,"id":96}},"96":{"varMapping":{"__isSmartRef__":true,"id":97},"source":"function () {\n                    try {\n                        return obj.constructor.prototype[name].apply(obj, arguments)\n                    } catch (e) {\n                        alert('Error in $super call: ' + e + '\\n' + e.stack);\n                        return null;\n                    }\n                }","funcProperties":{"__isSmartRef__":true,"id":98},"__LivelyClassName__":"lively.Closure"},"97":{"obj":{"__isSmartRef__":true,"id":87},"name":"onDrag"},"98":{},"99":{"user":"sstamm","tags":[],"__serializedExpressions__":["timestamp"],"timestamp":"new Date(\"Thu Feb 23 2012 12:08:52 GMT+0100 (W. Europe Standard Time)\")"},"100":{"varMapping":{"__isSmartRef__":true,"id":101},"source":"function onDragEnd(evt) {\n    this.dragStartPoint = null;\n    this.originalTargetBounds = null;\n    this.relativeOrigin = null;\n}","funcProperties":{"__isSmartRef__":true,"id":106},"__LivelyClassName__":"lively.Closure"},"101":{"this":{"__isSmartRef__":true,"id":87},"__serializedLivelyClosures__":{"__isSmartRef__":true,"id":102}},"102":{"$super":{"__isSmartRef__":true,"id":103}},"103":{"varMapping":{"__isSmartRef__":true,"id":104},"source":"function () {\n                    try {\n                        return obj.constructor.prototype[name].apply(obj, arguments)\n                    } catch (e) {\n                        alert('Error in $super call: ' + e + '\\n' + e.stack);\n                        return null;\n                    }\n                }","funcProperties":{"__isSmartRef__":true,"id":105},"__LivelyClassName__":"lively.Closure"},"104":{"obj":{"__isSmartRef__":true,"id":87},"name":"onDragEnd"},"105":{},"106":{"user":"sstamm","tags":[],"__serializedExpressions__":["timestamp"],"timestamp":"new Date(\"Thu Feb 23 2012 12:09:00 GMT+0100 (W. Europe Standard Time)\")"},"107":{"varMapping":{"__isSmartRef__":true,"id":108},"source":"function onDragStart(evt) {\n    var absToRelativePoint =  function (r, absPt) {\n\t\treturn new Point(\n\t\t\t(absPt.x - r.x) / r.width,\n\t\t\t(absPt.y - r.y) / r.height)\n\t}\n    // absToRelativePoint(new Rectangle(10,10,100,100), pt(20,20))\n    // absToRelativePoint(new Rectangle(10,10,100,100), pt(0,0))\n    // absToRelativePoint(new Rectangle(-100,-100,200,200), pt(0,0))\n\n\n    this.dragStartPoint = evt.mousePoint;\n    this.originalTargetBounds= this.owner.bounds();\n    this.relativeOrigin =  absToRelativePoint(pt(0,0).extent(this.owner.getExtent()), this.owner.getOrigin())\n}","funcProperties":{"__isSmartRef__":true,"id":113},"__LivelyClassName__":"lively.Closure"},"108":{"this":{"__isSmartRef__":true,"id":87},"__serializedLivelyClosures__":{"__isSmartRef__":true,"id":109}},"109":{"$super":{"__isSmartRef__":true,"id":110}},"110":{"varMapping":{"__isSmartRef__":true,"id":111},"source":"function () {\n                    try {\n                        return obj.constructor.prototype[name].apply(obj, arguments)\n                    } catch (e) {\n                        alert('Error in $super call: ' + e + '\\n' + e.stack);\n                        return null;\n                    }\n                }","funcProperties":{"__isSmartRef__":true,"id":112},"__LivelyClassName__":"lively.Closure"},"111":{"obj":{"__isSmartRef__":true,"id":87},"name":"onDragStart"},"112":{},"113":{"user":"sstamm","tags":[],"__serializedExpressions__":["timestamp"],"timestamp":"new Date(\"Thu Feb 23 2012 12:08:40 GMT+0100 (W. Europe Standard Time)\")"},"114":{"varMapping":{"__isSmartRef__":true,"id":115},"source":"function reset() {\n    this.isResizeCorner = true\n    this.cornerName = 'bottomRight'\n    this.setExtent(pt(10,10));\n    this.setPosition(pt(0,0))\n}","funcProperties":{"__isSmartRef__":true,"id":116},"__LivelyClassName__":"lively.Closure"},"115":{"this":{"__isSmartRef__":true,"id":87}},"116":{},"117":{"varMapping":{"__isSmartRef__":true,"id":118},"source":"function morphMenuItems() {\n    return $super().concat([\n        [\"corner\", [\n            [\"top left\", function() { this.cornerName = 'topLeft'}.bind(this)],\n            [\"top right\", function() { this.cornerName = 'topRight'}.bind(this)],\n            [\"bottom right\", function() { this.cornerName = 'bottomRight'}.bind(this)],\n            [\"bottom left\", function() { this.cornerName = 'bottomLeft'}.bind(this)],\n        ]]\n    ])\t\n}","funcProperties":{"__isSmartRef__":true,"id":123},"__LivelyClassName__":"lively.Closure"},"118":{"this":{"__isSmartRef__":true,"id":87},"__serializedLivelyClosures__":{"__isSmartRef__":true,"id":119}},"119":{"$super":{"__isSmartRef__":true,"id":120}},"120":{"varMapping":{"__isSmartRef__":true,"id":121},"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":122},"__LivelyClassName__":"lively.Closure"},"121":{"obj":{"__isSmartRef__":true,"id":87},"name":"morphMenuItems"},"122":{},"123":{},"124":{"varMapping":{"__isSmartRef__":true,"id":125},"source":"function alignToOwner() {\n    this.align(this.bounds()[this.cornerName](), this.owner.shape.bounds()[this.cornerName]() )\n}","funcProperties":{"__isSmartRef__":true,"id":126},"__LivelyClassName__":"lively.Closure"},"125":{"this":{"__isSmartRef__":true,"id":87}},"126":{},"127":{"submorphs":[{"__isSmartRef__":true,"id":128}],"scripts":[],"shape":{"__isSmartRef__":true,"id":133},"eventHandler":{"__isSmartRef__":true,"id":134},"_ClipMode":"visible","derivationIds":["EC7EBB28-54AE-4244-80ED-3E13650F82B7","9FD2DCE2-B997-4536-B2A5-90D7DD92B3E6","0D8CC908-BD1C-4062-BB03-3FCEB910483D"],"id":"B8265A02-7262-4E1E-B10C-4AF6FEE5D103","grabbingEnabled":false,"droppingEnabled":false,"halosEnabled":true,"value":false,"toggle":false,"isActive":true,"label":{"__isSmartRef__":true,"id":128},"_PreviousBorderWidth":1,"isPressed":false,"showsHalos":false,"attributeConnections":[{"__isSmartRef__":true,"id":135},{"__isSmartRef__":true,"id":137}],"doNotSerialize":["$$fire"],"doNotCopyProperties":["$$fire"],"name":"Button","partsBinMetaInfo":{"__isSmartRef__":true,"id":139},"pinSpecs":[{"__isSmartRef__":true,"id":147}],"owner":{"__isSmartRef__":true,"id":0},"_StyleClassNames":["Morph","Button"],"doAction":false,"__serializedExpressions__":["_Position","distanceToDragEvent"],"_Rotation":0,"_Scale":1,"__LivelyClassName__":"lively.morphic.Button","__SourceModuleName__":"Global.lively.morphic.Widgets","_Position":"lively.pt(1.3,4.1)","distanceToDragEvent":"lively.pt(53.7,-6.9)"},"128":{"submorphs":[],"scripts":[],"shape":{"__isSmartRef__":true,"id":129},"_WhiteSpaceHandling":"pre-wrap","textChunks":[{"__isSmartRef__":true,"id":130}],"eventHandler":{"__isSmartRef__":true,"id":132},"_ClipMode":"hidden","derivationIds":["7884E73F-0D17-44B3-907F-44A5223F1F3D","444B63A6-D9E7-4AB2-AB57-4A9146C18BFF","08999E10-CCC3-4CAB-99BC-4EF500309EC4"],"id":"7BFF6BFF-F029-4538-9703-B581441843C4","grabbingEnabled":false,"droppingEnabled":false,"halosEnabled":true,"fixedWidth":true,"_WordBreak":"break-all","fixedHeight":true,"_InputAllowed":false,"_HandStyle":"default","allowInput":false,"_FontFamily":"Helvetica","_FontSize":10,"evalEnabled":false,"owner":{"__isSmartRef__":true,"id":127},"isLabel":true,"_Align":"center","eventsAreIgnored":true,"_TextStylingMode":true,"showsHalos":false,"eventsAreDisabled":true,"_PointerEvents":"none","__serializedExpressions__":["_TextColor"],"__LivelyClassName__":"lively.morphic.Text","__SourceModuleName__":"Global.lively.morphic.TextCore","_TextColor":"Color.rgb(0,0,0)"},"129":{"_BorderWidth":0,"_Fill":null,"__serializedExpressions__":["_Position","_Extent","_Padding","_BorderColor"],"__LivelyClassName__":"lively.morphic.Shapes.Rectangle","__SourceModuleName__":"Global.lively.morphic.Shapes","_Position":"lively.pt(0.0,0.0)","_Extent":"lively.pt(63.0,19.0)","_Padding":"lively.rect(0,3,0,0)","_BorderColor":"Color.rgb(0,0,0)"},"130":{"style":{"__isSmartRef__":true,"id":131},"chunkOwner":{"__isSmartRef__":true,"id":128},"_id":"_5833","storedString":"Do it","__LivelyClassName__":"lively.morphic.TextChunk","__SourceModuleName__":"Global.lively.morphic.TextCore"},"131":{"__serializedExpressions__":["color"],"__LivelyClassName__":"lively.morphic.TextEmphasis","__SourceModuleName__":"Global.lively.morphic.TextCore","color":"Color.rgb(0,0,0)"},"132":{"morph":{"__isSmartRef__":true,"id":128},"__LivelyClassName__":"lively.morphic.EventHandler","__SourceModuleName__":"Global.lively.morphic.Events"},"133":{"_BorderWidth":1,"_BorderRadius":5,"_AppearanceStylingMode":false,"_BorderStylingMode":true,"_Opacity":1,"__serializedExpressions__":["_Position","_Extent","_Padding","_BorderColor"],"__LivelyClassName__":"lively.morphic.Shapes.Rectangle","__SourceModuleName__":"Global.lively.morphic.Shapes","_Position":"lively.pt(0.0,0.0)","_Extent":"lively.pt(63.0,19.0)","_Padding":"lively.rect(0,0,0,0)","_BorderColor":"Color.rgb(189,190,192)"},"134":{"morph":{"__isSmartRef__":true,"id":127},"__LivelyClassName__":"lively.morphic.EventHandler","__SourceModuleName__":"Global.lively.morphic.Events"},"135":{"sourceObj":{"__isSmartRef__":true,"id":127},"sourceAttrName":"fire","targetObj":{"__isSmartRef__":true,"id":127},"targetMethodName":"doAction","varMapping":{"__isSmartRef__":true,"id":136},"__LivelyClassName__":"AttributeConnection","__SourceModuleName__":"Global.lively.bindings.Core"},"136":{"source":{"__isSmartRef__":true,"id":127},"target":{"__isSmartRef__":true,"id":127}},"137":{"sourceObj":{"__isSmartRef__":true,"id":127},"sourceAttrName":"fire","targetObj":{"__isSmartRef__":true,"id":0},"targetMethodName":"evalAll","varMapping":{"__isSmartRef__":true,"id":138},"__LivelyClassName__":"AttributeConnection","__SourceModuleName__":"Global.lively.bindings.Core"},"138":{"source":{"__isSmartRef__":true,"id":127},"target":{"__isSmartRef__":true,"id":0}},"139":{"partName":"Button","requiredModules":[],"partsSpaceName":"PartsBin/Inputs","comment":"A simple button that calls a method #doAction when pressed.","changes":[{"__isSmartRef__":true,"id":140},{"__isSmartRef__":true,"id":141},{"__isSmartRef__":true,"id":142},{"__isSmartRef__":true,"id":143},{"__isSmartRef__":true,"id":144},{"__isSmartRef__":true,"id":145},{"__isSmartRef__":true,"id":146}],"migrationLevel":7,"__serializedExpressions__":["lastModifiedDate"],"__LivelyClassName__":"lively.PartsBin.PartsBinMetaInfo","__SourceModuleName__":"Global.lively.PartsBin","lastModifiedDate":"new Date(\"Wed Jul 24 2013 08:21:12 GMT+0200 (W. Europe Daylight Time)\")"},"140":{"author":null,"message":"no comment","id":"F8B70225-5143-4A51-ABB4-344B488B3811","__serializedExpressions__":["date"],"date":"new Date(\"Tue Dec 11 2012 22:15:42 GMT+0100 (W. Europe Standard Time)\")"},"141":{"author":"robertkrahn","message":"no comment","id":"9B8B6BE4-4519-4A6C-8F47-70DE61BBB0FB","__serializedExpressions__":["date"],"date":"new Date(\"Tue Dec 11 2012 22:53:16 GMT+0100 (W. Europe Standard Time)\")"},"142":{"author":"robertkrahn","message":"test","id":"ACA617B4-0416-4E3C-9F4D-171A40F44F0F","__serializedExpressions__":["date"],"date":"new Date(\"Wed May 01 2013 05:34:25 GMT+0200 (W. Europe Daylight Time)\")"},"143":{"author":"robertkrahn","message":"no comment","id":"811BDE87-D8DD-48BB-97B2-7A3C3F3FAE32","__serializedExpressions__":["date"],"date":"new Date(\"Wed May 01 2013 05:35:59 GMT+0200 (W. Europe Daylight Time)\")"},"144":{"author":"robertkrahn","message":"no comment","id":"BB2EA501-D9AF-414B-A035-E1487DA6F0FD","__serializedExpressions__":["date"],"date":"new Date(\"Wed May 01 2013 05:36:30 GMT+0200 (W. Europe Daylight Time)\")"},"145":{"author":"Dan","message":"no comment","id":"A594459F-DA9B-49DD-A105-547B3F613CC5","__serializedExpressions__":["date"],"date":"new Date(\"Mon Jun 17 2013 19:22:38 GMT+0200 (W. Europe Daylight Time)\")"},"146":{"author":"Dan","message":"no comment","id":"CFEC4071-14FF-4AEB-A399-197884CD18BF","__serializedExpressions__":["date"],"date":"new Date(\"Mon Jun 17 2013 19:24:50 GMT+0200 (W. Europe Daylight Time)\")"},"147":{"pinName":"fire","modality":"output","type":"Boolean","accessor":"fire","location":1.5},"148":{"submorphs":[{"__isSmartRef__":true,"id":149}],"scripts":[],"shape":{"__isSmartRef__":true,"id":154},"eventHandler":{"__isSmartRef__":true,"id":155},"_ClipMode":"visible","derivationIds":["EC7EBB28-54AE-4244-80ED-3E13650F82B7","9FD2DCE2-B997-4536-B2A5-90D7DD92B3E6","0D8CC908-BD1C-4062-BB03-3FCEB910483D","B8265A02-7262-4E1E-B10C-4AF6FEE5D103"],"id":"36272DBC-79DF-4B1E-A705-0165519382B4","grabbingEnabled":false,"droppingEnabled":false,"halosEnabled":true,"value":false,"toggle":false,"isActive":true,"label":{"__isSmartRef__":true,"id":149},"_PreviousBorderWidth":1,"isPressed":false,"showsHalos":false,"attributeConnections":[{"__isSmartRef__":true,"id":156}],"doNotSerialize":["$$fire"],"doNotCopyProperties":["$$fire"],"name":"Button1","partsBinMetaInfo":{"__isSmartRef__":true,"id":158},"pinSpecs":[{"__isSmartRef__":true,"id":166}],"_StyleClassNames":["Morph","Button"],"owner":{"__isSmartRef__":true,"id":0},"layout":{"__isSmartRef__":true,"id":167},"__serializedExpressions__":["_Position","distanceToDragEvent"],"_Rotation":0,"_Scale":1,"__serializedLivelyClosures__":{"__isSmartRef__":true,"id":168},"__LivelyClassName__":"lively.morphic.Button","__SourceModuleName__":"Global.lively.morphic.Widgets","_Position":"lively.pt(514.6,4.1)","distanceToDragEvent":"lively.pt(64.4,-14.9)"},"149":{"submorphs":[],"scripts":[],"shape":{"__isSmartRef__":true,"id":150},"_WhiteSpaceHandling":"pre-wrap","textChunks":[{"__isSmartRef__":true,"id":151}],"eventHandler":{"__isSmartRef__":true,"id":153},"_ClipMode":"hidden","derivationIds":["7884E73F-0D17-44B3-907F-44A5223F1F3D","444B63A6-D9E7-4AB2-AB57-4A9146C18BFF","08999E10-CCC3-4CAB-99BC-4EF500309EC4","7BFF6BFF-F029-4538-9703-B581441843C4"],"id":"1731FE84-2D41-421C-8890-4B4FD271CF2D","grabbingEnabled":false,"droppingEnabled":false,"halosEnabled":true,"fixedWidth":true,"_WordBreak":"break-all","fixedHeight":true,"_InputAllowed":false,"_HandStyle":"default","allowInput":false,"_FontFamily":"Helvetica","_FontSize":10,"evalEnabled":false,"owner":{"__isSmartRef__":true,"id":148},"isLabel":true,"_Align":"center","eventsAreIgnored":true,"_TextStylingMode":true,"showsHalos":false,"eventsAreDisabled":true,"_PointerEvents":"none","__serializedExpressions__":["_TextColor"],"__LivelyClassName__":"lively.morphic.Text","__SourceModuleName__":"Global.lively.morphic.TextCore","_TextColor":"Color.rgb(0,0,0)"},"150":{"_BorderWidth":0,"_Fill":null,"__serializedExpressions__":["_Position","_Extent","_Padding","_BorderColor"],"__LivelyClassName__":"lively.morphic.Shapes.Rectangle","__SourceModuleName__":"Global.lively.morphic.Shapes","_Position":"lively.pt(0.0,0.0)","_Extent":"lively.pt(77.7,20.5)","_Padding":"lively.rect(0,3,0,0)","_BorderColor":"Color.rgb(0,0,0)"},"151":{"style":{"__isSmartRef__":true,"id":152},"chunkOwner":{"__isSmartRef__":true,"id":149},"_id":"_5997","storedString":"maximize","__LivelyClassName__":"lively.morphic.TextChunk","__SourceModuleName__":"Global.lively.morphic.TextCore"},"152":{"__serializedExpressions__":["color"],"__LivelyClassName__":"lively.morphic.TextEmphasis","__SourceModuleName__":"Global.lively.morphic.TextCore","color":"Color.rgb(0,0,0)"},"153":{"morph":{"__isSmartRef__":true,"id":149},"__LivelyClassName__":"lively.morphic.EventHandler","__SourceModuleName__":"Global.lively.morphic.Events"},"154":{"_BorderWidth":1,"_BorderRadius":5,"_AppearanceStylingMode":false,"_BorderStylingMode":true,"_Opacity":1,"__serializedExpressions__":["_Position","_Extent","_Padding","_BorderColor"],"__LivelyClassName__":"lively.morphic.Shapes.Rectangle","__SourceModuleName__":"Global.lively.morphic.Shapes","_Position":"lively.pt(0.0,0.0)","_Extent":"lively.pt(77.7,20.5)","_Padding":"lively.rect(0,0,0,0)","_BorderColor":"Color.rgb(189,190,192)"},"155":{"morph":{"__isSmartRef__":true,"id":148},"__LivelyClassName__":"lively.morphic.EventHandler","__SourceModuleName__":"Global.lively.morphic.Events"},"156":{"sourceObj":{"__isSmartRef__":true,"id":148},"sourceAttrName":"fire","targetObj":{"__isSmartRef__":true,"id":148},"targetMethodName":"doAction","varMapping":{"__isSmartRef__":true,"id":157},"__LivelyClassName__":"AttributeConnection","__SourceModuleName__":"Global.lively.bindings.Core"},"157":{"source":{"__isSmartRef__":true,"id":148},"target":{"__isSmartRef__":true,"id":148}},"158":{"partName":"Button","requiredModules":[],"partsSpaceName":"PartsBin/Inputs","comment":"A simple button that calls a method #doAction when pressed.","changes":[{"__isSmartRef__":true,"id":159},{"__isSmartRef__":true,"id":160},{"__isSmartRef__":true,"id":161},{"__isSmartRef__":true,"id":162},{"__isSmartRef__":true,"id":163},{"__isSmartRef__":true,"id":164},{"__isSmartRef__":true,"id":165}],"migrationLevel":7,"__serializedExpressions__":["lastModifiedDate"],"__LivelyClassName__":"lively.PartsBin.PartsBinMetaInfo","__SourceModuleName__":"Global.lively.PartsBin","lastModifiedDate":"new Date(\"Wed Jul 24 2013 08:21:12 GMT+0200 (W. Europe Daylight Time)\")"},"159":{"author":null,"message":"no comment","id":"F8B70225-5143-4A51-ABB4-344B488B3811","__serializedExpressions__":["date"],"date":"new Date(\"Tue Dec 11 2012 22:15:42 GMT+0100 (W. Europe Standard Time)\")"},"160":{"author":"robertkrahn","message":"no comment","id":"9B8B6BE4-4519-4A6C-8F47-70DE61BBB0FB","__serializedExpressions__":["date"],"date":"new Date(\"Tue Dec 11 2012 22:53:16 GMT+0100 (W. Europe Standard Time)\")"},"161":{"author":"robertkrahn","message":"test","id":"ACA617B4-0416-4E3C-9F4D-171A40F44F0F","__serializedExpressions__":["date"],"date":"new Date(\"Wed May 01 2013 05:34:25 GMT+0200 (W. Europe Daylight Time)\")"},"162":{"author":"robertkrahn","message":"no comment","id":"811BDE87-D8DD-48BB-97B2-7A3C3F3FAE32","__serializedExpressions__":["date"],"date":"new Date(\"Wed May 01 2013 05:35:59 GMT+0200 (W. Europe Daylight Time)\")"},"163":{"author":"robertkrahn","message":"no comment","id":"BB2EA501-D9AF-414B-A035-E1487DA6F0FD","__serializedExpressions__":["date"],"date":"new Date(\"Wed May 01 2013 05:36:30 GMT+0200 (W. Europe Daylight Time)\")"},"164":{"author":"Dan","message":"no comment","id":"A594459F-DA9B-49DD-A105-547B3F613CC5","__serializedExpressions__":["date"],"date":"new Date(\"Mon Jun 17 2013 19:22:38 GMT+0200 (W. Europe Daylight Time)\")"},"165":{"author":"Dan","message":"no comment","id":"CFEC4071-14FF-4AEB-A399-197884CD18BF","__serializedExpressions__":["date"],"date":"new Date(\"Mon Jun 17 2013 19:24:50 GMT+0200 (W. Europe Daylight Time)\")"},"166":{"pinName":"fire","modality":"output","type":"Boolean","accessor":"fire","location":1.5},"167":{"moveHorizontal":true},"168":{"doAction":{"__isSmartRef__":true,"id":169}},"169":{"varMapping":{"__isSmartRef__":true,"id":170},"source":"function doAction() {\n    var morph = this.get(\"Log\")\n    if (this.owner.shape.bounds().bottomRight().eqPt(morph.bounds().bottomRight())) {\n        morph.setExtent(morph.getExtent().scaleBy(3))\n        this.setLabel(\"minimize\")   \n        morph.bringToFront()\n    } else {\n        morph.setBounds(\n           lively.rect(morph.getPosition(),\n           this.owner.shape.bounds().bottomRight()))\n        this.setLabel(\"maximize\")\n        morph.sendToBack()\n    }\n      \n}","funcProperties":{"__isSmartRef__":true,"id":171},"__LivelyClassName__":"lively.Closure"},"170":{"this":{"__isSmartRef__":true,"id":148}},"171":{"__serializedExpressions__":["timestamp"],"user":"unknown_user","timestamp":"new Date(\"Tue Jun 02 2015 22:12:55 GMT+0200 (W. Europe Daylight Time)\")"},"172":{"_BorderWidth":0,"_ClipMode":"visible","_BorderRadius":0,"_Opacity":1,"_BorderStyle":"solid","__serializedExpressions__":["position","_Extent","_BorderColor","_Fill","_Padding"],"_BorderStylingMode":false,"__LivelyClassName__":"lively.morphic.Shapes.Rectangle","__SourceModuleName__":"Global.lively.morphic.Shapes","position":"lively.pt(0.0,0.0)","_Extent":"lively.pt(882.7,176.6)","_BorderColor":"Color.rgb(149,149,149)","_Fill":"Color.rgb(255,255,255)","_Padding":"lively.rect(0,0,0,0)"},"173":{"partsSpaceName":"PartsBin/Jens/","comment":"A code snipped with an expandable log","migrationLevel":9,"partName":"SnippedWithLog","changes":[{"__isSmartRef__":true,"id":174},{"__isSmartRef__":true,"id":175},{"__isSmartRef__":true,"id":176},{"__isSmartRef__":true,"id":177},{"__isSmartRef__":true,"id":178},{"__isSmartRef__":true,"id":179},{"__isSmartRef__":true,"id":180},{"__isSmartRef__":true,"id":181},{"__isSmartRef__":true,"id":182},{"__isSmartRef__":true,"id":183},{"__isSmartRef__":true,"id":184},{"__isSmartRef__":true,"id":185},{"__isSmartRef__":true,"id":186},{"__isSmartRef__":true,"id":187},{"__isSmartRef__":true,"id":188},{"__isSmartRef__":true,"id":189},{"__isSmartRef__":true,"id":190},{"__isSmartRef__":true,"id":191},{"__isSmartRef__":true,"id":192},{"__isSmartRef__":true,"id":193},{"__isSmartRef__":true,"id":194},{"__isSmartRef__":true,"id":195}],"__serializedExpressions__":["lastModifiedDate"],"__LivelyClassName__":"lively.PartsBin.PartsBinMetaInfo","__SourceModuleName__":"Global.lively.PartsBin","lastModifiedDate":"new Date(\"Tue Jun 02 2015 21:28:57 GMT+0200 (W. Europe Daylight Time)\")"},"174":{"author":"jenslincke","message":"no comment","id":"ADFBF069-513C-4DE6-95A9-8AD4985C6508","__serializedExpressions__":["date"],"date":"new Date(\"Tue Feb 04 2014 10:23:53 GMT+0100 (W. Europe Standard Time)\")"},"175":{"author":"robertkrahn","message":"no comment","id":"A452871F-4EB9-45D1-94B8-6065CBA7B8FD","__serializedExpressions__":["date"],"date":"new Date(\"Tue Jul 30 2013 08:20:51 GMT+0200 (W. Europe Daylight Time)\")"},"176":{"author":"SAPLivelyScreen","message":"no comment","id":"7A44D8CA-6D5F-42A3-A4B4-4D7F51EECA52","__serializedExpressions__":["date"],"date":"new Date(\"Tue Jun 18 2013 20:49:27 GMT+0200 (W. Europe Daylight Time)\")"},"177":{"author":"SAPLivelyScreen","message":"no comment","id":"EF145198-0649-41BD-A92E-521D98FEC49D","__serializedExpressions__":["date"],"date":"new Date(\"Thu May 30 2013 00:36:50 GMT+0200 (W. Europe Daylight Time)\")"},"178":{"author":"jenslincke","message":"added legend","id":"7ADA3049-56C1-4D32-874B-F664A79DDB20","__serializedExpressions__":["date"],"date":"new Date(\"Fri Jan 18 2013 16:47:05 GMT+0100 (W. Europe Standard Time)\")"},"179":{"author":"jenslincke","message":"no comment","id":"A4B86A7E-A398-4C29-BEE0-4AA045ABABD2","__serializedExpressions__":["date"],"date":"new Date(\"Fri Jan 18 2013 16:42:31 GMT+0100 (W. Europe Standard Time)\")"},"180":{"author":"jenslincke","message":"I want my blue rectangle back!","id":"5AA9291A-869F-4D36-8095-4721B5A5B205","__serializedExpressions__":["date"],"date":"new Date(\"Thu Nov 22 2012 10:35:51 GMT+0100 (W. Europe Standard Time)\")"},"181":{"author":"bgnauk","message":"no comment","id":"0124E570-50B7-4CE3-83A1-6E7BA89B5CD8","__serializedExpressions__":["date"],"date":"new Date(\"Mon Jun 18 2012 19:35:08 GMT+0200 (W. Europe Daylight Time)\")"},"182":{"author":"undefined","message":"suddenly, the rectangle became a CarDemo","id":"B5083AA8-9BAE-48DD-A6B4-FD7DB3998350","__serializedExpressions__":["date"],"date":"new Date(\"Mon Apr 09 2012 13:42:07 GMT+0200 (W. Europe Daylight Time)\")"},"183":{"author":"undefined","message":"css transitions","id":"1004E0FC-D96B-4F40-B3E0-F514A3FCFFD7","__serializedExpressions__":["date"],"date":"new Date(\"Wed Mar 14 2012 10:42:26 GMT+0100 (W. Europe Standard Time)\")"},"184":{"author":"fbo","message":"","id":"BD1C654D-9100-4B66-BC62-B15FF2498B2B","__serializedExpressions__":["date"],"date":"new Date(\"Sat Feb 25 2012 02:59:09 GMT+0100 (W. Europe Standard Time)\")"},"185":{"author":"undefined","message":"sorry","id":"44B56D2E-9B59-4C67-A305-49A6E10E66C2","__serializedExpressions__":["date"],"date":"new Date(\"Wed Mar 14 2012 10:53:45 GMT+0100 (W. Europe Standard Time)\")"},"186":{"author":"undefined","message":"whoopsie","id":"CEA5DCD5-2DB7-40AD-A776-262A7A0666FC","__serializedExpressions__":["date"],"date":"new Date(\"Thu May 03 2012 15:51:30 GMT+0200 (W. Europe Daylight Time)\")"},"187":{"author":"undefined","message":"whoopsie","id":"3F17A2D2-3C24-424B-B0FA-E43112267D23","__serializedExpressions__":["date"],"date":"new Date(\"Thu May 03 2012 15:51:36 GMT+0200 (W. Europe Daylight Time)\")"},"188":{"author":"jenslincke","message":"no comment","id":"AEB2F41B-2C88-4BBA-8875-93CD17CBA1C8","__serializedExpressions__":["date"],"date":"new Date(\"Wed Jan 23 2013 12:57:18 GMT+0100 (W. Europe Standard Time)\")"},"189":{"author":"robertkrahn","message":"no comment","id":"67FD74CD-7AE4-4050-ADC7-4DF73804258D","__serializedExpressions__":["date"],"date":"new Date(\"Thu May 30 2013 09:18:06 GMT+0200 (W. Europe Daylight Time)\")"},"190":{"author":"robertkrahn","message":"no comment","id":"FBBB9C99-B61C-4D5F-8750-6E2987DF0C9C","__serializedExpressions__":["date"],"date":"new Date(\"Fri Jun 21 2013 00:16:24 GMT+0200 (W. Europe Daylight Time)\")"},"191":{"author":"jenslincke","message":"no comment","id":"ECD12BFF-E872-4918-8341-C6571E72F36D","__serializedExpressions__":["date"],"date":"new Date(\"Tue Feb 04 2014 10:24:27 GMT+0100 (W. Europe Standard Time)\")"},"192":{"author":"lauritz","message":"dropping enabled for the blue rectangle","id":"81D350CB-D926-491F-8FF3-A6C9C831BDF2","__serializedExpressions__":["date"],"date":"new Date(\"Wed Mar 12 2014 15:00:28 GMT+0100 (W. Europe Standard Time)\")"},"193":{"author":"robertkrahn","message":"no comment","id":"5AF36E70-7428-4762-9423-D7160E3DCBDC","__serializedExpressions__":["date"],"date":"new Date(\"Sun Nov 09 2014 00:34:45 GMT+0100 (W. Europe Standard Time)\")"},"194":{"author":"unknown_user","message":"no comment","id":"72C4516E-C189-478C-B979-EFA49E1C213E","__serializedExpressions__":["date"],"date":"new Date(\"Tue Jun 02 2015 21:29:52 GMT+0200 (W. Europe Daylight Time)\")"},"195":{"__serializedExpressions__":["date"],"author":"unknown_user","message":"no comment","id":"1A609EFF-4E2D-445A-BE9D-C48FD3286BD3","date":"new Date(\"Tue Jun 02 2015 22:13:11 GMT+0200 (W. Europe Daylight Time)\")"},"196":{"morph":{"__isSmartRef__":true,"id":0},"__LivelyClassName__":"lively.morphic.EventHandler","__SourceModuleName__":"Global.lively.morphic.Events"},"197":{"__serializedLivelyClosures__":{"__isSmartRef__":true,"id":198}},"198":{"test01IsMorph":{"__isSmartRef__":true,"id":199}},"199":{"varMapping":{"__isSmartRef__":true,"id":200},"source":"function test01IsMorph(aPart) {\n    this.assert(aPart.isMorph, 'rectangle should be a morph');\n}","funcProperties":{"__isSmartRef__":true,"id":201},"__LivelyClassName__":"lively.Closure"},"200":{"this":{"__isSmartRef__":true,"id":197}},"201":{},"202":{"adjustForNewBounds":true},"203":{"print":{"__isSmartRef__":true,"id":204},"log":{"__isSmartRef__":true,"id":207},"evalAll":{"__isSmartRef__":true,"id":210}},"204":{"varMapping":{"__isSmartRef__":true,"id":205},"source":"function print(s) {\n    this.get(\"Log\").textString = s\n}","funcProperties":{"__isSmartRef__":true,"id":206},"__LivelyClassName__":"lively.Closure"},"205":{"this":{"__isSmartRef__":true,"id":0}},"206":{"user":"unknown_user","__serializedExpressions__":["timestamp"],"timestamp":"new Date(\"Tue Jun 02 2015 20:52:13 GMT+0200 (W. Europe Daylight Time)\")"},"207":{"varMapping":{"__isSmartRef__":true,"id":208},"source":"function log(s) {\n    this.get(\"Log\").textString += s + \"\\n\"\n}","funcProperties":{"__isSmartRef__":true,"id":209},"__LivelyClassName__":"lively.Closure"},"208":{"this":{"__isSmartRef__":true,"id":0}},"209":{"__serializedExpressions__":["timestamp"],"user":"unknown_user","timestamp":"new Date(\"Tue Jun 02 2015 21:51:02 GMT+0200 (W. Europe Daylight Time)\")"},"210":{"varMapping":{"__isSmartRef__":true,"id":211},"source":"function evalAll() {\n    this.print(\"\")\n    var w = this.get(\"workspace\");\n    this.log(w.tryBoundEval(w.textString))\n}","funcProperties":{"__isSmartRef__":true,"id":212},"__LivelyClassName__":"lively.Closure"},"211":{"this":{"__isSmartRef__":true,"id":0}},"212":{"__serializedExpressions__":["timestamp"],"user":"unknown_user","timestamp":"new Date(\"Tue Jun 02 2015 21:49:24 GMT+0200 (W. Europe Daylight Time)\")"},"isSimplifiedRegistry":true}}