fix: prevent navigator.fonts.query() from crashing (#30930)
* fix: prevent navigator.fonts.query() from crashing * refactor: use base::PostTask instead
This commit is contained in:
parent
9eaa9de3b4
commit
c8e4cc29c0
5 changed files with 82 additions and 0 deletions
|
@ -20,6 +20,7 @@
|
|||
#include "net/ssl/client_cert_identity.h"
|
||||
#include "services/metrics/public/cpp/ukm_source_id.h"
|
||||
#include "shell/browser/bluetooth/electron_bluetooth_delegate.h"
|
||||
#include "shell/browser/font/electron_font_access_delegate.h"
|
||||
#include "shell/browser/serial/electron_serial_delegate.h"
|
||||
#include "third_party/blink/public/mojom/badging/badging.mojom-forward.h"
|
||||
|
||||
|
@ -91,6 +92,8 @@ class ElectronBrowserClient : public content::ContentBrowserClient,
|
|||
|
||||
content::SerialDelegate* GetSerialDelegate() override;
|
||||
|
||||
content::FontAccessDelegate* GetFontAccessDelegate() override;
|
||||
|
||||
content::BluetoothDelegate* GetBluetoothDelegate() override;
|
||||
|
||||
device::GeolocationManager* GetGeolocationManager() override;
|
||||
|
@ -305,6 +308,7 @@ class ElectronBrowserClient : public content::ContentBrowserClient,
|
|||
|
||||
std::unique_ptr<ElectronSerialDelegate> serial_delegate_;
|
||||
std::unique_ptr<ElectronBluetoothDelegate> bluetooth_delegate_;
|
||||
std::unique_ptr<ElectronFontAccessDelegate> font_access_delegate_;
|
||||
|
||||
#if defined(OS_MAC)
|
||||
ElectronBrowserMainParts* browser_main_parts_ = nullptr;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue