diff options
| author | Stephen Blott | 2018-09-04 15:17:05 +0100 | 
|---|---|---|
| committer | Stephen Blott | 2018-09-04 15:17:05 +0100 | 
| commit | 12952674a9233fca4d46d85d896f6c5fb008fd2e (patch) | |
| tree | 98c1a6bc11e73a2a0c697d1dc014fe9fb7a0b546 /content_scripts/scroller.coffee | |
| parent | 339f37fb5c19f5129c7757294d8c5968be9c9db2 (diff) | |
| download | vimium-12952674a9233fca4d46d85d896f6c5fb008fd2e.tar.bz2 | |
Revert "Add special-case rule for GMail."
This reverts commit aff380669445594e7566a835d4b27f11da26ea6a.
This breaks scrolling on Twitter.
Needs more thought.
Diffstat (limited to 'content_scripts/scroller.coffee')
| -rw-r--r-- | content_scripts/scroller.coffee | 6 | 
1 files changed, 2 insertions, 4 deletions
| diff --git a/content_scripts/scroller.coffee b/content_scripts/scroller.coffee index cb56b4bf..94a0d4f1 100644 --- a/content_scripts/scroller.coffee +++ b/content_scripts/scroller.coffee @@ -89,9 +89,8 @@ isScrollableElement = (element, direction = "y", amount = 1, factor = 1) ->  # From element and its parents, find the first which we should scroll and which does scroll.  findScrollableElement = (element, direction, amount, factor) -> -  while not isScrollableElement element, direction, amount, factor +  while element != getScrollingElement() and not isScrollableElement element, direction, amount, factor      element = DomUtils.getContainingElement(element) ? getScrollingElement() -    return element if element == getScrollingElement() # Prevent infinite loop.    element  # On some pages, the scrolling element is not actually scrollable.  Here, we search the document for the @@ -103,7 +102,7 @@ firstScrollableElement = (element = null) ->      if doesScroll(scrollingElement, "y", 1, 1) or doesScroll(scrollingElement, "y", -1, 1)        return scrollingElement      else -      element = getScrollingElement() ? document.body +      element = document.body ? getScrollingElement()    if doesScroll(element, "y", 1, 1) or doesScroll(element, "y", -1, 1)      element @@ -323,7 +322,6 @@ specialScrollingElementMap =    'twitter.com': 'div.permalink-container div.permalink[role=main]'    'reddit.com': '#overlayScrollContainer'    'new.reddit.com': '#overlayScrollContainer' -  'mail.google.com': 'table[role="presentation"]'  root = exports ? (window.root ?= {})  root.Scroller = Scroller | 
