keyboard shortcut to restart firefox? [Mac]
-
- Posts: 244
- Joined: September 17th, 2003, 12:07 pm
- smsmith
- Moderator
- Posts: 19979
- Joined: December 7th, 2004, 8:51 pm
- Location: Indiana
Re: keyboard shortcut to restart firefox? [Mac]
I don't believe there is a built in restart keyboard shortcut, but you can use this extension to do that:
https://addons.mozilla.org/en-US/firefo ... /re-start/
The extension may no longer work in Fx 57, though.
https://addons.mozilla.org/en-US/firefo ... /re-start/
The extension may no longer work in Fx 57, though.
Give a man a fish, and he eats for a day. Teach a man to fish, and he eats for a lifetime.
I like poetry, long walks on the beach and poking dead things with a stick.
Please do not PM me for personal support. Keep posts here in the Forums instead and we all learn.
I like poetry, long walks on the beach and poking dead things with a stick.
Please do not PM me for personal support. Keep posts here in the Forums instead and we all learn.
-
- Posts: 6406
- Joined: February 3rd, 2009, 6:29 pm
Re: keyboard shortcut to restart firefox? [Mac]
You can show a restart button in the Add-ons Manager with a css tweak in Fx 57.
http://kb.mozillazine.org/UserContent.css
Edit:
The header-small.png image isn't available in Fx 58. (fix below)
Code: Select all
/* Firefox userContent.css */
@-moz-document url-prefix("chrome://mozapps/content/extensions/extensions.xul"), url-prefix("about:addons") {
#updates-restart-btn {
display: -moz-box !important;
}
#updates-restart-btn .button-icon {
list-style-image: url("chrome://browser/skin/panic-panel/header-small.png") !important;
}
#updates-restart-btn .button-text {
display: none !important;
}
}
Edit:
The header-small.png image isn't available in Fx 58. (fix below)
Last edited by morat on November 20th, 2017, 11:25 pm, edited 1 time in total.
- dickvl
- Posts: 54147
- Joined: July 18th, 2005, 3:25 am
Re: keyboard shortcut to restart firefox? [Mac]
I usually have the developer toolbar visible and type 'restart' (rest: autocomplete with the tab key) to restart.
-
- Posts: 244
- Joined: September 17th, 2003, 12:07 pm
Re: keyboard shortcut to restart firefox? [Mac]
Thanks.
Out of curiosity, what function does the restart button call? Is there any way to map that function to a hotkey in macOS preferences > Keyboard > Shortcuts?
Out of curiosity, what function does the restart button call? Is there any way to map that function to a hotkey in macOS preferences > Keyboard > Shortcuts?
-
- Posts: 6406
- Joined: February 3rd, 2009, 6:29 pm
Re: keyboard shortcut to restart firefox? [Mac]
The restart button calls an internal command that's only valid when the Add-ons Manger tab is selected.
Mac OS doesn't have access to internal commands.
I don't know how you would politely close a process on the Mac OS.
Windows OS
http://nircmd.nirsoft.net/closeprocess.html
http://nircmd.nirsoft.net/killprocess.html
Code: Select all
goDoCommand("cmd_restartApp");
I don't know how you would politely close a process on the Mac OS.
Windows OS
http://nircmd.nirsoft.net/closeprocess.html
http://nircmd.nirsoft.net/killprocess.html
- RobertJ
- Moderator
- Posts: 10880
- Joined: October 15th, 2003, 7:40 pm
- Location: Chicago IL/Oconomowoc WI
Re: keyboard shortcut to restart firefox? [Mac]
.
You could write a simple AppleScript to shut down FF and then restart it. You could then use Automator to assign that AppleScript to a keyboard shortcut. BEWARE: on Mac all keyboard shortcuts are global so what ever you select must be unique.
.
You could write a simple AppleScript to shut down FF and then restart it. You could then use Automator to assign that AppleScript to a keyboard shortcut. BEWARE: on Mac all keyboard shortcuts are global so what ever you select must be unique.
.
FF 92.0 - TB 78.13 - Mac OSX 10.13.6
-
- Posts: 244
- Joined: September 17th, 2003, 12:07 pm
Re: keyboard shortcut to restart firefox? [Mac]
morat: you can kill processes from terminal or activity monitor (which is sort of like task manager in Windows or whatever it's called)
RobertJ: oh ya, right. Forgot about that. Thanks.
RobertJ: oh ya, right. Forgot about that. Thanks.
-
- Posts: 244
- Joined: September 17th, 2003, 12:07 pm
Re: keyboard shortcut to restart firefox? [Mac]
check it, I made a stupid simple applescript app tell application "firefox" to quit, delay, tell application Firefox to open. I have BetterTouchTool, created a firefox specific shortcut to open the script app with cmd-shift-q. I mean... just. Great.
- dickvl
- Posts: 54147
- Joined: July 18th, 2005, 3:25 am
Re: keyboard shortcut to restart firefox? [Mac]
Keep in mind that it can take unknown time for Firefox to close properly.
When you use builtin means to restart then it is known when Firefox has closed and Firefox is restarted properly in all cases and currently open tabs will reloaded (browser.sessionstore.resume_session_once = true).
If you use an external script then you would have to guess how long you need to wait before starting Firefox.
Otherwise you will get the alert dialog that Firefox is already running.
When you use builtin means to restart then it is known when Firefox has closed and Firefox is restarted properly in all cases and currently open tabs will reloaded (browser.sessionstore.resume_session_once = true).
If you use an external script then you would have to guess how long you need to wait before starting Firefox.
Otherwise you will get the alert dialog that Firefox is already running.
-
- Posts: 244
- Joined: September 17th, 2003, 12:07 pm
Re: keyboard shortcut to restart firefox? [Mac]
On macOS, I don't think that's a problem. I've never seen a "firefox is already running" msg, or any other app for that matter. If I do, I'll increase the delay but right now it's at 1 second with no problems whatsoever. But even if I try to click on the firefox dock icon as it's quitting just nothing happens. Actually it automatically starts up again after it's quit. So I don't think it's possible to start up an app again before it's fully quit on macOS.
- therube
- Posts: 21703
- Joined: March 10th, 2004, 9:59 pm
- Location: Maryland USA
Re: keyboard shortcut to restart firefox? [Mac]
(
)
kill -9I don't know how you would politely close a process on the Mac OS.
)
Fire 750, bring back 250.
Mozilla/5.0 (Windows; U; Windows NT 6.1; en-US; rv:1.9.1.19) Gecko/20110420 SeaMonkey/2.0.14 Pinball CopyURL+ FetchTextURL FlashGot NoScript
Mozilla/5.0 (Windows; U; Windows NT 6.1; en-US; rv:1.9.1.19) Gecko/20110420 SeaMonkey/2.0.14 Pinball CopyURL+ FetchTextURL FlashGot NoScript
-
- Posts: 250
- Joined: January 29th, 2016, 4:36 pm
Re: keyboard shortcut to restart firefox? [Mac]
Hi, unfortunately morat's code no longer works on 58 beta or 59 nightly Can it be revived?
Edit: I haven't updated to 57 yet, so can't say if it still works there.
Edit: I haven't updated to 57 yet, so can't say if it still works there.
-
- Posts: 6406
- Joined: February 3rd, 2009, 6:29 pm
Re: keyboard shortcut to restart firefox? [Mac]
It succeeds in Fx 57. It fails in Fx 58. The header-small.png image isn't available in Fx 58.
Try this:
http://dxr.mozilla.org/mozilla-release/ ... nsions.xul
http://dxr.mozilla.org/mozilla-release/ ... -small.png
http://dxr.mozilla.org/mozilla-release/ ... ersion.txt
http://dxr.mozilla.org/mozilla-beta/sea ... nsions.xul
http://dxr.mozilla.org/mozilla-beta/sea ... -small.png
http://dxr.mozilla.org/mozilla-beta/sou ... ersion.txt
Try this:
Code: Select all
/* Firefox userContent.css */
@-moz-document url-prefix("about:addons"),
url-prefix("chrome://mozapps/content/extensions/extensions.xul") {
#updates-restart-btn {
display: -moz-box !important;
}
#updates-restart-btn .button-icon {
/* list-style-image: url("chrome://browser/skin/panic-panel/header-small.png") !important; */
/* list-style-image: url("chrome://browser/content/abouthome/restore.png") !important; */
list-style-image: url("chrome://branding/content/icon32.png") !important;
}
#updates-restart-btn .button-text {
display: none !important;
}
}
http://dxr.mozilla.org/mozilla-release/ ... -small.png
http://dxr.mozilla.org/mozilla-release/ ... ersion.txt
http://dxr.mozilla.org/mozilla-beta/sea ... nsions.xul
http://dxr.mozilla.org/mozilla-beta/sea ... -small.png
http://dxr.mozilla.org/mozilla-beta/sou ... ersion.txt
-
- Posts: 250
- Joined: January 29th, 2016, 4:36 pm
Re: keyboard shortcut to restart firefox? [Mac]
Works! Thanks much, morat.