I have been browsing around to find a way to disable closing Firefox 7 tab using ctrl+F4
.
Kind of hard to find an easy way to do it. Lock down browser security will help me using Firefox as a kiosk during the Linux Day event.
相关问题
- “Zero out” sensitive String data in Swift
- High cost encryption but less cost decryption
- TestCafe - The browser always starts in clean slat
- UrlEncodeUnicode and browser navigation errors
- How to restrict VOB read access in ClearCase (Wind
相关文章
Have you seen the keyconfig addon?
Or, more directly kiosk-related: R-kiosk
In your Firefox address bar type about:config and hit enter you will be shown the warning to proceed with care, then look for the properties like
browser.tabs.warnOnClose
,browser.tabs.closeButtons
,browser.tabs.closeWindowWithLastTab
.You need to modify the binary values or change the boolean values from true to false or vice versa. If you don't have such entries, create them with
right-click > New > Boolean
.PS: Please proceed with care.
Curious, I've never known CTRL+F4 is able to close the tab.
I've investigated the case a bit. I've tried disabling it in Keyconfig, but without success. The shortcut is not even listed there. When you try to add other shortcut to CTRL+F4 to override the default behavior, it still closes the tab.
Note that also CTRL+W is able to close the tab, but in this case you can disable it in Keyconfig.
Seems that CTRL+W and CTRL+F4 are handled different way therefore.
About CTRL+F4, I was able to find the following code:
http://dxr.mozilla.org/mozilla-central/browser/base/content/tabbrowser.xml.html, #else in line 2437:
I'm new to Mozilla code base, so I don't know where to search for CTRL+W however. But it seems CTRL+F4 is hardcoded at compile time for Windows and Linux and not easily (or at all) configurable.
You can think of reporting a bug to Bugzilla but I don't know if this would get top-priority treatment.