{"id":0,"registry":{"0":{"submorphs":[{"__isSmartRef__":true,"id":1},{"__isSmartRef__":true,"id":14}],"scripts":[],"id":"8C761626-A2D0-48A8-8F0E-E32422D7E141","shape":{"__isSmartRef__":true,"id":17},"__layered_droppingEnabled__":true,"halosEnabled":true,"registeredForMouseEvents":true,"showsHalos":false,"name":"TimeSlider","partsBinMetaInfo":{"__isSmartRef__":true,"id":18},"eventHandler":{"__isSmartRef__":true,"id":42},"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","1C17567C-751A-447E-A93C-0CE8CAEEF262","C31986AF-AB07-427F-BD76-E0F3859AC975","37DA4D8C-871B-45C4-BC5F-E40AED62221E"],"partTests":{"__isSmartRef__":true,"id":43},"_ClipMode":"visible","moved":true,"droppingEnabled":true,"mss":4,"state":{"__isSmartRef__":true,"id":48},"isBeingDragged":false,"connections":{"__isSmartRef__":true,"id":49},"layout":{"__isSmartRef__":true,"id":52},"_Rotation":0,"_Scale":1,"__serializedExpressions__":["_Position","distanceToDragEvent","hitPoint"],"__serializedLivelyClosures__":{"__isSmartRef__":true,"id":53},"__LivelyClassName__":"lively.morphic.Box","__SourceModuleName__":"Global.lively.morphic.Core","_Position":"lively.pt(0.0,0.0)","distanceToDragEvent":"lively.pt(230.0,-29.0)","hitPoint":"lively.pt(762.0,8.0)"},"1":{"submorphs":[],"scripts":[],"id":"5ED32CA2-9420-477E-BFC9-3BCF2E70E5B3","shape":{"__isSmartRef__":true,"id":2},"droppingEnabled":true,"halosEnabled":true,"draggingEnabled":true,"slider":{"__isSmartRef__":true,"id":3},"styleClass":["slider_horizontal"],"eventHandler":{"__isSmartRef__":true,"id":13},"derivationIds":[2632,"A8917D7B-B083-4C54-AFA0-5443B4DEF9E4","78BC880A-08AD-4548-85B1-D400C7CB0747","CBF4660B-0123-4296-8D46-B699FF591986"],"_ClipMode":"visible","isBeingDragged":false,"showsHalos":false,"name":"leftSliderKnob","owner":{"__isSmartRef__":true,"id":0},"_Rotation":0,"_Scale":1,"__serializedExpressions__":["_Position","hitPoint","distanceToDragEvent"],"popup":null,"__LivelyClassName__":"lively.morphic.SliderKnob","__SourceModuleName__":"Global.lively.morphic.Widgets","_Position":"lively.pt(71.3,-6.0)","hitPoint":"lively.pt(73.0,20.0)","distanceToDragEvent":"lively.pt(40.0,-15.0)"},"2":{"_BorderWidth":1,"_BorderRadius":6,"__serializedExpressions__":["_Fill","position","_Extent","_BorderColor","_Padding"],"__LivelyClassName__":"lively.morphic.Shapes.Rectangle","__SourceModuleName__":"Global.lively.morphic.Shapes","_Fill":"lively.morphic.Gradient.create({\n  stops: [{\n    color: Color.rgb(196,211,221),\n    offset: 0\n  },{\n    color: Color.rgb(137,167,187),\n    offset: 0.5\n  },{\n    color: Color.rgb(96,130,153),\n    offset: 1\n  }],\n  type: \"linear\",\n  vector: lively.rect(0,0,0,1)\n})","position":"lively.pt(0.0,0.0)","_Extent":"lively.pt(28.5,44.0)","_BorderColor":"Color.rgb(102,102,102)","_Padding":"lively.rect(0,0,0,0)"},"3":{"submorphs":[{"__isSmartRef__":true,"id":4}],"scripts":[],"id":"C0652BA2-0B89-4964-B7ED-5F3415A7851B","shape":{"__isSmartRef__":true,"id":7},"droppingEnabled":true,"halosEnabled":true,"attributeConnections":[{"__isSmartRef__":true,"id":8}],"doNotSerialize":["$$value"],"doNotCopyProperties":["$$value"],"value":0.2977,"sliderExtent":0.1,"valueScale":1,"sliderKnob":{"__isSmartRef__":true,"id":4},"styleClass":["slider_background_horizontal"],"showsHalos":false,"name":"Slider","partsBinMetaInfo":{"__isSmartRef__":true,"id":9},"eventHandler":{"__isSmartRef__":true,"id":11},"layout":{"__isSmartRef__":true,"id":12},"derivationIds":[2631,"E6C0AF56-6D3E-41C8-AE8E-A0520F495C6B"],"_ClipMode":"visible","moved":true,"isBeingDragged":false,"_Rotation":0,"_Scale":1,"isCopyMorphRef":true,"morphRefId":1,"__serializedExpressions__":["_Position"],"__LivelyClassName__":"lively.morphic.Slider","__SourceModuleName__":"Global.lively.morphic.Widgets","_Position":"lively.pt(709.0,90.0)"},"4":{"submorphs":[],"scripts":[],"id":"78BC880A-08AD-4548-85B1-D400C7CB0747","shape":{"__isSmartRef__":true,"id":5},"droppingEnabled":true,"halosEnabled":true,"draggingEnabled":true,"slider":{"__isSmartRef__":true,"id":3},"owner":{"__isSmartRef__":true,"id":3},"styleClass":["slider_horizontal"],"eventHandler":{"__isSmartRef__":true,"id":6},"derivationIds":[2632,"A8917D7B-B083-4C54-AFA0-5443B4DEF9E4"],"_ClipMode":"visible","isBeingDragged":false,"showsHalos":false,"__serializedExpressions__":["_Position","hitPoint"],"__LivelyClassName__":"lively.morphic.SliderKnob","__SourceModuleName__":"Global.lively.morphic.Widgets","_Position":"lively.pt(41.5,0.0)","hitPoint":"lively.pt(196.0,602.0)"},"5":{"_BorderWidth":1,"_BorderRadius":6,"__serializedExpressions__":["_Fill","position","_Extent","_BorderColor","_Padding"],"__LivelyClassName__":"lively.morphic.Shapes.Rectangle","__SourceModuleName__":"Global.lively.morphic.Shapes","_Fill":"lively.morphic.Gradient.create({\n  stops: [{\n    color: Color.rgb(196,211,221),\n    offset: 0\n  },{\n    color: Color.rgb(137,167,187),\n    offset: 0.5\n  },{\n    color: Color.rgb(96,130,153),\n    offset: 1\n  }],\n  type: \"linear\",\n  vector: lively.rect(0,0,0,1)\n})","position":"lively.pt(0.0,0.0)","_Extent":"lively.pt(15.5,26.0)","_BorderColor":"Color.rgb(102,102,102)","_Padding":"lively.rect(0,0,0,0)"},"6":{"morph":{"__isSmartRef__":true,"id":4},"__LivelyClassName__":"lively.morphic.EventHandler","__SourceModuleName__":"Global.lively.morphic.Events"},"7":{"_BorderWidth":1,"_BorderRadius":6,"_Opacity":1,"_BorderStyle":"solid","__serializedExpressions__":["_Fill","position","_Extent","_BorderColor","_Padding"],"__LivelyClassName__":"lively.morphic.Shapes.Rectangle","__SourceModuleName__":"Global.lively.morphic.Shapes","_Fill":"lively.morphic.Gradient.create({\n  stops: [{\n    color: Color.rgb(204,204,204),\n    offset: 0\n  },{\n    color: Color.rgb(240,240,240),\n    offset: 0.4\n  },{\n    color: Color.rgb(245,245,245),\n    offset: 1\n  }],\n  type: \"linear\",\n  vector: lively.rect(0,0,0,1)\n})","position":"lively.pt(0.0,0.0)","_Extent":"lively.pt(155.0,26.0)","_BorderColor":"Color.rgb(192,192,192)","_Padding":"lively.rect(0,0,0,0)"},"8":{"sourceObj":{"__isSmartRef__":true,"id":3},"sourceAttrName":"value","targetObj":{"__isSmartRef__":true,"id":3},"targetMethodName":"adjustSliderParts","__LivelyClassName__":"AttributeConnection","__SourceModuleName__":"Global.lively.bindings.Core"},"9":{"requiredModules":[],"partsSpaceName":"PartsBin/Inputs","migrationLevel":4,"partName":"Slider","comment":"The connection point \"value\" can be used to read/write the slider knob position.","changes":[{"__isSmartRef__":true,"id":10}],"__serializedExpressions__":["lastModifiedDate"],"__LivelyClassName__":"lively.PartsBin.PartsBinMetaInfo","__SourceModuleName__":"Global.lively.PartsBin","lastModifiedDate":"new Date(\"Wed Feb 06 2013 21:45:01 GMT-0800 (PST)\")"},"10":{"author":"dustin.glaeser","message":"no comment","id":"9CD9677C-9A79-4D71-85C1-E5C72C253D16","__serializedExpressions__":["date"],"date":"new Date(\"Thu Dec 13 2012 02:34:16 GMT-0800 (PST)\")"},"11":{"morph":{"__isSmartRef__":true,"id":3},"__LivelyClassName__":"lively.morphic.EventHandler","__SourceModuleName__":"Global.lively.morphic.Events"},"12":{},"13":{"morph":{"__isSmartRef__":true,"id":1},"__LivelyClassName__":"lively.morphic.EventHandler","__SourceModuleName__":"Global.lively.morphic.Events"},"14":{"submorphs":[],"scripts":[],"id":"8C8AD166-EA58-4EF5-B76A-CA7A48D8D035","shape":{"__isSmartRef__":true,"id":15},"droppingEnabled":true,"halosEnabled":true,"draggingEnabled":true,"slider":{"__isSmartRef__":true,"id":3},"styleClass":["slider_horizontal"],"eventHandler":{"__isSmartRef__":true,"id":16},"derivationIds":[2632,"A8917D7B-B083-4C54-AFA0-5443B4DEF9E4","78BC880A-08AD-4548-85B1-D400C7CB0747","CBF4660B-0123-4296-8D46-B699FF591986","B8043BB2-C465-4079-9995-38BD2FB3269A"],"_ClipMode":"visible","isBeingDragged":false,"showsHalos":false,"name":"rightSliderKnob","owner":{"__isSmartRef__":true,"id":0},"_Rotation":0,"_Scale":1,"__serializedExpressions__":["_Position","hitPoint","distanceToDragEvent"],"popup":null,"__LivelyClassName__":"lively.morphic.SliderKnob","__SourceModuleName__":"Global.lively.morphic.Widgets","_Position":"lively.pt(216.1,-6.0)","hitPoint":"lively.pt(237.0,20.0)","distanceToDragEvent":"lively.pt(40.0,-15.0)"},"15":{"_BorderWidth":1,"_BorderRadius":6,"__serializedExpressions__":["_Fill","position","_Extent","_BorderColor","_Padding"],"__LivelyClassName__":"lively.morphic.Shapes.Rectangle","__SourceModuleName__":"Global.lively.morphic.Shapes","_Fill":"lively.morphic.Gradient.create({\n  stops: [{\n    color: Color.rgb(196,211,221),\n    offset: 0\n  },{\n    color: Color.rgb(137,167,187),\n    offset: 0.5\n  },{\n    color: Color.rgb(96,130,153),\n    offset: 1\n  }],\n  type: \"linear\",\n  vector: lively.rect(0,0,0,1)\n})","position":"lively.pt(0.0,0.0)","_Extent":"lively.pt(28.5,44.0)","_BorderColor":"Color.rgb(102,102,102)","_Padding":"lively.rect(0,0,0,0)"},"16":{"morph":{"__isSmartRef__":true,"id":14},"__LivelyClassName__":"lively.morphic.EventHandler","__SourceModuleName__":"Global.lively.morphic.Events"},"17":{"_BorderWidth":1,"_ClipMode":"visible","_BorderRadius":6,"_Opacity":1,"_BorderStyle":"solid","_StrokeOpacity":1,"__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(285.0,38.0)","_BorderColor":"Color.rgb(192,192,192)","_Fill":"lively.morphic.Gradient.create({\n  stops: [{\n    color: Color.rgb(204,204,204),\n    offset: 0\n  },{\n    color: Color.rgb(240,240,240),\n    offset: 0.4\n  },{\n    color: Color.rgb(245,245,245),\n    offset: 1\n  }],\n  type: \"linear\",\n  vector: lively.rect(0,0,0,1)\n})","_Padding":"lively.rect(0,0,0,0)"},"18":{"partsSpaceName":"PartsBin/Widgets","comment":"A slider with two knobs that allows you to select a time / date range.\n\nSee the reset method for config options.\n\nYou can connect to slider.startDate and slider.endDate","migrationLevel":8,"partName":"TimeSlider","changes":[{"__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},{"__isSmartRef__":true,"id":29},{"__isSmartRef__":true,"id":30},{"__isSmartRef__":true,"id":31},{"__isSmartRef__":true,"id":32},{"__isSmartRef__":true,"id":33},{"__isSmartRef__":true,"id":34},{"__isSmartRef__":true,"id":35},{"__isSmartRef__":true,"id":36},{"__isSmartRef__":true,"id":37},{"__isSmartRef__":true,"id":38},{"__isSmartRef__":true,"id":39},{"__isSmartRef__":true,"id":40},{"__isSmartRef__":true,"id":41}],"__serializedExpressions__":["lastModifiedDate"],"__LivelyClassName__":"lively.PartsBin.PartsBinMetaInfo","__SourceModuleName__":"Global.lively.PartsBin","lastModifiedDate":"new Date(\"Thu Sep 11 2014 16:19:05 GMT-0700 (PDT)\")"},"19":{"author":"jenslincke","message":"no comment","id":"ADFBF069-513C-4DE6-95A9-8AD4985C6508","__serializedExpressions__":["date"],"date":"new Date(\"Tue Feb 04 2014 01:23:53 GMT-0800 (PST)\")"},"20":{"author":"robertkrahn","message":"no comment","id":"A452871F-4EB9-45D1-94B8-6065CBA7B8FD","__serializedExpressions__":["date"],"date":"new Date(\"Mon Jul 29 2013 23:20:51 GMT-0700 (PDT)\")"},"21":{"author":"SAPLivelyScreen","message":"no comment","id":"7A44D8CA-6D5F-42A3-A4B4-4D7F51EECA52","__serializedExpressions__":["date"],"date":"new Date(\"Tue Jun 18 2013 11:49:27 GMT-0700 (PDT)\")"},"22":{"author":"SAPLivelyScreen","message":"no comment","id":"EF145198-0649-41BD-A92E-521D98FEC49D","__serializedExpressions__":["date"],"date":"new Date(\"Wed May 29 2013 15:36:50 GMT-0700 (PDT)\")"},"23":{"author":"jenslincke","message":"added legend","id":"7ADA3049-56C1-4D32-874B-F664A79DDB20","__serializedExpressions__":["date"],"date":"new Date(\"Fri Jan 18 2013 07:47:05 GMT-0800 (PST)\")"},"24":{"author":"jenslincke","message":"no comment","id":"A4B86A7E-A398-4C29-BEE0-4AA045ABABD2","__serializedExpressions__":["date"],"date":"new Date(\"Fri Jan 18 2013 07:42:31 GMT-0800 (PST)\")"},"25":{"author":"jenslincke","message":"I want my blue rectangle back!","id":"5AA9291A-869F-4D36-8095-4721B5A5B205","__serializedExpressions__":["date"],"date":"new Date(\"Thu Nov 22 2012 01:35:51 GMT-0800 (PST)\")"},"26":{"author":"bgnauk","message":"no comment","id":"0124E570-50B7-4CE3-83A1-6E7BA89B5CD8","__serializedExpressions__":["date"],"date":"new Date(\"Mon Jun 18 2012 10:35:08 GMT-0700 (PDT)\")"},"27":{"author":"undefined","message":"suddenly, the rectangle became a CarDemo","id":"B5083AA8-9BAE-48DD-A6B4-FD7DB3998350","__serializedExpressions__":["date"],"date":"new Date(\"Mon Apr 09 2012 04:42:07 GMT-0700 (PDT)\")"},"28":{"author":"undefined","message":"css transitions","id":"1004E0FC-D96B-4F40-B3E0-F514A3FCFFD7","__serializedExpressions__":["date"],"date":"new Date(\"Wed Mar 14 2012 02:42:26 GMT-0700 (PDT)\")"},"29":{"author":"fbo","message":"","id":"BD1C654D-9100-4B66-BC62-B15FF2498B2B","__serializedExpressions__":["date"],"date":"new Date(\"Fri Feb 24 2012 17:59:09 GMT-0800 (PST)\")"},"30":{"author":"undefined","message":"sorry","id":"44B56D2E-9B59-4C67-A305-49A6E10E66C2","__serializedExpressions__":["date"],"date":"new Date(\"Wed Mar 14 2012 02:53:45 GMT-0700 (PDT)\")"},"31":{"author":"undefined","message":"whoopsie","id":"CEA5DCD5-2DB7-40AD-A776-262A7A0666FC","__serializedExpressions__":["date"],"date":"new Date(\"Thu May 03 2012 06:51:30 GMT-0700 (PDT)\")"},"32":{"author":"undefined","message":"whoopsie","id":"3F17A2D2-3C24-424B-B0FA-E43112267D23","__serializedExpressions__":["date"],"date":"new Date(\"Thu May 03 2012 06:51:36 GMT-0700 (PDT)\")"},"33":{"author":"jenslincke","message":"no comment","id":"AEB2F41B-2C88-4BBA-8875-93CD17CBA1C8","__serializedExpressions__":["date"],"date":"new Date(\"Wed Jan 23 2013 03:57:18 GMT-0800 (PST)\")"},"34":{"author":"robertkrahn","message":"no comment","id":"67FD74CD-7AE4-4050-ADC7-4DF73804258D","__serializedExpressions__":["date"],"date":"new Date(\"Thu May 30 2013 00:18:06 GMT-0700 (PDT)\")"},"35":{"author":"robertkrahn","message":"no comment","id":"FBBB9C99-B61C-4D5F-8750-6E2987DF0C9C","__serializedExpressions__":["date"],"date":"new Date(\"Thu Jun 20 2013 15:16:24 GMT-0700 (PDT)\")"},"36":{"author":"jenslincke","message":"no comment","id":"ECD12BFF-E872-4918-8341-C6571E72F36D","__serializedExpressions__":["date"],"date":"new Date(\"Tue Feb 04 2014 01:24:27 GMT-0800 (PST)\")"},"37":{"author":"lauritz","message":"dropping enabled for the blue rectangle","id":"81D350CB-D926-491F-8FF3-A6C9C831BDF2","__serializedExpressions__":["date"],"date":"new Date(\"Wed Mar 12 2014 07:00:28 GMT-0700 (PDT)\")"},"38":{"author":"robertkrahn","message":"initial","id":"8B0565E8-58CC-46B6-9279-6CC76596F30C","__serializedExpressions__":["date"],"date":"new Date(\"Thu Sep 11 2014 13:53:03 GMT-0700 (PDT)\")"},"39":{"author":"robertkrahn","message":"removed text connection","id":"71A5D4CD-AD32-4C12-BAD0-1C6638238D61","__serializedExpressions__":["date"],"date":"new Date(\"Thu Sep 11 2014 13:54:28 GMT-0700 (PDT)\")"},"40":{"author":"robertkrahn","message":"no comment","id":"F57927B4-6852-4DEF-993F-C98ADD8B263D","__serializedExpressions__":["date"],"date":"new Date(\"Thu Sep 11 2014 16:19:00 GMT-0700 (PDT)\")"},"41":{"__serializedExpressions__":["date"],"author":"robertkrahn","message":"time gridding","id":"8BEF6CCE-98F8-47C9-A974-623791723450","date":"new Date(\"Thu Sep 11 2014 22:51:05 GMT-0700 (PDT)\")"},"42":{"morph":{"__isSmartRef__":true,"id":0},"__LivelyClassName__":"lively.morphic.EventHandler","__SourceModuleName__":"Global.lively.morphic.Events"},"43":{"__serializedLivelyClosures__":{"__isSmartRef__":true,"id":44}},"44":{"test01IsMorph":{"__isSmartRef__":true,"id":45}},"45":{"varMapping":{"__isSmartRef__":true,"id":46},"source":"function test01IsMorph(aPart) {\n    this.assert(aPart.isMorph, 'rectangle should be a morph');\n}","funcProperties":{"__isSmartRef__":true,"id":47},"__LivelyClassName__":"lively.Closure","__SourceModuleName__":"Global.lively.lang.Closure"},"46":{"this":{"__isSmartRef__":true,"id":43}},"47":{},"48":{"__serializedExpressions__":["minDate","maxDate","startDate","endDate"],"relativeKnobSize":0.1,"sliderStickoutTop":6,"sliderStickoutBottom":0,"dateFormat":"HH:MM:ss yyyy-mm-dd","grid":3600000,"minDate":"new Date(\"Mon Sep 01 2014 06:00:00 GMT-0700 (PDT)\")","maxDate":"new Date(\"Fri Sep 05 2014 18:00:00 GMT-0700 (PDT)\")","startDate":"new Date(\"Tue Sep 02 2014 12:00:00 GMT-0700 (PDT)\")","endDate":"new Date(\"Fri Sep 05 2014 01:00:00 GMT-0700 (PDT)\")"},"49":{"startDate":{"__isSmartRef__":true,"id":50},"endDate":{"__isSmartRef__":true,"id":51}},"50":{},"51":{},"52":{"resizeWidth":true,"moveVertical":true},"53":{"reset":{"__isSmartRef__":true,"id":54},"getSliderExtent":{"__isSmartRef__":true,"id":57},"clipValue":{"__isSmartRef__":true,"id":60},"vertical":{"__isSmartRef__":true,"id":63},"setScaledValue":{"__isSmartRef__":true,"id":66},"getScaledValue":{"__isSmartRef__":true,"id":69},"getState":{"__isSmartRef__":true,"id":72},"fromTimeToPos":{"__isSmartRef__":true,"id":75},"fromPosToTime":{"__isSmartRef__":true,"id":78},"adjustKnob":{"__isSmartRef__":true,"id":81},"adjustKnobs":{"__isSmartRef__":true,"id":84},"setExtent":{"__isSmartRef__":true,"id":87},"getStartDate":{"__isSmartRef__":true,"id":94},"getEndDate":{"__isSmartRef__":true,"id":97},"test":{"__isSmartRef__":true,"id":100},"setMinDate":{"__isSmartRef__":true,"id":103},"setMaxDate":{"__isSmartRef__":true,"id":106},"setStartDate":{"__isSmartRef__":true,"id":109},"setEndDate":{"__isSmartRef__":true,"id":112},"knobPopup":{"__isSmartRef__":true,"id":115},"onDrag":{"__isSmartRef__":true,"id":118},"onDragStart":{"__isSmartRef__":true,"id":125}},"54":{"varMapping":{"__isSmartRef__":true,"id":55},"source":"function reset() {\n    this.mss = 4; // \"minimum slider size\"\n    var date1 = new Date(\"Wed Sep 01 2014 06:00:00 GMT-0700 (PDT)\");\n    var date2 = new Date(\"Wed Sep 05 2014 18:00:00 GMT-0700 (PDT)\");\n    this.state = {\n        minDate: date1, maxDate: date2,\n        startDate: date1, endDate: date2,\n        // relativeKnobSize: .02,\n        relativeKnobSize: .1,\n        sliderStickoutTop: 6,\n        sliderStickoutBottom: 0,\n        dateFormat: \"HH:MM:ss yyyy-mm-dd\",\n        grid: 1000*60*60\n    }\n    this.connections = {\n        startDate: {},\n        endDate: {}\n    }\n    delete this.get(\"leftSliderKnob\").popup;\n    delete this.get(\"rightSliderKnob\").popup;\n    this.adjustKnobs();\n}","funcProperties":{"__isSmartRef__":true,"id":56},"__LivelyClassName__":"lively.Closure","__SourceModuleName__":"Global.lively.lang.Closure"},"55":{"this":{"__isSmartRef__":true,"id":0}},"56":{"__serializedExpressions__":["timestamp"],"user":"robertkrahn","timestamp":"new Date(\"Thu Sep 11 2014 22:39:45 GMT-0700 (PDT)\")"},"57":{"varMapping":{"__isSmartRef__":true,"id":58},"source":"function getSliderExtent() { return this.state.relativeKnobSize; }","funcProperties":{"__isSmartRef__":true,"id":59},"__LivelyClassName__":"lively.Closure","__SourceModuleName__":"Global.lively.lang.Closure"},"58":{"this":{"__isSmartRef__":true,"id":0}},"59":{"user":"robertkrahn","__serializedExpressions__":["timestamp"],"timestamp":"new Date(\"Thu Sep 11 2014 12:54:41 GMT-0700 (PDT)\")"},"60":{"varMapping":{"__isSmartRef__":true,"id":61},"source":"function clipValue(val) {\n    return Math.min(1.0,Math.max(0,0,val.roundTo(0.0001)));\n}","funcProperties":{"__isSmartRef__":true,"id":62},"__LivelyClassName__":"lively.Closure","__SourceModuleName__":"Global.lively.lang.Closure"},"61":{"this":{"__isSmartRef__":true,"id":0}},"62":{"user":"robertkrahn","__serializedExpressions__":["timestamp"],"timestamp":"new Date(\"Thu Sep 11 2014 12:31:18 GMT-0700 (PDT)\")"},"63":{"varMapping":{"__isSmartRef__":true,"id":64},"source":"function vertical() {\n    var bnds = this.shape.bounds();\n    return bnds.height > bnds.width;\n}","funcProperties":{"__isSmartRef__":true,"id":65},"__LivelyClassName__":"lively.Closure","__SourceModuleName__":"Global.lively.lang.Closure"},"64":{"this":{"__isSmartRef__":true,"id":0}},"65":{"user":"robertkrahn","__serializedExpressions__":["timestamp"],"timestamp":"new Date(\"Thu Sep 11 2014 13:47:54 GMT-0700 (PDT)\")"},"66":{"varMapping":{"__isSmartRef__":true,"id":67},"source":"function setScaledValue(val, knob) {\n    var s = this.getState();\n    var pos = (s.maxPos - s.minPos) * val;\n    var timeAtKnobStart = this.fromPosToTime(\n        pos, s.minDate, s.maxDate, s.minPos, s.maxPos);\n    var timeAtKnobEnd = this.fromPosToTime(\n        pos+s.elevPix, s.minDate, s.maxDate, s.minPos, s.maxPos)\n\n    var newTime = timeAtKnobStart;\n\n    if (s.grid) {\n        s.startDate\n        newTime = new Date(s.grid * Math.round(newTime / s.grid));\n        // show(+newTime)\n        // newTime = new Date((+newTime).detent(s.grid, s.grid, true))\n    }\n\n    if (knob.name === \"leftSliderKnob\") {\n        if (timeAtKnobEnd > s.endDate) newTime = new Date(s.endDate - (timeAtKnobEnd - timeAtKnobStart));\n        this.state.startDate = newTime;\n        lively.bindings.signal(this, \"startDate\", newTime);\n    } else if (knob.name === \"rightSliderKnob\") {\n        var minEndTime = new Date(+s.startDate + (timeAtKnobEnd - timeAtKnobStart));\n        if (newTime < minEndTime) newTime = minEndTime;\n        this.state.endDate = newTime;\n        lively.bindings.signal(this, \"endDate\", newTime);\n    };\n    this.adjustKnobs();\n\n    this.knobPopup(knob, newTime.format(this.state.dateFormat), 3);\n\n    return newTime;\n}","funcProperties":{"__isSmartRef__":true,"id":68},"__LivelyClassName__":"lively.Closure","__SourceModuleName__":"Global.lively.lang.Closure"},"67":{"this":{"__isSmartRef__":true,"id":0}},"68":{"__serializedExpressions__":["timestamp"],"user":"robertkrahn","timestamp":"new Date(\"Thu Sep 11 2014 22:47:46 GMT-0700 (PDT)\")"},"69":{"varMapping":{"__isSmartRef__":true,"id":70},"source":"function getScaledValue(knob) {\n    if (this.get(\"leftSliderKnob\") === knob) return this.getState().startDate;\n    if (this.get(\"rightSliderKnob\") === knob) return this.getState().endDate;\n    return null;\n}","funcProperties":{"__isSmartRef__":true,"id":71},"__LivelyClassName__":"lively.Closure","__SourceModuleName__":"Global.lively.lang.Closure"},"70":{"this":{"__isSmartRef__":true,"id":0}},"71":{"__serializedExpressions__":["timestamp"],"user":"robertkrahn","timestamp":"new Date(\"Thu Sep 11 2014 22:47:28 GMT-0700 (PDT)\")"},"72":{"varMapping":{"__isSmartRef__":true,"id":73},"source":"function getState() {\n    var state = Object.extend({}, this.state);\n    var bnds = this.innerBounds(),\n        ext = this.getSliderExtent();\n\n    if (this.vertical()) { // more vertical...\n        // thickness of elevator in pixels\n        var elevPix = Math.max(ext*bnds.height, this.mss);\n        var maxPos = (bnds.height - elevPix);\n    } else { // more horizontal...\n        // thickness of elevator in pixels\n        var elevPix = Math.max(ext*bnds.width, this.mss),\n            maxPos = bnds.width - elevPix;\n    }\n\n    state.maxPos = maxPos;\n    state.minPos = 0;\n    state.elevPix = elevPix;\n\n    return state;\n}","funcProperties":{"__isSmartRef__":true,"id":74},"__LivelyClassName__":"lively.Closure","__SourceModuleName__":"Global.lively.lang.Closure"},"73":{"this":{"__isSmartRef__":true,"id":0}},"74":{"user":"robertkrahn","__serializedExpressions__":["timestamp"],"timestamp":"new Date(\"Thu Sep 11 2014 12:07:36 GMT-0700 (PDT)\")"},"75":{"varMapping":{"__isSmartRef__":true,"id":76},"source":"function fromTimeToPos(time, minTime, maxTime, minPos, maxPos) {\n    var domainPercent = (time - minTime) / (maxTime - minTime);\n    var delta = (maxPos - minPos) * domainPercent;\n    return minPos + delta;\n}","funcProperties":{"__isSmartRef__":true,"id":77},"__LivelyClassName__":"lively.Closure","__SourceModuleName__":"Global.lively.lang.Closure"},"76":{"this":{"__isSmartRef__":true,"id":0}},"77":{"user":"robertkrahn","__serializedExpressions__":["timestamp"],"timestamp":"new Date(\"Thu Sep 11 2014 11:55:40 GMT-0700 (PDT)\")"},"78":{"varMapping":{"__isSmartRef__":true,"id":79},"source":"function fromPosToTime(pos, minTime, maxTime, minPos, maxPos) {\n    var domainPercent = (pos - minPos) / (maxPos - minPos);\n    var delta = (maxTime - minTime) * domainPercent;\n    return new Date((+minTime) + delta);\n}","funcProperties":{"__isSmartRef__":true,"id":80},"__LivelyClassName__":"lively.Closure","__SourceModuleName__":"Global.lively.lang.Closure"},"79":{"this":{"__isSmartRef__":true,"id":0}},"80":{"user":"robertkrahn","__serializedExpressions__":["timestamp"],"timestamp":"new Date(\"Thu Sep 11 2014 11:56:15 GMT-0700 (PDT)\")"},"81":{"varMapping":{"__isSmartRef__":true,"id":82},"source":"function adjustKnob(knob, val) {\n    if (!knob) return;\n    var s = this.getState();\n    var pos = this.fromTimeToPos(val, s.minDate, s.maxDate, s.minPos, s.maxPos);\n    if (this.vertical()) { // more vertical.\n        var topLeft = pt(0, pos),\n            sliderExt = pt(this.innerBounds().width, s.elevPix);\n        topLeft = topLeft.addXY(-s.sliderStickout, 0);\n        sliderExt = sliderExt.addXY(2*s.sliderStickout, 0);\n    } else { // more horizontal...\n        var topLeft = pt(pos, 0),\n            sliderExt = pt(s.elevPix, this.innerBounds().height);\n        topLeft = topLeft.addXY(0, -s.sliderStickoutTop);\n        sliderExt = sliderExt.addXY(0, s.sliderStickoutTop + s.sliderStickoutBottom);\n    }\n\n    knob.setBounds(topLeft.extent(sliderExt));\n}","funcProperties":{"__isSmartRef__":true,"id":83},"__LivelyClassName__":"lively.Closure","__SourceModuleName__":"Global.lively.lang.Closure"},"82":{"this":{"__isSmartRef__":true,"id":0}},"83":{"user":"robertkrahn","__serializedExpressions__":["timestamp"],"timestamp":"new Date(\"Thu Sep 11 2014 13:50:14 GMT-0700 (PDT)\")"},"84":{"varMapping":{"__isSmartRef__":true,"id":85},"source":"function adjustKnobs() {\n    this.adjustKnob(this.get(\"leftSliderKnob\"), this.getState().startDate);\n    this.adjustKnob(this.get(\"rightSliderKnob\"), this.getState().endDate);\n}","funcProperties":{"__isSmartRef__":true,"id":86},"__LivelyClassName__":"lively.Closure","__SourceModuleName__":"Global.lively.lang.Closure"},"85":{"this":{"__isSmartRef__":true,"id":0}},"86":{"user":"robertkrahn","__serializedExpressions__":["timestamp"],"timestamp":"new Date(\"Thu Sep 11 2014 12:41:37 GMT-0700 (PDT)\")"},"87":{"varMapping":{"__isSmartRef__":true,"id":88},"source":"function setExtent(val) {\n    $super(val);\n    this.adjustKnobs();\n    return val;\n}","funcProperties":{"__isSmartRef__":true,"id":93},"__LivelyClassName__":"lively.Closure","__SourceModuleName__":"Global.lively.lang.Closure"},"88":{"this":{"__isSmartRef__":true,"id":0},"__serializedLivelyClosures__":{"__isSmartRef__":true,"id":89}},"89":{"$super":{"__isSmartRef__":true,"id":90}},"90":{"varMapping":{"__isSmartRef__":true,"id":91},"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 ($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":92},"__LivelyClassName__":"lively.Closure","__SourceModuleName__":"Global.lively.lang.Closure"},"91":{"obj":{"__isSmartRef__":true,"id":0},"name":"setExtent"},"92":{},"93":{"user":"robertkrahn","__serializedExpressions__":["timestamp"],"timestamp":"new Date(\"Thu Sep 11 2014 12:45:48 GMT-0700 (PDT)\")"},"94":{"varMapping":{"__isSmartRef__":true,"id":95},"source":"function getStartDate() {\n    return this.getState().startDate;\n}","funcProperties":{"__isSmartRef__":true,"id":96},"__LivelyClassName__":"lively.Closure","__SourceModuleName__":"Global.lively.lang.Closure"},"95":{"this":{"__isSmartRef__":true,"id":0}},"96":{"user":"robertkrahn","tags":[],"__serializedExpressions__":["timestamp"],"timestamp":"new Date(\"Thu Sep 11 2014 13:02:09 GMT-0700 (PDT)\")"},"97":{"varMapping":{"__isSmartRef__":true,"id":98},"source":"function getEndDate() {\n    return this.getState().endDate;\n}","funcProperties":{"__isSmartRef__":true,"id":99},"__LivelyClassName__":"lively.Closure","__SourceModuleName__":"Global.lively.lang.Closure"},"98":{"this":{"__isSmartRef__":true,"id":0}},"99":{"user":"robertkrahn","__serializedExpressions__":["timestamp"],"timestamp":"new Date(\"Thu Sep 11 2014 13:02:24 GMT-0700 (PDT)\")"},"100":{"varMapping":{"__isSmartRef__":true,"id":101},"source":"function test() {\n    var t = this.get(\"Text\");\n\n    t.addScript(function printDateRange(timeSlider) {\n        var s = timeSlider.getStartDate(),\n            e = timeSlider.getEndDate(),\n            format = timeSlider.getState().dateFormat;\n        this.textString = Strings.format(\n            \"%s\\n%s\", s.format(format), e.format(format));\n    });\n\n    lively.bindings.connect(this, 'startDate', t, 'printDateRange', {\n        converter: function(val) { return this.sourceObj; }});\n    lively.bindings.connect(this, 'endDate', t, 'printDateRange', {\n        converter: function(val) { return this.sourceObj; }});\n}","funcProperties":{"__isSmartRef__":true,"id":102},"__LivelyClassName__":"lively.Closure","__SourceModuleName__":"Global.lively.lang.Closure"},"101":{"this":{"__isSmartRef__":true,"id":0}},"102":{"user":"robertkrahn","__serializedExpressions__":["timestamp"],"timestamp":"new Date(\"Thu Sep 11 2014 13:46:04 GMT-0700 (PDT)\")"},"103":{"varMapping":{"__isSmartRef__":true,"id":104},"source":"function setMinDate(date) {\n    this.state.minDate = date;\n    this.adjustKnobs();\n}","funcProperties":{"__isSmartRef__":true,"id":105},"__LivelyClassName__":"lively.Closure","__SourceModuleName__":"Global.lively.lang.Closure"},"104":{"this":{"__isSmartRef__":true,"id":0}},"105":{"user":"robertkrahn","__serializedExpressions__":["timestamp"],"timestamp":"new Date(\"Thu Sep 11 2014 14:20:16 GMT-0700 (PDT)\")"},"106":{"varMapping":{"__isSmartRef__":true,"id":107},"source":"function setMaxDate(date) {\n    this.state.maxDate = date;\n    this.adjustKnobs();\n}","funcProperties":{"__isSmartRef__":true,"id":108},"__LivelyClassName__":"lively.Closure","__SourceModuleName__":"Global.lively.lang.Closure"},"107":{"this":{"__isSmartRef__":true,"id":0}},"108":{"user":"robertkrahn","__serializedExpressions__":["timestamp"],"timestamp":"new Date(\"Thu Sep 11 2014 14:20:10 GMT-0700 (PDT)\")"},"109":{"varMapping":{"__isSmartRef__":true,"id":110},"source":"function setStartDate(date) {\n    this.state.startDate = date;\n    this.adjustKnobs();\n}","funcProperties":{"__isSmartRef__":true,"id":111},"__LivelyClassName__":"lively.Closure","__SourceModuleName__":"Global.lively.lang.Closure"},"110":{"this":{"__isSmartRef__":true,"id":0}},"111":{"user":"robertkrahn","__serializedExpressions__":["timestamp"],"timestamp":"new Date(\"Thu Sep 11 2014 14:42:58 GMT-0700 (PDT)\")"},"112":{"varMapping":{"__isSmartRef__":true,"id":113},"source":"function setEndDate(date) {\n    this.state.endDate = date;\n    this.adjustKnobs();\n}","funcProperties":{"__isSmartRef__":true,"id":114},"__LivelyClassName__":"lively.Closure","__SourceModuleName__":"Global.lively.lang.Closure"},"113":{"this":{"__isSmartRef__":true,"id":0}},"114":{"user":"robertkrahn","__serializedExpressions__":["timestamp"],"timestamp":"new Date(\"Thu Sep 11 2014 14:43:12 GMT-0700 (PDT)\")"},"115":{"varMapping":{"__isSmartRef__":true,"id":116},"source":"function knobPopup(knob, string, delay) {\n    if (knob.popup) {\n        var popup = knob.popup;\n        popup.textString = string;\n        popup.align(popup.bounds().topCenter(), knob.bounds().bottomCenter())\n        return;\n    }\n\n    delay = delay || 5;\n    var popup = lively.morphic.Text.makeLabel(\n        string,\n        {})\n    knob.popup = this.addMorph(popup);\n    popup.setVisible(false);\n    popup.fitThenDo(function() {\n        popup.setVisible(true);\n        popup.align(popup.bounds().topLeft(), knob.bounds().bottomLeft())\n    });\n    (function() {\n        popup.remove();\n        knob.popup = null;\n    }).delay(delay);\n}","funcProperties":{"__isSmartRef__":true,"id":117},"__LivelyClassName__":"lively.Closure","__SourceModuleName__":"Global.lively.lang.Closure"},"116":{"this":{"__isSmartRef__":true,"id":0}},"117":{"user":"robertkrahn","__serializedExpressions__":["timestamp"],"timestamp":"new Date(\"Thu Sep 11 2014 14:56:08 GMT-0700 (PDT)\")"},"118":{"varMapping":{"__isSmartRef__":true,"id":119},"source":"function onDrag(evt) {\n    this.get(\"leftSliderKnob\").onDrag(evt);\n    this.get(\"rightSliderKnob\").onDrag(evt);\n    evt.stop(); return true;\n}","funcProperties":{"__isSmartRef__":true,"id":124},"__LivelyClassName__":"lively.Closure","__SourceModuleName__":"Global.lively.lang.Closure"},"119":{"this":{"__isSmartRef__":true,"id":0},"__serializedLivelyClosures__":{"__isSmartRef__":true,"id":120}},"120":{"$super":{"__isSmartRef__":true,"id":121}},"121":{"varMapping":{"__isSmartRef__":true,"id":122},"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 ($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":123},"__LivelyClassName__":"lively.Closure","__SourceModuleName__":"Global.lively.lang.Closure"},"122":{"obj":{"__isSmartRef__":true,"id":0},"name":"onDrag"},"123":{},"124":{"user":"robertkrahn","__serializedExpressions__":["timestamp"],"timestamp":"new Date(\"Thu Sep 11 2014 16:14:53 GMT-0700 (PDT)\")"},"125":{"varMapping":{"__isSmartRef__":true,"id":126},"source":"function onDragStart(evt) {\n    var hitPoint = evt.getPositionIn(this);\n    this.get(\"leftSliderKnob\").hitPoint = hitPoint;\n    this.get(\"rightSliderKnob\").hitPoint = hitPoint;\n    evt.stop(); return true;\n}","funcProperties":{"__isSmartRef__":true,"id":131},"__LivelyClassName__":"lively.Closure","__SourceModuleName__":"Global.lively.lang.Closure"},"126":{"this":{"__isSmartRef__":true,"id":0},"__serializedLivelyClosures__":{"__isSmartRef__":true,"id":127}},"127":{"$super":{"__isSmartRef__":true,"id":128}},"128":{"varMapping":{"__isSmartRef__":true,"id":129},"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 ($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":130},"__LivelyClassName__":"lively.Closure","__SourceModuleName__":"Global.lively.lang.Closure"},"129":{"obj":{"__isSmartRef__":true,"id":0},"name":"onDragStart"},"130":{},"131":{"user":"robertkrahn","__serializedExpressions__":["timestamp"],"timestamp":"new Date(\"Thu Sep 11 2014 16:15:34 GMT-0700 (PDT)\")"},"isSimplifiedRegistry":true}}