mirror of https://github.com/electron/electron
47 lines
1.9 KiB
Diff
47 lines
1.9 KiB
Diff
From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
|
|
From: deepak1556 <hop2deep@gmail.com>
|
|
Date: Tue, 15 Nov 2022 21:45:28 +0900
|
|
Subject: chore: introduce blocking api for //electron
|
|
|
|
This patch comes after Chromium removed the ScopedAllowIO API in favor
|
|
of explicitly adding ScopedAllowBlocking calls as friends.
|
|
|
|
diff --git a/base/threading/thread_restrictions.h b/base/threading/thread_restrictions.h
|
|
index 8447e22c20399dc754ee1815529b5d95e65b58be..de93ff999f9aa7035e47dde44c2fff79586eec9a 100644
|
|
--- a/base/threading/thread_restrictions.h
|
|
+++ b/base/threading/thread_restrictions.h
|
|
@@ -136,6 +136,7 @@ class KeyStorageLinux;
|
|
class NativeBackendKWallet;
|
|
class NativeDesktopMediaList;
|
|
class PartnerBookmarksReader;
|
|
+class ProcessSingleton;
|
|
class Profile;
|
|
class ProfileImpl;
|
|
class ScopedAllowBlockingForProfile;
|
|
@@ -277,6 +278,9 @@ class BackendImpl;
|
|
class InFlightIO;
|
|
bool CleanupDirectorySync(const base::FilePath&);
|
|
} // namespace disk_cache
|
|
+namespace electron {
|
|
+class ScopedAllowBlockingForElectron;
|
|
+} // namespace electron
|
|
namespace enterprise_connectors {
|
|
class LinuxKeyRotationCommand;
|
|
} // namespace enterprise_connectors
|
|
@@ -579,6 +583,7 @@ class BASE_EXPORT [[maybe_unused, nodiscard]] ScopedAllowBlocking {
|
|
friend class ::DesktopNotificationBalloon;
|
|
friend class ::FirefoxProfileLock;
|
|
friend class ::GaiaConfig;
|
|
+ friend class ::ProcessSingleton;
|
|
friend class ::ProfileImpl;
|
|
friend class ::ScopedAllowBlockingForProfile;
|
|
friend class ::StartupTabProviderImpl;
|
|
@@ -619,6 +624,7 @@ class BASE_EXPORT [[maybe_unused, nodiscard]] ScopedAllowBlocking {
|
|
friend class crosapi::LacrosThreadTypeDelegate;
|
|
friend class crypto::ScopedAllowBlockingForNSS; // http://crbug.com/59847
|
|
friend class drive::FakeDriveService;
|
|
+ friend class electron::ScopedAllowBlockingForElectron;
|
|
friend class extensions::InstalledLoader;
|
|
friend class extensions::UnpackedInstaller;
|
|
friend class font_service::internal::MappedFontFile;
|