summaryrefslogtreecommitdiffstats
path: root/webkit/glue/event_conversion.cc
diff options
context:
space:
mode:
authorestade@chromium.org <estade@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2008-12-09 23:38:39 +0000
committerestade@chromium.org <estade@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2008-12-09 23:38:39 +0000
commit3b2792bf4a12e151ed83d272b3eb4729496ee130 (patch)
tree2b16032a261cb06d35bbbe30f76220b67fdcffd6 /webkit/glue/event_conversion.cc
parentff34e3e9184dc76abfeec7fc7783336950cfdb8b (diff)
downloadchromium_src-3b2792bf4a12e151ed83d272b3eb4729496ee130.zip
chromium_src-3b2792bf4a12e151ed83d272b3eb4729496ee130.tar.gz
chromium_src-3b2792bf4a12e151ed83d272b3eb4729496ee130.tar.bz2
Correctly construct platform keyboard event in event sending controller.
Same as issue 12981 with but now with change to test_shell.vsprops. This change makes it actually compile on windows! It also makes it clear that test shell is looking in webkit directories for include files. Apparently this was already the case on linux and mac, but it is new for windows. Review URL: http://codereview.chromium.org/13678 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@6657 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'webkit/glue/event_conversion.cc')
-rw-r--r--webkit/glue/event_conversion.cc11
1 files changed, 6 insertions, 5 deletions
diff --git a/webkit/glue/event_conversion.cc b/webkit/glue/event_conversion.cc
index 5de8271..881cdae 100644
--- a/webkit/glue/event_conversion.cc
+++ b/webkit/glue/event_conversion.cc
@@ -283,10 +283,8 @@ MakePlatformKeyboardEvent::MakePlatformKeyboardEvent(const WebKeyboardEvent& e)
m_text = "\x9";
m_unmodifiedText = "\x9";
}
-#elif defined(OS_WIN)
+#elif defined(OS_WIN) || defined(OS_LINUX)
m_text = m_unmodifiedText = ToSingleCharacterString(e.key_code);
-#elif defined(OS_LINUX)
- m_text = m_unmodifiedText = ToSingleCharacterString(e.text);
#endif
}
#if defined(OS_WIN) || defined(OS_LINUX)
@@ -307,10 +305,13 @@ MakePlatformKeyboardEvent::MakePlatformKeyboardEvent(const WebKeyboardEvent& e)
m_metaKey = (e.modifiers & WebInputEvent::META_KEY) != 0;
#if defined(OS_WIN)
m_isSystemKey = e.system_key;
+// TODO(port): set this field properly for linux and mac.
+#elif defined(OS_LINUX)
+ m_isSystemKey = m_altKey;
#else
- m_isSystemKey = false; // TODO(port): make this proper.
+ m_isSystemKey = false;
#endif
-}
+}
void MakePlatformKeyboardEvent::SetKeyType(Type type) {
// According to the behavior of Webkit in Windows platform,