Disable two-finger swipe on Firefox

32

13

When I scroll along the page or some scrollbox with two fingers on MacBook Pro touchpad, and it can be no longer scrolled to the left, Firefox decides I want to go back in history.

What can I do to disable history navigation using two-finger swipe in Firefox 17? I'm happy with using Backspace for going backwards, and wiping out all the text I was writing somewhere in some forms when I accidentally scroll more than I'm allowed is really frustrating.

toriningen

Posted 2012-12-22T22:52:20.973

Reputation: 455

Answers

57

I like the following solution better (than the existing answer) because it only affects Firefox:

  1. In Firefox, go to "about:config"
  2. Change the value for "browser.gesture.swipe.left" to "cmd_scrollLeft" (instead of "Browser:BackOrBackDuplicate")
  3. Change the value for "browser.gesture.swipe.right" to "cmd_scrollRight" (instead of "Browser:ForwardOrForwardDuplicate")

enter image description here

Charlesism

Posted 2012-12-22T22:52:20.973

Reputation: 686

I know it is against policy to leave "thank you" comments, but that issue was haunting me for years already. Thanks! – Anton Purin – 2019-12-03T08:23:33.117

Still works with Firefox Quantum (tested with 68.3esr) under OSX Mojave (tested with 10.14.6). Yay! – Bryan P – 2019-12-12T18:29:06.300

2This is awesome! Finally there is solution that WORKS. Thank you so much! And welcome to SuperUser — good start :) – toriningen – 2013-09-10T00:53:10.100

11

UPDATE:

There is a native way to do this. Go to System Preferences / Trackpad / More Gestures and deactivate the checkbox for "Swipe between pages" (first checkbox). This works at least for Mountain Lion.


The old, non-functional answer was:

I do not know of a native option in OSX (ML, 10.8.x), but there is a nice trick to do it:

Download the free BetterTouchTool. It lets you map a huge amount of functions to trackpad & mouse gestures as well as keyboard shortcuts. You can set "No action" and you can decide, which applications should know your new custom gesture/shortcut.

So I just mapped the two finger swipe (left & right) to "No action" only for Firefox, Chrome, Safari, Opera and Sleipnir.

Hugely useful and it will solve your problem.

Oliver

Posted 2012-12-22T22:52:20.973

Reputation: 210

Good first post. Sounds like a potential solution. – nixda – 2012-12-30T03:32:15.060

Unfortunately, tried on OSX Lion (10.7.x) and latest currently available BTT — it surely handles two-finger swipes in either direction, but default action (e.g. history navigation) is also triggered with wherever action I set for swipe in BTT. So if I set "show Mission Control" action for swipe, I get both history navigation AND mission control invokation. :( Is there something additional to look for? – toriningen – 2012-12-30T09:22:42.587

Oops. How embarrassing! Good: I tested it myself before posting. Bad: I tried it on a browser tab without a history (so obviously there is nowhere to swipe to).

But: I got it working. In System preferences / Trackpad / More Gestures.

I can set "Swipe between pages" off. This works for me (Mountain Lion)

I am updating the answer to reflect this. – Oliver – 2012-12-30T11:23:02.333

2Disabling system-wide swipe gesture disables it not only in Firefox, but also in Preview and Finder, and other apps where it's considered useful, and makes them inconvenient to use. – toriningen – 2013-02-16T17:05:27.907