mirror of
https://github.com/beefytech/Beef.git
synced 2025-06-08 11:38:21 +02:00
Require explicit insert action for multiline autocomplete insertions
This commit is contained in:
parent
73376d2f75
commit
018db49902
1 changed files with 8 additions and 0 deletions
|
@ -2751,7 +2751,15 @@ namespace IDE.ui
|
|||
return;
|
||||
}
|
||||
|
||||
bool isExplicitInsert = (keyChar == '\0') || (keyChar == '\t') || (keyChar == '\n');
|
||||
|
||||
String insertText = entry.mEntryInsert ?? entry.mEntryDisplay;
|
||||
if ((!isExplicitInsert) && (insertText.Contains('\t')))
|
||||
{
|
||||
// Don't insert multi-line blocks unless we have an explicit insert request (click, tab, or enter)
|
||||
return;
|
||||
}
|
||||
|
||||
if ((keyChar == '=') && (insertText.EndsWith("=")))
|
||||
insertText.RemoveToEnd(insertText.Length - 1);
|
||||
//insertText = insertText.Substring(0, insertText.Length - 1);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue