Changeset View
Changeset View
Standalone View
Standalone View
webroot/rsrc/js/application/diff/DiffInline.js
| Show First 20 Lines • Show All 696 Lines • ▼ Show 20 Lines | _onupdate: function(response) { | ||||
| // TODO: Save the old row so the action it's undo-able if it was a | // TODO: Save the old row so the action it's undo-able if it was a | ||||
| // delete. | // delete. | ||||
| var remove_old = true; | var remove_old = true; | ||||
| if (remove_old) { | if (remove_old) { | ||||
| JX.DOM.remove(this._row); | JX.DOM.remove(this._row); | ||||
| } | } | ||||
| // If you delete the content on a comment and save it, it acts like a | |||||
| // delete: the server does not return a new row. | |||||
| if (new_row) { | |||||
| this.bindToRow(new_row); | this.bindToRow(new_row); | ||||
| } else { | |||||
| this.setDeleted(true); | |||||
| this._row = null; | |||||
| } | |||||
| this._didUpdate(); | this._didUpdate(); | ||||
| }, | }, | ||||
| _didUpdate: function(local_only) { | _didUpdate: function(local_only) { | ||||
| // After making changes to inline comments, refresh the transaction | // After making changes to inline comments, refresh the transaction | ||||
| // preview at the bottom of the page. | // preview at the bottom of the page. | ||||
| if (!local_only) { | if (!local_only) { | ||||
| Show All 38 Lines | |||||