This previously prescribed solution:
https://support.mozilla.org/en-US/questions/1116486
to remove the "Set Image as Desktop Background" and "Email Image" from the context menu items no longer functions in v89.
Anyone know of a solution that will work going forward?
Without having to resort to a policy file?
[v89] Remove context menu image-related items?[Mac.]
-
- Posts: 144
- Joined: April 26th, 2009, 1:36 am
[v89] Remove context menu image-related items?[Mac.]
Last edited by LIMPET235 on June 4th, 2021, 5:36 am, edited 1 time in total.
Reason: Added [Mac] to the Title.
Reason: Added [Mac] to the Title.
-
- Posts: 6421
- Joined: February 3rd, 2009, 6:29 pm
Re: [v89] Remove context menu image-related items?
Try this:
http://kb.mozillazine.org/UserChrome.css
Remember to set the toolkit.legacyUserProfileCustomizations.stylesheets preference to true, then restart.
P.S.
The ids didn't change in Fx 89.
Reference
http://searchfox.org/mozilla-release/se ... egexp=true
http://searchfox.org/mozilla-release/so ... ersion.txt
Code: Select all
/* Firefox userChrome.css */
@namespace url("http://www.mozilla.org/keymaster/gatekeeper/there.is.only.xul");
#context-sendimage,
#context-sep-setbackground,
#context-setDesktopBackground {
display: none !important;
}
Remember to set the toolkit.legacyUserProfileCustomizations.stylesheets preference to true, then restart.
P.S.
The ids didn't change in Fx 89.
Reference
http://searchfox.org/mozilla-release/se ... egexp=true
http://searchfox.org/mozilla-release/so ... ersion.txt
-
- Posts: 144
- Joined: April 26th, 2009, 1:36 am
Re: [v89] Remove context menu image-related items?
Thanks, but it didn't work.
I've been using that code, minus the separator line, in the same userchrome file, for many versions of Fx and it has been effective up until now.
I have one extension that modifies the context menu to provide search options, but disabling it made no difference.
Nor did disabling all extensions and running in that mode.
I've made other changes in the file, to tweak other elements new to v89, and they work as expected, so it's not an issue of the userchrome file not being read and functional.
I've been using that code, minus the separator line, in the same userchrome file, for many versions of Fx and it has been effective up until now.
I have one extension that modifies the context menu to provide search options, but disabling it made no difference.
Nor did disabling all extensions and running in that mode.
I've made other changes in the file, to tweak other elements new to v89, and they work as expected, so it's not an issue of the userchrome file not being read and functional.
-
- Posts: 6421
- Joined: February 3rd, 2009, 6:29 pm
Re: [v89] Remove context menu image-related items?
I don't know what's wrong.
Troubleshoot userChrome.css
http://forums.mozillazine.org/viewtopic ... #p14887480
Troubleshoot userChrome.css
http://forums.mozillazine.org/viewtopic ... #p14887480
- dickvl
- Posts: 54161
- Joined: July 18th, 2005, 3:25 am
Re: [v89] Remove context menu image-related items?
Maybe post your full userChrome.css so we can check for issues.
You can also try to move the new code to the top of the file.
You can also try to move the new code to the top of the file.
-
- Posts: 144
- Joined: April 26th, 2009, 1:36 am
Re: [v89] Remove context menu image-related items?
Alright, I tried moving the specific code to be first in the file. Also removing the commenting remarks. No joy.
Here's the file in its entirety. As you can see, it's not complex. I've even left the remarks at the top intact, from whenever it was that Fx generated the file on its own automatically, a long time ago.
The other two mods, the persistent tab close buttons, and the tab bar background color (just added for v89), do work. Only the context menu item does not.
Disabling extensions, and restarting in safe mode. No joy. Puzzling.
Here's the file in its entirety. As you can see, it's not complex. I've even left the remarks at the top intact, from whenever it was that Fx generated the file on its own automatically, a long time ago.
The other two mods, the persistent tab close buttons, and the tab bar background color (just added for v89), do work. Only the context menu item does not.
Disabling extensions, and restarting in safe mode. No joy. Puzzling.
Code: Select all
/*
* Edit this file and copy it as userChrome.css into your
* profile-directory/chrome/
*/
/*
* This file can be used to customize the look of Mozilla's user interface
* You should consider using !important on rules which you want to
* override default settings.
*/
/*
* Do not remove the @namespace line -- it's required for correct functioning
*/
@namespace url("http://www.mozilla.org/keymaster/gatekeeper/there.is.only.xul"); /* set default namespace to XUL */
/* Always show close button */
.tab-close-button {
display: -moz-box !important;
}
/* Remove image options from context menu */
#context-sendimage,
#context-setDesktopBackground {
display: none !important;
}
/* Set Tab bar color to match window title bar */
#titlebar > toolbar{ background-color: #d8d8db !important; }
- Luna C
- Posts: 40
- Joined: June 9th, 2007, 11:36 am
Re: [v89] Remove context menu image-related items?[Mac.]
I'm having the same problem with the context menu items not being removed with userchrome.css, and am also on a Mac. The other changes work perfectly.
Is it a Mac thing?
Is it a Mac thing?
Code: Select all
/* * Do not remove the @namespace line — it’s required for correct functioning */
/* set default namespace to XUL */
@namespace url("http://www.mozilla.org/keymaster/gatekeeper/there.is.only.xul");
/******** HIDE STUFF *******/
/* Hide context menu items */
#context-back,
#context-forward,
#context-reload,
#context-stop,
#context-sep-stop
{display: none !important;}
/* Make tab close show only on hover */
.tab-close-button {visibility: collapse !important;}
.tabbrowser-tab:hover .tab-close-button {color: #6E6E6E !important; visibility: visible !important;}
/* Remove back button when nothing to go back to */
#back-button[disabled="true"] {display: none;}
#forward-button[disabled="true"] {display: none;}
/* Hide hamburger menu in toolbar */
#PanelUI-menu-button {display: none !important;}
-
- Posts: 6421
- Joined: February 3rd, 2009, 6:29 pm
Re: [v89] Remove context menu image-related items?[Mac.]
Try setting the widget.macos.native-context-menus pref to false, then restart.
Mac native context menus fail to honor CSS rules
http://bugzilla.mozilla.org/show_bug.cgi?id=1712734
Use native context menus on Mac
http://bugzilla.mozilla.org/show_bug.cgi?id=34572
For reading only as Bugzilla is not a forum.
Mac native context menus fail to honor CSS rules
http://bugzilla.mozilla.org/show_bug.cgi?id=1712734
Use native context menus on Mac
http://bugzilla.mozilla.org/show_bug.cgi?id=34572
For reading only as Bugzilla is not a forum.
- Luna C
- Posts: 40
- Joined: June 9th, 2007, 11:36 am
Re: [v89] Remove context menu image-related items?[Mac.]
That worked, thank you very much!
-
- Posts: 144
- Joined: April 26th, 2009, 1:36 am
Re: [v89] Remove context menu image-related items?[Mac.]
Hallelujah. Thanks, that worked. I should have known better and searched for a bug.morat wrote:Try setting the widget.macos.native-context-menus pref to false, then restart.
Mac native context menus fail to honor CSS rules
http://bugzilla.mozilla.org/show_bug.cgi?id=1712734
Use native context menus on Mac
http://bugzilla.mozilla.org/show_bug.cgi?id=34572
For reading only as Bugzilla is not a forum.
Additional thanks for posting the searchfox link. Using it to determine the IDs. I took the opportunity to remove additional items as well, and further tidy up the context menu to my liking.