[2/2] richedit: Handle ctrl-key shortcuts on WM_KEYDOWN. (Fixes bug 15318)

Dylan Smith dylan.ah.smith at gmail.com
Tue Oct 21 19:43:47 CDT 2008


Previously the shortcuts for cut, copy, paste, undo, redo, and select
all were handled on WM_CHAR.  This caused a problem for Google Chrome
which replaced the window proc, and handled pasting in the address bar
on WM_KEYDOWN, but delegated other message handling such as WM_CHAR to
the builtin richedit window proc.  The result was two paste messages
being sent when Ctrl-v was pressed.

This patch fixes this problem by handling the shortcuts in WM_KEYDOWN as
native does.  In order to do this, I refactored the copying and pasting
to new methods, and had to move up some code that it referenced.
---
 dlls/riched20/editor.c       |  239 +++++++++++++++++++++++-------------------
 dlls/riched20/tests/editor.c |   10 +-
 2 files changed, 138 insertions(+), 111 deletions(-)
-------------- next part --------------
An embedded and charset-unspecified text was scrubbed...
Name: 0002-richedit-Handle-ctrl-key-shortcuts-on-WM_KEYDOWN.diff.txt
Url: http://www.winehq.org/pipermail/wine-patches/attachments/20081021/8f2a4ec6/attachment.txt 


More information about the wine-patches mailing list