Move the cursor on single click

This commit is contained in:
Nathan Sobo
2014-04-06 13:34:50 -06:00
parent b0ad5e2f69
commit 3a433f734c
4 changed files with 49 additions and 4 deletions

View File

@@ -153,7 +153,8 @@ class Editor extends Model
@delegatesMethods 'setLineHeight', 'getLineHeight', 'setDefaultCharWidth', 'setHeight',
'getHeight', 'setWidth', 'getWidth', 'setScrollTop', 'getScrollTop', 'getScrollBottom',
'setScrollBottom', 'setScrollLeft', 'getScrollLeft', 'getScrollHeight', 'getVisibleRowRange',
'intersectsVisibleRowRange', 'selectionIntersectsVisibleRowRange', toProperty: 'displayBuffer'
'intersectsVisibleRowRange', 'selectionIntersectsVisibleRowRange', 'pixelPositionForScreenPosition',
'screenPositionForPixelPosition', toProperty: 'displayBuffer'
@delegatesProperties '$lineHeight', '$defaultCharWidth', '$height', '$width',
'$scrollTop', '$scrollLeft', toProperty: 'displayBuffer'
@@ -512,8 +513,6 @@ class Editor extends Model
# this editor.
shouldPromptToSave: -> @isModified() and not @buffer.hasMultipleEditors()
pixelPositionForScreenPosition: (screenPosition) -> @displayBuffer.pixelPositionForScreenPosition(screenPosition)
# Public: Convert a position in buffer-coordinates to screen-coordinates.
#
# The position is clipped via {::clipBufferPosition} prior to the conversion.