aboutsummaryrefslogtreecommitdiffstats
path: root/lib
diff options
context:
space:
mode:
authormrmr19932017-07-04 12:46:42 +0100
committermrmr19932017-11-01 07:46:22 +0000
commite424bb942b58e5cee3506e42b6f3aa9008eb7b17 (patch)
tree6e39bb954d67bf486db385562f5a3307916fa243 /lib
parent8cd39d357b129e40b1e3a8fc99910bf4c76747c0 (diff)
downloadvimium-e424bb942b58e5cee3506e42b6f3aa9008eb7b17.tar.bz2
Rename Rect.contains to Rect.intersects, add an explanitory comment
Diffstat (limited to 'lib')
-rw-r--r--lib/rect.coffee3
1 files changed, 2 insertions, 1 deletions
diff --git a/lib/rect.coffee b/lib/rect.coffee
index fdeace25..703c640c 100644
--- a/lib/rect.coffee
+++ b/lib/rect.coffee
@@ -67,7 +67,8 @@ Rect =
rects.filter (rect) -> rect.height > 0 and rect.width > 0
- contains: (rect1, rect2) ->
+ # Determine whether two rects overlap.
+ intersects: (rect1, rect2) ->
rect1.right > rect2.left and
rect1.left < rect2.right and
rect1.bottom > rect2.top and