Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(2267)

Unified Diff: third_party/WebKit/Source/core/frame/LocalFrame.cpp

Issue 2702273004: bindings: Simplifies WindowProxyManager and its relation to Frame. (Closed)
Patch Set: Fixed WindowProxyManager::createWindowProxy(ForFrame). Created 3 years, 9 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: third_party/WebKit/Source/core/frame/LocalFrame.cpp
diff --git a/third_party/WebKit/Source/core/frame/LocalFrame.cpp b/third_party/WebKit/Source/core/frame/LocalFrame.cpp
index b1078389d3088be10d04a4ee1593717084f80ade..d8be255be3c8acc64e610ddc61a37d06015ed9a8 100644
--- a/third_party/WebKit/Source/core/frame/LocalFrame.cpp
+++ b/third_party/WebKit/Source/core/frame/LocalFrame.cpp
@@ -361,10 +361,6 @@ DEFINE_TRACE(LocalFrame) {
Supplementable<LocalFrame>::trace(visitor);
}
-WindowProxy* LocalFrame::windowProxy(DOMWrapperWorld& world) {
- return m_script->windowProxy(world);
-}
-
void LocalFrame::navigate(Document& originDocument,
const KURL& url,
bool replaceCurrentItem,
@@ -493,10 +489,6 @@ void LocalFrame::printNavigationWarning(const String& message) {
ConsoleMessage::create(JSMessageSource, WarningMessageLevel, message));
}
-WindowProxyManagerBase* LocalFrame::getWindowProxyManager() const {
- return m_script->getWindowProxyManager();
-}
-
bool LocalFrame::shouldClose() {
// TODO(dcheng): This should be fixed to dispatch beforeunload events to
// both local and remote frames.
@@ -855,12 +847,14 @@ inline LocalFrame::LocalFrame(LocalFrameClient* client,
FrameOwner* owner,
InterfaceProvider* interfaceProvider,
InterfaceRegistry* interfaceRegistry)
- : Frame(client, host, owner),
+ : Frame(client, host, owner, LocalWindowProxyManager::create(*this)),
m_frameScheduler(page()->chromeClient().createFrameScheduler(
client->frameBlameContext())),
m_loader(this),
m_navigationScheduler(NavigationScheduler::create(this)),
- m_script(ScriptController::create(this)),
+ m_script(ScriptController::create(
+ *this,
+ *static_cast<LocalWindowProxyManager*>(getWindowProxyManager()))),
m_editor(Editor::create(*this)),
m_spellChecker(SpellChecker::create(*this)),
m_selection(FrameSelection::create(*this)),

Powered by Google App Engine
This is Rietveld 408576698