diff --git a/src/app/edit-session.coffee b/src/app/edit-session.coffee index 3875e5c29..725c22652 100644 --- a/src/app/edit-session.coffee +++ b/src/app/edit-session.coffee @@ -41,6 +41,13 @@ class EditSession scrollLeft: @getScrollLeft() cursorScreenPosition: @getCursorScreenPosition().serialize() + isEqual: (other) -> + return false unless other instanceof EditSession + @buffer == other.buffer and + @scrollTop == other.getScrollTop() and + @scrollLeft == other.getScrollLeft() and + @getCursorScreenPosition().isEqual(other.getCursorScreenPosition()) + getRenderer: -> @renderer setScrollTop: (@scrollTop) -> @@ -153,11 +160,4 @@ class EditSession else positions.push(position) - isEqual: (other) -> - return false unless other instanceof EditSession - @buffer == other.buffer and - @scrollTop == other.getScrollTop() and - @scrollLeft == other.getScrollLeft() and - @getCursorScreenPosition().isEqual(other.getCursorScreenPosition()) - _.extend(EditSession.prototype, EventEmitter)