Skip to content

Instantly share code, notes, and snippets.

@robcee
Created January 17, 2018 15:37
Show Gist options
  • Save robcee/6eb5c4c11e314a74247a137ac7de2da5 to your computer and use it in GitHub Desktop.
Save robcee/6eb5c4c11e314a74247a137ac7de2da5 to your computer and use it in GitHub Desktop.
/**
* pinchy preferences.
*
* Execute in a Browser Scratchpad.
* 1. Open Firefox Developer Tools (cmd-opt-i)
* 2. Open Settings (gear icon)
* 3. Check "Enable browser chrome and add-on debugging toolboxes"
* and "Enable remote debugging" in "Advanced Settings"
* 4. Maybe restart the browser
* 5. Open Scratchpad (shift-F4)
* 6. From the Environment menu, select "Browser"
* 7. Hit Run on the toolbar
*/
Services.prefs.setStringPref("browser.gesture.pinch.in", "cmd_fullZoomReduce");
Services.prefs.setStringPref("browser.gesture.pinch.in.shift", "cmd_close");
Services.prefs.setStringPref("browser.gesture.pinch.out", "cmd_fullZoomEnlarge");
Services.prefs.setStringPref("browser.gesture.pinch.out.shift", "View:FullScreen");
Services.prefs.setIntPref("browser.gesture.pinch.threshold", 50);
Services.prefs.setStringPref("browser.gesture.swipe.left.shift", "Browser:PrevTab");
Services.prefs.setStringPref("browser.gesture.swipe.right.shift", "Browser:NextTab");
Services.prefs.setIntPref("browser.gesture.twist.threshold", 20);
@robcee
Copy link
Author

robcee commented Jan 17, 2018

results in trackpad gestures for pinch-to-zoom, shift-pinch to close a tab, shift-pinch out to enter fullscreen.
Shift+three-finger-swipes switches tabs left and right.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment