Changeset 33
- Timestamp:
- 05/29/08 22:36:21 (6 months ago)
- Files:
Legend:
- Unmodified
- Added
- Removed
- Modified
- Copied
- Moved
trunk/lily/lily/chrome/content/externals/number.js
r31 r33 113 113 thisPtr.controller.patchController.attachPatchObserver(thisPtr.objID,"mousemove",mouseMoveFunc,"performance"); 114 114 thisPtr.controller.patchController.attachPatchObserver(thisPtr.objID,"mouseup",mouseUpFunc,"performance"); 115 thisPtr.controller.patchController.attachPatchObserver( "canvas","click",numberDeselected,"performance");115 thisPtr.controller.patchController.attachPatchObserver(thisPtr.objID,"mousedown",numberDeselected,"performance"); 116 116 numberSelected(); 117 117 } … … 124 124 125 125 function numberDeselected(e) { 126 if(e.target.id =="canvas"&& isSelected) {126 if(e.target.id.indexOf(thisPtr.objID)==-1 && isSelected) { 127 127 thisPtr.ui.contentContainer.style.borderLeft="4px double black"; 128 thisPtr.controller.patchController.removePatchObserver( "canvas","mouseup",numberDeselected,"performance");128 thisPtr.controller.patchController.removePatchObserver(thisPtr.objID,"mousedown",numberDeselected,"performance"); 129 129 thisPtr.controller.patchController.removePatchObserver(thisPtr.objID,"keypress",keyPressFunc,"performance"); 130 130 if(typein_buffer) updateValue(+typein_buffer); … … 173 173 function toggleEditabilityFunc() { 174 174 if(isSelected) { 175 numberDeselected({target:{id:" canvas"}});175 numberDeselected({target:{id:"edit_state_change"}}); 176 176 } else { 177 177 updateValue(+(intDisplay.innerHTML+floatDisplay.innerHTML));
