foxygestures
foxygestures copied to clipboard
Mouse gesture will stop functioning when opening new tab in upcoming Firefox.
Foxygesture (mouse gesture) suddenly not working on newly opened tab for the past few firefox nightly.
Press CTRL + T to open new tab and do any kind of gesture such as close tab etc. It will not work.
I posted about it at MozillaZine forum and user Fanolian informed it is caused by Bug 1676492 "fix". Judging from Mozilla history, they probably "wontfix".
However, if I set about:blank at Foxygesture "Default URL for tabs opened with New Tab command", mouse gesture will work in the newly opened about:blank tab. The only grip is, it is not automatically focused at urlbar once the new tab is opened via gesture. Is there any way to automatically focus on the urlbar so that I can begin typing right away after I opened a new tab (about:blank) via gesture?
The issue is reproducible only when new tab and/or homepage/new window is set to blank page
.
Steps to reproduce
- Install latest Foxy Gestures 1.2.12 in a new profile in Firefox Beta 108.0b2 or Nightly.
- In about:preferences#home, set "Homepage and new windows" and "New tabs" to
Blank Page
. - Open a new tab or window by whatever means.
- Try to draw a mouse or wheel gesture in this new tab.
Actual result
Gestures cannot be initiated because this new "blank tab" is no longer about:blank
but chrome://browser/content/blanktab.html
after bug 1676492.
Yeah, looks like they won't be fixing this any time soon.
I did find a workaround for now by abusing the autoconfig system of firefox. Using it you can manually set the new tab page to about:blank to replicate the previous behaviour.
To do so you need to add two files to the installation folder of firefox:
defaults/pref/autoconfig.js
// Disable config sandbox
pref('general.config.sandbox_enabled', false);
// Point towards about-home fix
pref("general.config.filename", "blank-about-home-fix.cfg");
// Do not obfuscate contents
pref("general.config.obscure_value", 0);
blank-about-home-fix.cfg
// Load Components
var {classes:Cc,interfaces:Ci,utils:Cu} = Components;
/* set new tab page */
try {
Cu.import("resource:///modules/AboutNewTab.jsm");
AboutNewTab.newTabURL = "about:blank";
} catch(e){Cu.reportError(e);} // report errors in the Browser Console
paths are relative to the root of the firefox installation folder (the one containing firefox.exe).
I can only hope they implement a proper webextension API for gestures and hotkeys before we run out of workarounds.
Thanks for the workaround instruction, it works! @Shiandow
Yeah, looks like they won't be fixing this any time soon.
Reference: Bug 1800995 - Content scripts not injected into new blank tab page (which is no longer about:blank)