From a651270c09ed9c3885d2ba7177e1dee26ed91ae9 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?R=C3=A9gis=20Hanol?= Date: Mon, 29 Apr 2013 01:38:14 +0200 Subject: [PATCH] FIX: right click on selection deselects --- app/assets/javascripts/discourse/views/quote_button_view.js | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/app/assets/javascripts/discourse/views/quote_button_view.js b/app/assets/javascripts/discourse/views/quote_button_view.js index a718d2bb0af..18f424dbbb1 100644 --- a/app/assets/javascripts/discourse/views/quote_button_view.js +++ b/app/assets/javascripts/discourse/views/quote_button_view.js @@ -48,7 +48,8 @@ Discourse.QuoteButtonView = Discourse.View.extend({ .on("mousedown.quote-button", function(e) { view.set('isMouseDown', true); if ($(e.target).hasClass('quote-button') || $(e.target).hasClass('create')) return; - controller.deselectText(); + // deselects only when the user left-click + if (e.which === 1) controller.deselectText(); }) .on('mouseup.quote-button', function(e) { view.selectText(e.target, controller);