diff options
| author | Stephen Blott | 2015-01-31 12:13:48 +0000 | 
|---|---|---|
| committer | Stephen Blott | 2015-01-31 12:16:08 +0000 | 
| commit | f31de0f29b857390de315b8ca5cdf20619fbab70 (patch) | |
| tree | 2b7b7d1271294289a1c0c9eabb99f2504645557c | |
| parent | 90d2addc9b8f95f9272f8c2a77bdaf9dfebc0fa8 (diff) | |
| download | vimium-f31de0f29b857390de315b8ca5cdf20619fbab70.tar.bz2 | |
Revert "Fix scrolling issue."
This reverts commit 90d2addc9b8f95f9272f8c2a77bdaf9dfebc0fa8.
Nope.  This is bad.  It fixes the issue referred to in the commit
record, but breaks scrolling out of text areas.
With 90d2addc9b8f95f9272f8c2a77bdaf9dfebc0fa8:
- Start editing in a text area, add enough text that it scrolls.
- `Escape`
- `k`, `k`, `k`, ...
We expect first the text areas to scroll, then -- when it reaches the
top -- the document to scroll.  However, with
90d2addc9b8f95f9272f8c2a77bdaf9dfebc0fa8, we get stuck in the text
area.
| -rw-r--r-- | content_scripts/scroller.coffee | 6 | 
1 files changed, 1 insertions, 5 deletions
| diff --git a/content_scripts/scroller.coffee b/content_scripts/scroller.coffee index b9e7d76a..6e2e1ffc 100644 --- a/content_scripts/scroller.coffee +++ b/content_scripts/scroller.coffee @@ -75,11 +75,7 @@ doesScroll = (element, direction, amount, factor) ->    # definitely scrolling backwards, so a delta of -1 will do.  For absolute scrolls, factor is always 1.    delta = factor * getDimension(element, direction, amount) || -1    delta = getSign delta # 1 or -1 -  for change in [ delta, -delta ] -    if performScroll element, direction, change -      performScroll element, direction, -change -      return true -  false +  performScroll(element, direction, delta) and performScroll(element, direction, -delta)  # From element and its parents, find the first which we should scroll and which does scroll.  findScrollableElement = (element, direction, amount, factor) -> | 
