mirror of
https://bitbucket.org/chromiumembedded/cef
synced 2025-06-05 21:39:12 +02:00
Call OnBeforePluginLoad when building the plugin list (issue #1708)
This commit is contained in:
@ -9,8 +9,10 @@
|
||||
#include "libcef/browser/context.h"
|
||||
#include "libcef/browser/cookie_manager_impl.h"
|
||||
#include "libcef/browser/thread_util.h"
|
||||
|
||||
#include "base/atomic_sequence_num.h"
|
||||
#include "base/logging.h"
|
||||
#include "content/public/browser/plugin_service.h"
|
||||
|
||||
using content::BrowserThread;
|
||||
|
||||
@ -283,6 +285,13 @@ bool CefRequestContextImpl::ClearSchemeHandlerFactories() {
|
||||
return true;
|
||||
}
|
||||
|
||||
void CefRequestContextImpl::PurgePluginListCache(bool reload_pages) {
|
||||
GetBrowserContext(
|
||||
BrowserThread::GetMessageLoopProxyForThread(BrowserThread::UI),
|
||||
base::Bind(&CefRequestContextImpl::PurgePluginListCacheInternal,
|
||||
this, reload_pages));
|
||||
}
|
||||
|
||||
CefRequestContextImpl::CefRequestContextImpl(
|
||||
scoped_refptr<CefBrowserContext> browser_context)
|
||||
: browser_context_(browser_context),
|
||||
@ -375,3 +384,11 @@ void CefRequestContextImpl::ClearSchemeHandlerFactoriesInternal(
|
||||
CEF_REQUIRE_IOT();
|
||||
request_context->request_manager()->ClearFactories();
|
||||
}
|
||||
|
||||
void CefRequestContextImpl::PurgePluginListCacheInternal(
|
||||
bool reload_pages,
|
||||
scoped_refptr<CefBrowserContext> browser_context) {
|
||||
CEF_REQUIRE_UIT();
|
||||
content::PluginService::GetInstance()->PurgePluginListCache(
|
||||
browser_context.get(), false);
|
||||
}
|
||||
|
Reference in New Issue
Block a user