| 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 969 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 980 bool EventHandler::bubblingScroll(ScrollDirection direction, ScrollGranularity g
ranularity, Node* startingNode) | 980 bool EventHandler::bubblingScroll(ScrollDirection direction, ScrollGranularity g
ranularity, Node* startingNode) |
| 981 { | 981 { |
| 982 // The layout needs to be up to date to determine if we can scroll. We may b
e | 982 // The layout needs to be up to date to determine if we can scroll. We may b
e |
| 983 // here because of an onLoad event, in which case the final layout hasn't be
en performed yet. | 983 // here because of an onLoad event, in which case the final layout hasn't be
en performed yet. |
| 984 m_frame->document()->updateLayoutIgnorePendingStylesheets(); | 984 m_frame->document()->updateLayoutIgnorePendingStylesheets(); |
| 985 // FIXME: enable scroll customization in this case. See crbug.com/410974. | 985 // FIXME: enable scroll customization in this case. See crbug.com/410974. |
| 986 if (scroll(direction, granularity, startingNode)) | 986 if (scroll(direction, granularity, startingNode)) |
| 987 return true; | 987 return true; |
| 988 LocalFrame* frame = m_frame; | 988 LocalFrame* frame = m_frame; |
| 989 FrameView* view = frame->view(); | 989 FrameView* view = frame->view(); |
| 990 if (view && view->scroll(direction, granularity)) | 990 if (view && view->scroll(direction, granularity)) { |
| 991 setFrameWasScrolledByUser(); |
| 991 return true; | 992 return true; |
| 993 } |
| 992 Frame* parentFrame = frame->tree().parent(); | 994 Frame* parentFrame = frame->tree().parent(); |
| 993 if (!parentFrame || !parentFrame->isLocalFrame()) | 995 if (!parentFrame || !parentFrame->isLocalFrame()) |
| 994 return false; | 996 return false; |
| 995 // FIXME: Broken for OOPI. | 997 // FIXME: Broken for OOPI. |
| 996 return toLocalFrame(parentFrame)->eventHandler().bubblingScroll(direction, g
ranularity, m_frame->deprecatedLocalOwner()); | 998 return toLocalFrame(parentFrame)->eventHandler().bubblingScroll(direction, g
ranularity, m_frame->deprecatedLocalOwner()); |
| 997 } | 999 } |
| 998 | 1000 |
| 999 IntPoint EventHandler::lastKnownMousePosition() const | 1001 IntPoint EventHandler::lastKnownMousePosition() const |
| 1000 { | 1002 { |
| 1001 return m_lastKnownMousePosition; | 1003 return m_lastKnownMousePosition; |
| (...skipping 3134 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 4136 unsigned EventHandler::accessKeyModifiers() | 4138 unsigned EventHandler::accessKeyModifiers() |
| 4137 { | 4139 { |
| 4138 #if OS(MACOSX) | 4140 #if OS(MACOSX) |
| 4139 return PlatformEvent::CtrlKey | PlatformEvent::AltKey; | 4141 return PlatformEvent::CtrlKey | PlatformEvent::AltKey; |
| 4140 #else | 4142 #else |
| 4141 return PlatformEvent::AltKey; | 4143 return PlatformEvent::AltKey; |
| 4142 #endif | 4144 #endif |
| 4143 } | 4145 } |
| 4144 | 4146 |
| 4145 } // namespace blink | 4147 } // namespace blink |
| OLD | NEW |