From 457bbc83427a042fd77cddf974f970cd950ceda7 Mon Sep 17 00:00:00 2001 From: Thomas Renck Date: Thu, 12 Jun 2014 15:25:14 -0700 Subject: [PATCH] Added event param to getHorizontalBounds Firefox errors on getHorizontalBounds() because event is out of scope, so I added event to the parameters. --- js/grande.js | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/js/grande.js b/js/grande.js index 36e00ff..857703c 100644 --- a/js/grande.js +++ b/js/grande.js @@ -141,7 +141,7 @@ var childrenNodes = editNode.children, editBounds = editNode.getBoundingClientRect(); - imageBound = getHorizontalBounds(childrenNodes, editBounds); + imageBound = getHorizontalBounds(childrenNodes, editBounds, event); } function uploadImage(event) { @@ -164,7 +164,7 @@ function toggleImageTooltip(event, element) { var childrenNodes = editNode.children, editBounds = editNode.getBoundingClientRect(), - bound = getHorizontalBounds(childrenNodes, editBounds); + bound = getHorizontalBounds(childrenNodes, editBounds, event); if (bound) { imageTooltip.style.left = (editBounds.left - 90 ) + "px"; @@ -175,7 +175,7 @@ } } - function getHorizontalBounds(nodes, target) { + function getHorizontalBounds(nodes, target, event) { var bounds = [], bound, i,