[PATCH v7 3/7] shell32/autocomplete: Don't auto-append on control characters, except for ^V (paste)
Gabriel Ivăncescu
gabrielopcode at gmail.com
Mon Sep 17 14:23:11 CDT 2018
We must not auto-append on control characters, most notably Backspace, but
also ^X (cut) and so on. An exception is ^V, which auto-appends on Windows,
so this is needed to match Windows behavior (also needed when receiving
the ^V message directly).
Signed-off-by: Gabriel Ivăncescu <gabrielopcode at gmail.com>
---
dlls/shell32/autocomplete.c | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/dlls/shell32/autocomplete.c b/dlls/shell32/autocomplete.c
index 183b37b..429b4fb 100644
--- a/dlls/shell32/autocomplete.c
+++ b/dlls/shell32/autocomplete.c
@@ -343,7 +343,8 @@ static LRESULT APIENTRY ACEditSubclassProc(HWND hwnd, UINT uMsg, WPARAM wParam,
case WM_CHAR:
case WM_UNICHAR:
ret = CallWindowProcW(This->wpOrigEditProc, hwnd, uMsg, wParam, lParam);
- autocomplete_text(This, hwnd, (This->options & ACO_AUTOAPPEND)
+ autocomplete_text(This, hwnd, (This->options & ACO_AUTOAPPEND) &&
+ (wParam >= ' ' || wParam == 0x16 /* ^V (paste) */)
? autoappend_flag_yes : autoappend_flag_no);
return ret;
case WM_DESTROY:
--
1.9.1
More information about the wine-devel
mailing list