2008-07-24 Tor Arne Vestbø <tavestbo@trolltech.com>
authorvestbo@webkit.org <vestbo@webkit.org@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Fri, 25 Jul 2008 12:05:03 +0000 (12:05 +0000)
committervestbo@webkit.org <vestbo@webkit.org@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Fri, 25 Jul 2008 12:05:03 +0000 (12:05 +0000)
        Reviewed by Simon

        Provide access to the underlying QKeyEvent in PlatformKeyboardEvent.

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@35341 268f45cc-cd09-0410-ab3c-d52691b4dbfc

WebCore/ChangeLog
WebCore/platform/PlatformKeyboardEvent.h
WebCore/platform/qt/PlatformKeyboardEventQt.cpp

index bf50a3460d77ba865105f75a8aa5b3eb4edb705e..7f92b532f1a679fa1abcde7de0581a06e3e73401 100644 (file)
@@ -1,3 +1,13 @@
+2008-07-24  Tor Arne Vestbø  <tavestbo@trolltech.com>
+
+        Reviewed by Simon
+
+        Provide access to the underlying QKeyEvent in PlatformKeyboardEvent.
+
+        * platform/PlatformKeyboardEvent.h: add accessor and member.
+        * platform/qt/PlatformKeyboardEventQt.cpp: copy pointer in ctor.
+        (WebCore::PlatformKeyboardEvent::PlatformKeyboardEvent):
+
 2008-07-25  Simon Hausmann  <hausmann@webkit.org>
 
         Fix linking of QtWebKit against the statically built JavaScriptCore
 2008-07-25  Simon Hausmann  <hausmann@webkit.org>
 
         Fix linking of QtWebKit against the statically built JavaScriptCore
index 2b95dddc6d0bfdbdfdd03a543f5a064a02c0415f..7ba9690adf01932286045e3c343e1d15348c7403 100644 (file)
@@ -139,6 +139,7 @@ namespace WebCore {
 
 #if PLATFORM(QT)
         PlatformKeyboardEvent(QKeyEvent*);
 
 #if PLATFORM(QT)
         PlatformKeyboardEvent(QKeyEvent*);
+        QKeyEvent* qtEvent() const { return m_qtEvent; }
 #endif
 
 #if PLATFORM(WX)
 #endif
 
 #if PLATFORM(WX)
@@ -166,6 +167,9 @@ namespace WebCore {
 #endif
 #if PLATFORM(GTK)
         GdkEventKey* m_gdkEventKey;
 #endif
 #if PLATFORM(GTK)
         GdkEventKey* m_gdkEventKey;
+#endif
+#if PLATFORM(QT)
+        QKeyEvent* m_qtEvent;
 #endif
     };
 
 #endif
     };
 
index 5a54d8a9ad6e04cbd0fbf3d3dca17f5087560813..cc2aba4403e5765b8a5f1608ecc96cbd4128dacf 100644 (file)
@@ -446,6 +446,7 @@ PlatformKeyboardEvent::PlatformKeyboardEvent(QKeyEvent* event)
     m_windowsVirtualKeyCode = windowsKeyCodeForKeyEvent(event->key());
     m_isKeypad = (state & Qt::KeypadModifier) != 0;
     m_shiftKey = (state & Qt::ShiftModifier) != 0 || event->key() == Qt::Key_Backtab; // Simulate Shift+Tab with Key_Backtab
     m_windowsVirtualKeyCode = windowsKeyCodeForKeyEvent(event->key());
     m_isKeypad = (state & Qt::KeypadModifier) != 0;
     m_shiftKey = (state & Qt::ShiftModifier) != 0 || event->key() == Qt::Key_Backtab; // Simulate Shift+Tab with Key_Backtab
+    m_qtEvent = event;
 }
 
 void PlatformKeyboardEvent::disambiguateKeyDownEvent(Type type, bool)
 }
 
 void PlatformKeyboardEvent::disambiguateKeyDownEvent(Type type, bool)