From bf49485d4c08103924e55a181526213267b814bf Mon Sep 17 00:00:00 2001 From: Nick O'Leary Date: Sun, 11 May 2014 13:57:54 +0100 Subject: [PATCH] Handle null TouchEvent (FF/Safari) --- public/red/ui/view.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/public/red/ui/view.js b/public/red/ui/view.js index 5e154b39f..879a2f47e 100644 --- a/public/red/ui/view.js +++ b/public/red/ui/view.js @@ -668,7 +668,7 @@ RED.view = function() { function portMouseUp(d,portType,portIndex) { document.body.style.cursor = ""; if (mouse_mode == RED.state.JOINING && mousedown_node) { - if (d3.event instanceof TouchEvent) { + if (typeof TouchEvent != "undefined" && d3.event instanceof TouchEvent) { RED.nodes.eachNode(function(n) { if (n.z == activeWorkspace) { var hw = n.w/2;