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

Unified Diff: content/renderer/render_frame_impl.cc

Issue 2928033002: Move GetDocument method from WebFrame to WebLocalFrame. (Closed)
Patch Set: Split a DCHECK in two as suggested by boliu@. Created 3 years, 6 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/pepper/url_request_info_util.cc ('k') | content/renderer/render_view_impl.cc » ('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 e3ff259c1fa4825a715ea59aed41a580aef738a4..29d8b73e907d271a5c658cfdd8fd1562d479d3f9 100644
--- a/content/renderer/render_frame_impl.cc
+++ b/content/renderer/render_frame_impl.cc
@@ -4,6 +4,7 @@
#include "content/renderer/render_frame_impl.h"
+#include <algorithm>
#include <map>
#include <string>
#include <utility>
@@ -2898,9 +2899,9 @@ RenderFrameImpl::CreateApplicationCacheHost(
std::unique_ptr<blink::WebContentSettingsClient>
RenderFrameImpl::CreateWorkerContentSettingsClient() {
if (!frame_ || !frame_->View())
- return NULL;
+ return nullptr;
return GetContentClient()->renderer()->CreateWorkerContentSettingsClient(
- this, frame_);
+ this);
}
std::unique_ptr<blink::WebWorkerFetchContext>
@@ -3763,7 +3764,7 @@ void RenderFrameImpl::DidCreateDocumentElement(blink::WebLocalFrame* frame) {
// them different).
render_view_->Send(new ViewHostMsg_DocumentAvailableInMainFrame(
render_view_->GetRoutingID(),
- main_frame->GetDocument().IsPluginDocument()));
+ frame->GetDocument().IsPluginDocument()));
}
}
@@ -4909,6 +4910,7 @@ void RenderFrameImpl::SendDidCommitProvisionalLoad(
if (render_view_->webview()->MainFrame()->IsWebLocalFrame() &&
render_view_->webview()
->MainFrame()
+ ->ToWebLocalFrame()
->GetDocument()
.IsPluginDocument()) {
// Reset the zoom levels for plugins.
@@ -6751,7 +6753,7 @@ void RenderFrameImpl::SendFindReply(int request_id,
int ordinal,
const WebRect& selection_rect,
bool final_status_update) {
- DCHECK(ordinal >= -1);
+ DCHECK_GE(ordinal, -1);
Send(new FrameHostMsg_Find_Reply(routing_id_,
request_id,
« no previous file with comments | « content/renderer/pepper/url_request_info_util.cc ('k') | content/renderer/render_view_impl.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698