Stop using lambdas for WebResourceLoadStatisticsStore to interact with its WebsiteDat...
authorcdumez@apple.com <cdumez@apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Fri, 29 Jun 2018 16:54:05 +0000 (16:54 +0000)
committercdumez@apple.com <cdumez@apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Fri, 29 Jun 2018 16:54:05 +0000 (16:54 +0000)
commit7c5af86d2d83b539b842a9847a37132681bf6283
tree8402cf8ece7406a184303a4b47bb03bbe6339f6a
parent848fe61dd52d360209617fe5c6167850b17a2e51
Stop using lambdas for WebResourceLoadStatisticsStore to interact with its WebsiteDataStore
https://bugs.webkit.org/show_bug.cgi?id=187165

Reviewed by Brent Fulgham.

Stop using lambdas for WebResourceLoadStatisticsStore to interact with its WebsiteDataStore. Instead,
WebResourceLoadStatisticsStore now holds a weak pointer to its WebsiteDataStore and is able to call
methods on it directly. Reducing the indirection makes the code less complex and more understandable.

* UIProcess/WebResourceLoadStatisticsStore.cpp:
(WebKit::WebResourceLoadStatisticsStore::WebResourceLoadStatisticsStore):
(WebKit::WebResourceLoadStatisticsStore::callHasStorageAccessForFrameHandler):
(WebKit::WebResourceLoadStatisticsStore::callGrantStorageAccessHandler):
(WebKit::WebResourceLoadStatisticsStore::removeAllStorageAccess):
(WebKit::WebResourceLoadStatisticsStore::callUpdatePrevalentDomainsToPartitionOrBlockCookiesHandler):
(WebKit::WebResourceLoadStatisticsStore::callRemoveDomainsHandler):
* UIProcess/WebResourceLoadStatisticsStore.h:
* UIProcess/WebsiteData/WebsiteDataStore.cpp:
(WebKit::WebsiteDataStore::enableResourceLoadStatisticsAndSetTestingCallback):

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@233359 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Source/WebKit/ChangeLog
Source/WebKit/UIProcess/WebResourceLoadStatisticsStore.cpp
Source/WebKit/UIProcess/WebResourceLoadStatisticsStore.h
Source/WebKit/UIProcess/WebsiteData/WebsiteDataStore.cpp
Source/WebKit/UIProcess/WebsiteData/WebsiteDataStore.h