Firefox - Patches

Alt-Number Tab Switching

Add alt-number in additon to control-number for tab switching:
altnumbertab-current.patch

How to patch Firefox w/o rebuilding:

  1. change to <your_firefox_install_dir>/lib/chrome/
  2. cp browser.jar browser.jar.old
  3. mkdir foo
  4. cd foo
  5. unzip ../browser.jar
  6. cd content/browser/
  7. patch -p0 < ~/altnumbertab-current.patch (or do the instructions below)
  8. cd ../../
  9. zip -vr * ../browser.jar
  10. cd ..
  11. rm -rf foo
  12. start firefox, enjoy alt-{1-0} for tab switching...

The patch should apply, but if you have a different build of Firefox, it may not. In that case, it’s easy to make the changes; just find if (!event.ctrlKey) and change it to if (!(event.ctrlKey || event.altKey))

Note: On SUSE, <your_firefox_install_dir> is /opt/MozillaFirefox; on Red Hat (or other distros), it’s probably something entirely different, probably somewhere in /usr, like /usr/share/firefox...

Quit with Control-Q

The following patch, when applied, allows one to hit Control-Q for quitting Firefox: ctrlq_quit.patch

It should be applied wherever content/browser/browser.xul resides (like above, different places for Mozilla source vs. installed Firefox).

 
firefox/patches.txt · Last modified: 2006/09/19 15:10