Go to file
Juan Luis Boya García c15e8517ef Fix bug in updatePossibleKeyCodes() with dead keys and modifiers
As it was until now, QWindowsKeyMapper::updatePossibleKeyCodes() tested
using ToUnicode for which characters produce a key with every possible
combination of modifiers.

Calling ToUnicode with a dead key is dangerous, because MS Windows keeps
it in the driver buffer, so if you call ToUnicode with acute key and
then you press a, you get an á.

To prevent this, updatePossibleKeyCodes() checked if the key that was
being tested was a dead key. If true, it inserted an space and then
repeated the key in order to reset the system internal buffers to the
same state they were before the call.

The problem with this is if the dead key is really two keys (like ^ or ´
in US International keyboard layout) and you press one of those keys
without the modifier to make it a dead key (i.e. 6 in US International):
Since updatePossibleKeyCodes() only tests for the key that was pressed
it gets 6 is not a dead key, and thus it does not execute the
workaround. Thus, the next time the user presses 'a' they get 'â'
instead because updatePossibleKeyCodes() set the dead key on the
keyboard buffer and did not run the workaround.

This patch makes updatePossibleKeyCodes() run the workaround if any
possible combination of modifiers with the key being examinated makes a
dead key.

Task-number: QTBUG-33591
Change-Id: I8c0b27586f7c62798986258b1b84aa90e4c5d64c
Reviewed-by: Oliver Wolff <oliver.wolff@digia.com>
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@digia.com>
2013-10-25 14:51:30 +02:00
bin Merge "Merge remote-tracking branch 'origin/release' into stable" into refs/staging/stable 2013-06-15 22:39:25 +02:00
config.tests Remove gstreamer configure test. 2013-10-24 20:20:59 +02:00
dist changelog: add note about TLS session tickets 2013-10-21 13:38:00 +02:00
doc Doc: Added iOS examples to manifest-meta.qdocconf 2013-10-24 14:36:22 +02:00
examples don't erroneously claim that gui support is needed 2013-10-16 17:10:15 +02:00
lib Initial import from the monolithic Qt. 2011-04-27 12:05:43 +02:00
mkspecs iOS (OSX): rework how to bundle QML import folders 2013-10-25 12:32:31 +02:00
qmake qmake: Expose qmake arguments as QMAKE_ARGS 2013-10-24 20:20:59 +02:00
src Fix bug in updatePossibleKeyCodes() with dead keys and modifiers 2013-10-25 14:51:30 +02:00
tests QFileDialog can delete files too, not just directories 2013-10-23 19:09:54 +02:00
tools Fix check for ICU on MinGW 2013-10-24 20:20:59 +02:00
util kill unix_to_dos script 2013-10-25 14:51:30 +02:00
.gitattributes Update the git-archive export options 2012-09-07 15:39:31 +02:00
.gitignore Long live QCommandLineParser! 2013-08-24 21:33:39 +02:00
.qmake.conf Enable -Werror for all of qtbase 2013-09-04 01:50:10 +02:00
.tag Update the git-archive export options 2012-09-07 15:39:31 +02:00
configure Remove superfluous 'libudev ...' line 2013-10-25 14:51:30 +02:00
configure.bat get rid of syncqt wrapper scripts 2013-05-13 21:54:48 +02:00
header.BSD Update copyright year in Digia's license headers 2013-01-18 09:07:35 +01:00
header.FDL Update copyright year in Digia's license headers 2013-01-18 09:07:35 +01:00
header.LGPL Update copyright year in Digia's license headers 2013-01-18 09:07:35 +01:00
header.LGPL-ONLY Update copyright year in Digia's license headers 2013-01-18 09:07:35 +01:00
INSTALL INSTALL: Fix URL of Installing Qt documentation 2013-04-11 16:09:07 +02:00
LGPL_EXCEPTION.txt Change copyrights from Nokia to Digia 2012-09-22 19:20:11 +02:00
LICENSE.FDL Initial import from the monolithic Qt. 2011-04-27 12:05:43 +02:00
LICENSE.GPL Add the LICENSE.GPL file to the module referenced from license headers 2012-05-20 22:41:08 +02:00
LICENSE.LGPL Update copyright year in Digia's license headers 2013-01-18 09:07:35 +01:00
LICENSE.PREVIEW.COMMERCIAL Update LICENSE.PREVIEW.COMMERCIAL license 2013-06-03 20:04:26 +02:00
qtbase.pro Merge remote-tracking branch 'origin/stable' into dev 2013-06-27 13:06:38 +02:00
sync.profile put ANGLE includes in a QtANGLE subdir 2013-06-10 21:12:13 +02:00