* fix: disable remote host nodeIntegration warning for localhost
In warnAboutNodeWithRemoteContent(), add a check to see if the hostname
is "localhost" and prevent the warning message if it is.
* fix: disable loading insecure resources warning for localhost
In warnAboutInsecureResources(), filter out resources from localhost
since they are most likely not a threat.
* test: add tests for ignoring security warnings when using localhost
Add tests for ignoring warning messages for the following scenarios:
1. node integration with remote content from localhost
2. loading insecure resources from localhost
* test: fix insecure resource test
* test: pass nodeIntegration with remote test on did-finish-load
* test: maybe fix node integration test (error w/ conv circular struct)
* test: update test description
* test: use "load" event to check when nodeIntegration test has finished
Instead of relying on the "did-finish-load" event, which may result in
a race condition, add an "onload" handler that logs "loaded" to the
console. This will execute _after_ the nodeIntegration check, so it
can be safely used as a signal to indicate that the test is done.
* test: rename base-page-security-load-message.html
* fix: ignore enabled remote module warning for localhost
* refactor: add isLocalhost()
Resolves#18980.
Adds granularity to the optional callback in webContents.print() by adding a failureType value in addition to the success boolean that differentiates between cancelled and failed print jobs.
Fixes#18502
This PR changes the focus and blur events that we emit in Electron to listen to changes in key window rather than main window. It swaps out windowDidBecomeMain and windowDidResignMain for windowDidBecomeKey and windowDidResignKey, respectively.
* chore: small memory management improvement
Co-authored-by: Charles Kerr <ckerr@github.com>
* chore: fix code style
* use start-from-one ref count, check ref_counted.h for motivations
* reuse list_base_dir_
* net::DirectorLister offloads directory enumeration to a different
task sequence in its implementation, use of sequence runner on
our end is unnecessary
* Don't manually `Release` in `WebContentsDestroyed`, content::FileSelectListener
already handles this case.
Fixes#18808
Previously, the triggeredByAccelerator flag would be entirely coupled with whether or not the modifier keys were being used or not.
This PR swaps out the ui::EventFlagsFromModifiers([event modifierFlags])) call in the macOS code to ui::EventFlagsFromNSEventWithModifiers(event, [event modifierFlags])). The latter outputs flags that take into account mouse click events on top of modifier flags (see Chromium documentation).
The business logic to detect triggeredByAccelerator is then changed to exclude any mouse click flags.
* chore: use ScopedPumpMessagesInPrivateModes in tray
* revert refcounting of AtomMenuModel
* Prefer WeakPtr for posting tasks to handle unexpected destruction
* feat: show optional authors in gtk about panel
* chore: use a base::Value for about dialog options on Linux
* docs: mark 'version' as supported on Linux too
Wait for the focus event because checking focus status.
BrowserWindow.show gives focus to the window but there is
a moment where the window is shown but does not have the
focus yet. And the test was failing at this moment.
* build: move zip manifest logic in zip_manifests dir
* build: remove unused get-version.py script
* chore: move all release/sudowoodo related scripts into script/releases
* chore: update paths to zip manifests in CI configs
* build: fix path to ci release build script for arm tests