Imrpove console evaluation somewhat. Fix restart bug not resetting connection in the console view
This commit is contained in:
parent
3a898edd34
commit
256579c4d8
3 changed files with 11 additions and 4 deletions
|
|
@ -201,7 +201,7 @@ def AskForInput( prompt ):
|
|||
return vim.eval( "input( '{0}' )".format( Escape( prompt ) ) )
|
||||
|
||||
|
||||
def AppendToBuffer( buf, line_or_lines ):
|
||||
def AppendToBuffer( buf, line_or_lines, modified=False ):
|
||||
# After clearing the buffer (using buf[:] = None) there is always a single
|
||||
# empty line in the buffer object and no "is empty" method.
|
||||
if len( buf ) > 1 or buf[ 0 ]:
|
||||
|
|
@ -214,6 +214,9 @@ def AppendToBuffer( buf, line_or_lines ):
|
|||
line = 1
|
||||
buf[:] = line_or_lines
|
||||
|
||||
if not modified:
|
||||
buf.options[ 'modified' ] = False
|
||||
|
||||
# Return the first Vim line number (1-based) that we just set.
|
||||
return line
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue