| Index: chrome/browser/chrome_content_browser_client.cc
|
| diff --git a/chrome/browser/chrome_content_browser_client.cc b/chrome/browser/chrome_content_browser_client.cc
|
| index 4b32ccd72b7fbaf54ff7ef30a70acde1d39f041f..edc5f8243bf9f2474a500e6ea1c36563e5347800 100644
|
| --- a/chrome/browser/chrome_content_browser_client.cc
|
| +++ b/chrome/browser/chrome_content_browser_client.cc
|
| @@ -1902,10 +1902,11 @@ bool ChromeContentBrowserClient::AllowWorkerDatabase(
|
| return allow;
|
| }
|
|
|
| -bool ChromeContentBrowserClient::AllowWorkerFileSystem(
|
| +void ChromeContentBrowserClient::RequestWorkerFileSystemAccessSync(
|
| const GURL& url,
|
| content::ResourceContext* context,
|
| - const std::vector<std::pair<int, int> >& render_frames) {
|
| + const std::vector<std::pair<int, int> >& render_frames,
|
| + base::Callback<void(bool)> callback) {
|
| DCHECK(BrowserThread::CurrentlyOn(BrowserThread::IO));
|
| ProfileIOData* io_data = ProfileIOData::FromResourceContext(context);
|
| CookieSettings* cookie_settings = io_data->GetCookieSettings();
|
| @@ -1914,13 +1915,31 @@ bool ChromeContentBrowserClient::AllowWorkerFileSystem(
|
| // Record access to file system for potential display in UI.
|
| std::vector<std::pair<int, int> >::const_iterator i;
|
| for (i = render_frames.begin(); i != render_frames.end(); ++i) {
|
| +#if defined(ENABLE_EXTENSIONS)
|
| + bool is_web_view_guest =
|
| + ExtensionRendererState::GetInstance()->IsWebViewRenderer(i->first);
|
| + if (is_web_view_guest) {
|
| + BrowserThread::PostTask(BrowserThread::UI,
|
| + FROM_HERE,
|
| + base::Bind(&WebViewGuest::FileSystemAccessedSync,
|
| + i->first,
|
| + i->second,
|
| + url,
|
| + !allow,
|
| + callback));
|
| + continue;
|
| + }
|
| +#endif
|
| + callback.Run(allow);
|
| BrowserThread::PostTask(
|
| - BrowserThread::UI, FROM_HERE,
|
| + BrowserThread::UI,
|
| + FROM_HERE,
|
| base::Bind(&TabSpecificContentSettings::FileSystemAccessed,
|
| - i->first, i->second, url, !allow));
|
| + i->first,
|
| + i->second,
|
| + url,
|
| + !allow));
|
| }
|
| -
|
| - return allow;
|
| }
|
|
|
| bool ChromeContentBrowserClient::AllowWorkerIndexedDB(
|
|
|