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

Unified Diff: content/renderer/render_frame_impl.cc

Issue 2785583003: Remove redundant WebLocalFrame* parameter from didCreateDocumentElement (Closed)
Patch Set: 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
« no previous file with comments | « content/renderer/render_frame_impl.h ('k') | third_party/WebKit/Source/web/LocalFrameClientImpl.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: content/renderer/render_frame_impl.cc
diff --git a/content/renderer/render_frame_impl.cc b/content/renderer/render_frame_impl.cc
index 679773f82aca83ced3397903a82c2e4dd7c899e6..c7e905dafe8b433a1e6afbd69473094bd75be1b1 100644
--- a/content/renderer/render_frame_impl.cc
+++ b/content/renderer/render_frame_impl.cc
@@ -3816,16 +3816,14 @@ void RenderFrameImpl::didClearWindowObject(blink::WebLocalFrame* frame) {
observer.DidClearWindowObject();
}
-void RenderFrameImpl::didCreateDocumentElement(blink::WebLocalFrame* frame) {
- DCHECK(!frame_ || frame_ == frame);
-
+void RenderFrameImpl::didCreateDocumentElement() {
// Notify the browser about non-blank documents loading in the top frame.
- GURL url = frame->document().url();
+ GURL url = frame_->document().url();
if (url.is_valid() && url.spec() != url::kAboutBlankURL) {
// TODO(nasko): Check if webview()->mainFrame() is the same as the
- // frame->tree()->top().
+ // frame_->tree()->top().
blink::WebFrame* main_frame = render_view_->webview()->mainFrame();
- if (frame == main_frame) {
+ if (frame_ == main_frame) {
// For now, don't remember plugin zoom values. We don't want to mix them
// with normal web content (i.e. a fixed layout plugin would usually want
// them different).
@@ -3838,7 +3836,7 @@ void RenderFrameImpl::didCreateDocumentElement(blink::WebLocalFrame* frame) {
for (auto& observer : observers_)
observer.DidCreateDocumentElement();
for (auto& observer : render_view_->observers())
- observer.DidCreateDocumentElement(frame);
+ observer.DidCreateDocumentElement(frame_);
}
void RenderFrameImpl::runScriptsAtDocumentElementAvailable(
« no previous file with comments | « content/renderer/render_frame_impl.h ('k') | third_party/WebKit/Source/web/LocalFrameClientImpl.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698