Since I punted on full integration with torbutton in the sandboxed-tor-browser 0.0.3 release due to time constraints (and the relatively large patch that would be required), I opted for a simpler solution that will hopefully be acceptable for all torbutton branches.
If the TBB_SANDBOX env var is linux-v0, then the "Check for Tor Browser Update..." menu entry should be hidden.
To upload designs, you'll need to enable LFS and have an admin enable hashed storage. More information
Child items ...
Show closed items
Linked items 0
Link issues together to show that they're related.
Learn more.
This works, without the env var (existing behavior), with the env var set to what I set (relevant items hidden), and with the env var set to something I will set in the future (existing behavior again).
These changes look okay to me.
Do you expect to trigger other special behavior via the TOR_SANDBOX env variable? If not and if there is a chance that other people might want to hide this menu item as well, we should use a more specific env var name such as TOR_HIDE_UPDATE_CHECK_UI.
Eventually, I want to make the menu item work instead of hiding it, but since the sandbox is bundle version aware, having to do something different on my end isn't a big deal.
TOR_HIDE_UPDATE_CHECK_UI works for, and since other people want it (IIRC one of the patches in #20557 (moved) is to do something similar) that's probably better.
I'm on vacation (TM) this week, so feel free to change it in a branch, if not I'll do it this weekend or something, and someone could probably also close #20083 (moved) in favor of this, if we're going the env var route (Help->About Tor Browser's button gets disabled if you use autoconfig.js/mozilla.cfg, so I'm less worried about that now).
I changed the env var (and updated the sandbox code) as discussed. Setting it to 1 hides things, setting it to anything else, or omitting it leaves things visible.
In Torbutton, for similar env vars we just check for presence (e.g., for TOR_NO_DISPLAY_NETWORK_SETTINGS which is handled nearby). For consistency, Kathy and I think we should use the same approach for TOR_HIDE_UPDATE_CHECK_UI. Here is a revised patch: