aboutsummaryrefslogtreecommitdiffstats
path: root/linkHints.js
diff options
context:
space:
mode:
authorint32010-05-03 03:00:42 +0800
committerPhil Crosby2010-05-17 00:27:14 -0700
commit8001f3e553269739d8fd42671b58677455302eb0 (patch)
tree77058a35cbfa749d1f383d8cf53a4327d4700d8f /linkHints.js
parent04d57ed2126442d3f4b4d24d51e9e925c7f11f57 (diff)
downloadvimium-8001f3e553269739d8fd42671b58677455302eb0.tar.bz2
Fix link elimination boundaries
Diffstat (limited to 'linkHints.js')
-rw-r--r--linkHints.js4
1 files changed, 2 insertions, 2 deletions
diff --git a/linkHints.js b/linkHints.js
index 771b0728..fb47053d 100644
--- a/linkHints.js
+++ b/linkHints.js
@@ -124,8 +124,8 @@ function isVisible(element, boundingRect) {
// Exclude links which have just a few pixels on screen, because the link hints won't show for them anyway.
var zoomFactor = currentZoomLevel / 100.0;
- if (boundingRect.bottom <= 4 || boundingRect.top * zoomFactor >= window.innerHeight - 4 ||
- boundingRect.left <= 0 || boundingRect.left * zoomFactor >= window.innerWidth - 4)
+ if (boundingRect.top < 0 || boundingRect.top * zoomFactor >= window.innerHeight - 4 ||
+ boundingRect.left < 0 || boundingRect.left * zoomFactor >= window.innerWidth - 4)
return false;
if (boundingRect.width < 3 || boundingRect.height < 3)