diff options
author | Jason A. Donenfeld <Jason@zx2c4.com> | 2019-10-31 12:08:28 +0100 |
---|---|---|
committer | Jason A. Donenfeld <Jason@zx2c4.com> | 2019-12-11 12:06:25 +0100 |
commit | 5103eb85017a111db5cbf1cd3525f54ffebc1484 (patch) | |
tree | 95490ad0bc460fd329657794d6e5c59c3f6c13ec /ui | |
parent | tunnel: stop burst timer if we exceed 2 seconds (diff) | |
download | wireguard-windows-5103eb85017a111db5cbf1cd3525f54ffebc1484.tar.xz wireguard-windows-5103eb85017a111db5cbf1cd3525f54ffebc1484.zip |
syntax: disable events when highlighting
Diffstat (limited to 'ui')
-rw-r--r-- | ui/syntax/syntaxedit.c | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/ui/syntax/syntaxedit.c b/ui/syntax/syntaxedit.c index 2e53b011..80cff689 100644 --- a/ui/syntax/syntaxedit.c +++ b/ui/syntax/syntaxedit.c @@ -172,6 +172,7 @@ static void highlight_text(HWND hWnd) evaluate_untunneled_blocking(this, hWnd, msg, spans); this->idoc->lpVtbl->Undo(this->idoc, tomSuspend, NULL); + SendMessage(hWnd, EM_SETEVENTMASK, 0, 0); SendMessage(hWnd, WM_SETREDRAW, FALSE, 0); SendMessage(hWnd, EM_EXGETSEL, 0, (LPARAM)&orig_selection); SendMessage(hWnd, EM_GETSCROLLPOS, 0, (LPARAM)&original_scroll); @@ -198,6 +199,7 @@ static void highlight_text(HWND hWnd) SendMessage(hWnd, EM_HIDESELECTION, FALSE, 0); SendMessage(hWnd, WM_SETREDRAW, TRUE, 0); RedrawWindow(hWnd, NULL, NULL, RDW_ERASE | RDW_FRAME | RDW_INVALIDATE | RDW_ALLCHILDREN); + SendMessage(hWnd, EM_SETEVENTMASK, 0, ENM_CHANGE); this->idoc->lpVtbl->Undo(this->idoc, tomResume, NULL); if (!found_private_key) SendMessage(hWnd, SE_PRIVATE_KEY, 0, 0); |