- Timestamp:
- 03/11/14 01:00:40 (11 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
Dev/trunk/src/client/qed-client/model/widgets/QuestionEditorPreviewItem.js
r500 r503 33 33 lang.hitch(this, 'onToggleFold'))); 34 34 this.own(this.removeButton.on('click', 35 lang.hitch(this, ' onDestroy')));35 lang.hitch(this, '_handleDestroy'))); 36 36 this.own(this.editButton.on('click', 37 37 lang.hitch(this, 'onToggleEdit'))); 38 38 this.showEdit(); 39 39 }, 40 onDestroy: function() {}, 40 _handleDestroy: function(evt) { 41 if ( !( this.disabled || this.readOnly ) ) { 42 this.emit('destroy'); 43 } 44 if ( evt ) { event.stop(evt); } 45 return false; 46 }, 41 47 _getValueAttr: function(value) { 42 48 if ( this._editing ) { … … 102 108 this.innerWidget = newWidget; 103 109 this.addChild(this.innerWidget); 110 this.innerWidget.set('readOnly',this.readOnly); 111 this.innerWidget.set('disabled',this.disabled); 104 112 this.titleNode.innerHTML = this.value.type+" [editing]"; 105 113 domClass.replace(this.editButton.iconNode, "rftIconAccept", "rftIconEdit");
Note: See TracChangeset
for help on using the changeset viewer.