| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright (C) 2006, 2007, 2009, 2010, 2011 Apple Inc. All rights reserved. | 2 * Copyright (C) 2006, 2007, 2009, 2010, 2011 Apple Inc. All rights reserved. |
| 3 * | 3 * |
| 4 * Redistribution and use in source and binary forms, with or without | 4 * Redistribution and use in source and binary forms, with or without |
| 5 * modification, are permitted provided that the following conditions | 5 * modification, are permitted provided that the following conditions |
| 6 * are met: | 6 * are met: |
| 7 * 1. Redistributions of source code must retain the above copyright | 7 * 1. Redistributions of source code must retain the above copyright |
| 8 * notice, this list of conditions and the following disclaimer. | 8 * notice, this list of conditions and the following disclaimer. |
| 9 * 2. Redistributions in binary form must reproduce the above copyright | 9 * 2. Redistributions in binary form must reproduce the above copyright |
| 10 * notice, this list of conditions and the following disclaimer in the | 10 * notice, this list of conditions and the following disclaimer in the |
| (...skipping 255 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 266 void activeIntervalTimerFired(Timer<EventHandler>*); | 266 void activeIntervalTimerFired(Timer<EventHandler>*); |
| 267 | 267 |
| 268 void fakeMouseMoveEventTimerFired(Timer<EventHandler>*); | 268 void fakeMouseMoveEventTimerFired(Timer<EventHandler>*); |
| 269 void cancelFakeMouseMoveEvent(); | 269 void cancelFakeMouseMoveEvent(); |
| 270 bool isCursorVisible() const; | 270 bool isCursorVisible() const; |
| 271 void updateCursor(); | 271 void updateCursor(); |
| 272 | 272 |
| 273 ScrollableArea* associatedScrollableArea(const PaintLayer*) const; | 273 ScrollableArea* associatedScrollableArea(const PaintLayer*) const; |
| 274 | 274 |
| 275 // Performs a chaining scroll, within a *single* frame, starting from a | 275 // Performs a chaining scroll, within a *single* frame, starting from a |
| 276 // given node and optionally stopping on a given node. Does *not* attempt | 276 // given node and optionally stopping on a given node. |
| 277 // to scroll the layout view. | |
| 278 // granularity - The units that the scroll delta parameter is in. | 277 // granularity - The units that the scroll delta parameter is in. |
| 279 // delta - The delta to scroll by, in the units of the granularity param | 278 // delta - The delta to scroll by, in the units of the granularity param |
| 280 // (e.g. pixels, lines, pages, etc.). These are in a physical | 279 // (e.g. pixels, lines, pages, etc.). These are in a physical |
| 281 // direction. i.e. Positive is down and right. | 280 // direction. i.e. Positive is down and right. |
| 282 // startNode - The node to start the scroll chaining from. | 281 // startNode - The node to start the scroll chaining from. |
| 283 // stopNode - On input, if provided and non-null, the node at which we | 282 // stopNode - On input, if non-null, the node at which we should stop |
| 284 // should stop chaining. On output, if provided and a node was | 283 // chaining. On output, if provided and a node was scrolled, |
| 285 // scrolled, stopNode will point to that node. | 284 // stopNode will point to that node. |
| 286 ScrollResult physicalScroll(ScrollGranularity, const FloatSize& delta, Node*
startNode, Node** stopNode = nullptr); | 285 // consumed - [OUT] Whether the scroll was consumed. This is different than |
| 286 // ScrollResult.didScroll since we might not have scrolled but |
| 287 // have reached the stopNode and thus don't want to continue |
| 288 // chaining the scroll. |
| 289 ScrollResult physicalScroll(ScrollGranularity, const FloatSize& delta, Node*
startNode, Node** stopNode, bool* consumed); |
| 287 | 290 |
| 288 // Performs a chaining logical scroll, within a *single* frame, starting | 291 // Performs a chaining logical scroll, within a *single* frame, starting |
| 289 // from either a provided starting node or a default based on the focused or | 292 // from either a provided starting node or a default based on the focused or |
| 290 // most recently clicked node. | 293 // most recently clicked node, falling back to the frame. |
| 291 // Returns true if the scroll was consumed. | 294 // Returns true if the scroll was consumed. |
| 292 // direction - The logical direction to scroll in. This will be converted to | 295 // direction - The logical direction to scroll in. This will be converted to |
| 293 // a physical direction for each LayoutBox we try to scroll | 296 // a physical direction for each LayoutBox we try to scroll |
| 294 // based on that box's writing mode. | 297 // based on that box's writing mode. |
| 295 // granularity - The units that the scroll delta parameter is in. | 298 // granularity - The units that the scroll delta parameter is in. |
| 296 // startNode - Optional. If provided, start chaining from the given node. | 299 // startNode - Optional. If provided, start chaining from the given node. |
| 297 // If not, use the current focus or last clicked node. | 300 // If not, use the current focus or last clicked node. |
| 298 bool logicalScroll(ScrollDirection, ScrollGranularity, Node* startNode = nul
lptr); | 301 bool logicalScroll(ScrollDirection, ScrollGranularity, Node* startNode = nul
lptr); |
| 299 | 302 |
| 300 void resetOverscroll(bool didScrollX, bool didScrollY); | 303 void resetOverscroll(bool didScrollX, bool didScrollY); |
| (...skipping 174 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 475 // scroll which shouldn't propagate can't cause any element to | 478 // scroll which shouldn't propagate can't cause any element to |
| 476 // scroll other than the |m_previousGestureScrolledNode|. | 479 // scroll other than the |m_previousGestureScrolledNode|. |
| 477 bool m_deltaConsumedForScrollSequence; | 480 bool m_deltaConsumedForScrollSequence; |
| 478 }; | 481 }; |
| 479 | 482 |
| 480 } // namespace blink | 483 } // namespace blink |
| 481 | 484 |
| 482 WTF_ALLOW_INIT_WITH_MEM_FUNCTIONS(blink::EventHandler::TouchInfo); | 485 WTF_ALLOW_INIT_WITH_MEM_FUNCTIONS(blink::EventHandler::TouchInfo); |
| 483 | 486 |
| 484 #endif // EventHandler_h | 487 #endif // EventHandler_h |
| OLD | NEW |