mirror of
https://github.com/UpsilonNumworks/Upsilon.git
synced 2026-01-19 00:37:25 +01:00
[apps/code] Remove double call to addAutocompletion
This commit is contained in:
@@ -412,11 +412,10 @@ void PythonTextArea::acceptAutocompletion(bool moveCursorToEndOfAutocompletion)
|
||||
m_contentView.pythonDelegate()->variableBoxController()->setSender(this);
|
||||
m_contentView.pythonDelegate()->variableBoxController()->insertAutocompletionResultAtIndex(m_autocompletionResultIndex);
|
||||
|
||||
/* Add the autocompletion if we moved the cursor. If we did not want to move
|
||||
* the cursor, restore its position. */
|
||||
if (moveCursorToEndOfAutocompletion) {
|
||||
addAutocompletion();
|
||||
} else {
|
||||
// insertAutocompletionResultAtIndex already added the autocompletion
|
||||
|
||||
// If we did not want to move the cursor, restore its position.
|
||||
if (!moveCursorToEndOfAutocompletion) {
|
||||
setCursorLocation(previousCursorLocation);
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user