OLD | NEW |
1 /* | 1 /* |
2 * Copyright (C) 2006, 2007, 2008, 2009, 2010, 2011 Apple Inc. All rights reserv
ed. | 2 * Copyright (C) 2006, 2007, 2008, 2009, 2010, 2011 Apple Inc. All rights reserv
ed. |
3 * Copyright (C) 2006 Alexey Proskuryakov (ap@webkit.org) | 3 * Copyright (C) 2006 Alexey Proskuryakov (ap@webkit.org) |
4 * Copyright (C) 2012 Digia Plc. and/or its subsidiary(-ies) | 4 * Copyright (C) 2012 Digia Plc. and/or its subsidiary(-ies) |
5 * | 5 * |
6 * Redistribution and use in source and binary forms, with or without | 6 * Redistribution and use in source and binary forms, with or without |
7 * modification, are permitted provided that the following conditions | 7 * modification, are permitted provided that the following conditions |
8 * are met: | 8 * are met: |
9 * 1. Redistributions of source code must retain the above copyright | 9 * 1. Redistributions of source code must retain the above copyright |
10 * notice, this list of conditions and the following disclaimer. | 10 * notice, this list of conditions and the following disclaimer. |
(...skipping 2951 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
2962 || (keyCode >= VK_OEM_1 && keyCode <= VK_OEM_PLUS) | 2962 || (keyCode >= VK_OEM_1 && keyCode <= VK_OEM_PLUS) |
2963 || (keyCode >= VK_MULTIPLY && keyCode <= VK_OEM_8); | 2963 || (keyCode >= VK_MULTIPLY && keyCode <= VK_OEM_8); |
2964 } | 2964 } |
2965 | 2965 |
2966 bool EventHandler::keyEvent(const PlatformKeyboardEvent& initialKeyEvent) | 2966 bool EventHandler::keyEvent(const PlatformKeyboardEvent& initialKeyEvent) |
2967 { | 2967 { |
2968 RefPtr<FrameView> protector(m_frame->view()); | 2968 RefPtr<FrameView> protector(m_frame->view()); |
2969 | 2969 |
2970 ASSERT(m_frame->document()); | 2970 ASSERT(m_frame->document()); |
2971 if (Fullscreen* fullscreen = Fullscreen::fromIfExists(*m_frame->document()))
{ | 2971 if (Fullscreen* fullscreen = Fullscreen::fromIfExists(*m_frame->document()))
{ |
2972 if (fullscreen->webkitIsFullScreen() && !isKeyEventAllowedInFullScreen(f
ullscreen, initialKeyEvent)) { | 2972 if (fullscreen->webkitCurrentFullScreenElement() && !isKeyEventAllowedIn
FullScreen(fullscreen, initialKeyEvent)) { |
2973 UseCounter::count(*m_frame->document(), UseCounter::KeyEventNotAllow
edInFullScreen); | 2973 UseCounter::count(*m_frame->document(), UseCounter::KeyEventNotAllow
edInFullScreen); |
2974 return false; | 2974 return false; |
2975 } | 2975 } |
2976 } | 2976 } |
2977 | 2977 |
2978 if (initialKeyEvent.windowsVirtualKeyCode() == VK_CAPITAL) | 2978 if (initialKeyEvent.windowsVirtualKeyCode() == VK_CAPITAL) |
2979 capsLockStateMayHaveChanged(); | 2979 capsLockStateMayHaveChanged(); |
2980 | 2980 |
2981 #if OS(WIN) | 2981 #if OS(WIN) |
2982 if (panScrollInProgress()) { | 2982 if (panScrollInProgress()) { |
(...skipping 867 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
3850 unsigned EventHandler::accessKeyModifiers() | 3850 unsigned EventHandler::accessKeyModifiers() |
3851 { | 3851 { |
3852 #if OS(MACOSX) | 3852 #if OS(MACOSX) |
3853 return PlatformEvent::CtrlKey | PlatformEvent::AltKey; | 3853 return PlatformEvent::CtrlKey | PlatformEvent::AltKey; |
3854 #else | 3854 #else |
3855 return PlatformEvent::AltKey; | 3855 return PlatformEvent::AltKey; |
3856 #endif | 3856 #endif |
3857 } | 3857 } |
3858 | 3858 |
3859 } // namespace blink | 3859 } // namespace blink |
OLD | NEW |