Title: [262984] trunk/Source/WebKit
- Revision
- 262984
- Author
- [email protected]
- Date
- 2020-06-12 15:38:27 -0700 (Fri, 12 Jun 2020)
Log Message
[iOS] Preferences are not being observed if the process pool is being created after activation
https://bugs.webkit.org/show_bug.cgi?id=213145
Reviewed by Brent Fulgham.
If the app is creating the Web process pool after being activated, preferences will not be observed until the app is being backgrounded
and then foregrounded again, since the preference observer is initialized when handling the app activation notification.
No new tests, since an API test would make sense in this case, but API tests aren't run on iOS.
* UIProcess/Cocoa/WebProcessPoolCocoa.mm:
(WebKit::WebProcessPool::platformInitializeWebProcess):
Modified Paths
Diff
Modified: trunk/Source/WebKit/ChangeLog (262983 => 262984)
--- trunk/Source/WebKit/ChangeLog 2020-06-12 22:22:09 UTC (rev 262983)
+++ trunk/Source/WebKit/ChangeLog 2020-06-12 22:38:27 UTC (rev 262984)
@@ -1,3 +1,18 @@
+2020-06-12 Per Arne Vollan <[email protected]>
+
+ [iOS] Preferences are not being observed if the process pool is being created after activation
+ https://bugs.webkit.org/show_bug.cgi?id=213145
+
+ Reviewed by Brent Fulgham.
+
+ If the app is creating the Web process pool after being activated, preferences will not be observed until the app is being backgrounded
+ and then foregrounded again, since the preference observer is initialized when handling the app activation notification.
+
+ No new tests, since an API test would make sense in this case, but API tests aren't run on iOS.
+
+ * UIProcess/Cocoa/WebProcessPoolCocoa.mm:
+ (WebKit::WebProcessPool::platformInitializeWebProcess):
+
2020-06-12 Takashi Komori <[email protected]>
[Curl] Implement functions to use ResourceLoadStatistics.
Modified: trunk/Source/WebKit/UIProcess/Cocoa/WebProcessPoolCocoa.mm (262983 => 262984)
--- trunk/Source/WebKit/UIProcess/Cocoa/WebProcessPoolCocoa.mm 2020-06-12 22:22:09 UTC (rev 262983)
+++ trunk/Source/WebKit/UIProcess/Cocoa/WebProcessPoolCocoa.mm 2020-06-12 22:38:27 UTC (rev 262984)
@@ -466,6 +466,14 @@
if (!_MGCacheValid())
[adoptNS([[objc_getClass("MobileGestaltHelperProxy") alloc] init]) proxyRebuildCache];
#endif
+
+#if PLATFORM(IOS_FAMILY) && ENABLE(CFPREFS_DIRECT_MODE)
+ if ([UIApplication sharedApplication]) {
+ auto state = [[UIApplication sharedApplication] applicationState];
+ if (state == UIApplicationStateActive)
+ startObservingPreferenceChanges();
+ }
+#endif
}
void WebProcessPool::platformInitializeNetworkProcess(NetworkProcessCreationParameters& parameters)
_______________________________________________
webkit-changes mailing list
[email protected]
https://lists.webkit.org/mailman/listinfo/webkit-changes