feat: Electron Fuses, package time feature toggles (#24241)
* feat: add new 'fuses' feature for package-time build-flag style feature control * feat: put ENABLE_RUN_AS_NODE behind a fuse as well * chore: address PR feedback * build: move FUSE_EXPORT to headers * build: use hex codes for kFuseWire char[] * docs: add fuse wire documentation * chore: update fuses.json info * Apply suggestions from code review Co-authored-by: Jeremy Rose <jeremya@chromium.org> * chore: add link to fuse schema * Update shell/app/electron_library_main.mm Co-authored-by: Jeremy Rose <jeremya@chromium.org> Co-authored-by: Jeremy Rose <jeremya@chromium.org>
This commit is contained in:
parent
422190e1ff
commit
dbf2931f0e
8 changed files with 195 additions and 5 deletions
|
@ -3,6 +3,7 @@
|
|||
// found in the LICENSE file.
|
||||
|
||||
#include "electron/buildflags/buildflags.h"
|
||||
#include "electron/fuses.h"
|
||||
#include "printing/buildflags/buildflags.h"
|
||||
#include "shell/common/gin_helper/dictionary.h"
|
||||
#include "shell/common/node_includes.h"
|
||||
|
@ -30,7 +31,7 @@ bool IsPDFViewerEnabled() {
|
|||
}
|
||||
|
||||
bool IsRunAsNodeEnabled() {
|
||||
return BUILDFLAG(ENABLE_RUN_AS_NODE);
|
||||
return electron::fuses::IsRunAsNodeEnabled() && BUILDFLAG(ENABLE_RUN_AS_NODE);
|
||||
}
|
||||
|
||||
bool IsFakeLocationProviderEnabled() {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue