Changeset View
Changeset View
Standalone View
Standalone View
webroot/rsrc/js/application/diff/DiffInline.js
Show First 20 Lines • Show All 641 Lines • ▼ Show 20 Lines | cancel: function() { | ||||
JX.DOM.remove(this._editRow); | JX.DOM.remove(this._editRow); | ||||
this._editRow = null; | this._editRow = null; | ||||
if (text && text.length && (text != this._originalText)) { | if (text && text.length && (text != this._originalText)) { | ||||
this._drawUneditRows(text); | this._drawUneditRows(text); | ||||
} | } | ||||
this.setEditing(false); | this.setEditing(false); | ||||
this.setInvisible(false); | this.setInvisible(false); | ||||
var uri = this._getInlineURI(); | |||||
var data = this._newRequestData('cancel'); | |||||
var handler = JX.bind(this, this._onCancelResponse); | |||||
this.setLoading(true); | |||||
new JX.Request(uri, handler) | |||||
.setData(data) | |||||
.send(); | |||||
this._didUpdate(true); | this._didUpdate(true); | ||||
}, | }, | ||||
_onCancelResponse: function(response) { | |||||
this.setLoading(false); | |||||
}, | |||||
_readText: function(row) { | _readText: function(row) { | ||||
var textarea; | var textarea; | ||||
try { | try { | ||||
textarea = JX.DOM.find( | textarea = JX.DOM.find( | ||||
row, | row, | ||||
'textarea', | 'textarea', | ||||
'differential-inline-comment-edit-textarea'); | 'differential-inline-comment-edit-textarea'); | ||||
} catch (ex) { | } catch (ex) { | ||||
▲ Show 20 Lines • Show All 79 Lines • Show Last 20 Lines |