Remove unused comment

This commit is contained in:
c-bata 2017-07-17 02:21:14 +09:00
parent d1f3414be3
commit 6dafc9ad1f

@ -9,7 +9,7 @@ type Buffer struct {
workingLines []string // The working lines. Similar to history workingLines []string // The working lines. Similar to history
workingIndex int workingIndex int
CursorPosition int CursorPosition int
cacheDocument *Document // TODO: More effective cache using Queue or map. See https://github.com/jonathanslenders/python-prompt-toolkit/blob/master/prompt_toolkit/cache.py#L55-L93 cacheDocument *Document
preferredColumn int // Remember the original column for the next up/down movement. preferredColumn int // Remember the original column for the next up/down movement.
} }
@ -50,9 +50,6 @@ func (b *Buffer) InsertText(v string, overwrite bool, moveCursor bool) {
if moveCursor { if moveCursor {
b.CursorPosition += len([]rune(v)) b.CursorPosition += len([]rune(v))
} }
// TODO: Fire onTextInsert event.
// https://github.com/jonathanslenders/python-prompt-toolkit/blob/master/prompt_toolkit/buffer.py#L1063-L1065
} }
// SetText method to set text and update CursorPosition. // SetText method to set text and update CursorPosition.
@ -62,8 +59,6 @@ func (b *Buffer) setText(v string) {
if b.CursorPosition > len([]rune(v)) { if b.CursorPosition > len([]rune(v)) {
panic("The length of input value should be shorter than the position of cursor.") panic("The length of input value should be shorter than the position of cursor.")
} }
// TODO: Add checking that the buffer is read only?
// https://github.com/jonathanslenders/python-prompt-toolkit/blob/master/prompt_toolkit/buffer.py#L374-L376
o := b.workingLines[b.workingIndex] o := b.workingLines[b.workingIndex]
b.workingLines[b.workingIndex] = v b.workingLines[b.workingIndex] = v