diff options
| author | Stephen Blott | 2014-12-28 11:52:37 +0000 |
|---|---|---|
| committer | Stephen Blott | 2014-12-28 11:52:37 +0000 |
| commit | 6066c97d7b4e5f65565ea769b18f9cbe4db8a833 (patch) | |
| tree | 9df9a6ba86f87667f6eb22e9320c7abf2c928694 | |
| parent | ff55b5bbf2a1b3c3310c93a2851b8bc3a7c491b3 (diff) | |
| parent | 278820f544d201b975a73ebe82d4a67792b967df (diff) | |
| download | vimium-6066c97d7b4e5f65565ea769b18f9cbe4db8a833.tar.bz2 | |
Merge branch 'link-hints-overlap' of https://github.com/mrmr1993/vimium into mrmr1993-link-hints-overlap
| -rw-r--r-- | content_scripts/link_hints.coffee | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/content_scripts/link_hints.coffee b/content_scripts/link_hints.coffee index df442ea6..3a9e2027 100644 --- a/content_scripts/link_hints.coffee +++ b/content_scripts/link_hints.coffee @@ -215,7 +215,8 @@ LinkHints = while visibleElement = visibleElements.pop() rects = [visibleElement.rect] for {rect: negativeRect} in visibleElements - rects = Array::concat.apply [], (rects.map (rect) -> Rect.subtract rect, negativeRect) + # Subtract negativeRect from every rect in rects, and concatenate the arrays of rects that result. + rects = [].concat (rects.map (rect) -> Rect.subtract rect, negativeRect)... if rects.length > 0 nonOverlappingElements.push {element: visibleElement.element, rect: rects[0]} else |
