From e992d194f31a37cbf2cb2a34c08f218ad9be2113 Mon Sep 17 00:00:00 2001 From: Dan Vanderkam Date: Thu, 22 Mar 2012 17:54:53 -0400 Subject: [PATCH] Fix Issue 145: Chrome/right-click seems to start implementing zoom bounding boxes. --- dygraph-interaction-model.js | 3 +++ 1 file changed, 3 insertions(+) diff --git a/dygraph-interaction-model.js b/dygraph-interaction-model.js index 2790633..b6c19d2 100644 --- a/dygraph-interaction-model.js +++ b/dygraph-interaction-model.js @@ -499,6 +499,9 @@ Dygraph.Interaction.endTouch = function(event, g, context) { Dygraph.Interaction.defaultModel = { // Track the beginning of drag events mousedown: function(event, g, context) { + // Right-click should not initiate a zoom. + if (event.button && event.button == 2) return; + context.initializeMouseDown(event, g, context); if (event.altKey || event.shiftKey) { -- 2.7.4