Index: third_party/WebKit/Source/core/loader/FrameLoader.cpp |
diff --git a/third_party/WebKit/Source/core/loader/FrameLoader.cpp b/third_party/WebKit/Source/core/loader/FrameLoader.cpp |
index 8e001981251379fc0a86ea15d51e8c2a2fb9457d..ea456890d092e95c75287d73ad1b83d8c8fd1694 100644 |
--- a/third_party/WebKit/Source/core/loader/FrameLoader.cpp |
+++ b/third_party/WebKit/Source/core/loader/FrameLoader.cpp |
@@ -50,6 +50,7 @@ |
#include "core/events/KeyboardEvent.h" |
#include "core/events/MouseEvent.h" |
#include "core/events/PageTransitionEvent.h" |
+#include "core/frame/ContentSettingsClient.h" |
#include "core/frame/FrameView.h" |
#include "core/frame/LocalDOMWindow.h" |
#include "core/frame/LocalFrame.h" |
@@ -676,13 +677,13 @@ void FrameLoader::setOpener(LocalFrame* opener) { |
bool FrameLoader::allowPlugins(ReasonForCallingAllowPlugins reason) { |
// With Oilpan, a FrameLoader might be accessed after the Page has been |
// detached. FrameClient will not be accessible, so bail early. |
- if (!client()) |
+ if (!client() || !m_frame->contentSettingsClient()) |
dcheng
2017/04/02 05:26:19
Similarly, I think we ideally shouldn't need to nu
kinuko
2017/04/03 15:15:06
Done.
|
return false; |
Settings* settings = m_frame->settings(); |
- bool allowed = |
- client()->allowPlugins(settings && settings->getPluginsEnabled()); |
+ bool allowed = m_frame->contentSettingsClient()->allowPlugins( |
+ settings && settings->getPluginsEnabled()); |
if (!allowed && reason == AboutToInstantiatePlugin) |
- client()->didNotAllowPlugins(); |
+ m_frame->contentSettingsClient()->didNotAllowPlugins(); |
return allowed; |
} |