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

Side by Side Diff: trunk/src/content/browser/renderer_host/render_view_host_impl.cc

Issue 208263008: Revert 258763 "Adds plumbing to pass WebUI mojo::Handle from bro..." (Closed) Base URL: svn://svn.chromium.org/chrome/
Patch Set: Created 6 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 unified diff | Download patch | Annotate | Revision Log
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "content/browser/renderer_host/render_view_host_impl.h" 5 #include "content/browser/renderer_host/render_view_host_impl.h"
6 6
7 #include <set> 7 #include <set>
8 #include <string> 8 #include <string>
9 #include <utility> 9 #include <utility>
10 #include <vector> 10 #include <vector>
(...skipping 717 matching lines...) Expand 10 before | Expand all | Expand 10 after
728 728
729 void RenderViewHostImpl::RequestFindMatchRects(int current_version) { 729 void RenderViewHostImpl::RequestFindMatchRects(int current_version) {
730 Send(new ViewMsg_FindMatchRects(GetRoutingID(), current_version)); 730 Send(new ViewMsg_FindMatchRects(GetRoutingID(), current_version));
731 } 731 }
732 732
733 void RenderViewHostImpl::DisableFullscreenEncryptedMediaPlayback() { 733 void RenderViewHostImpl::DisableFullscreenEncryptedMediaPlayback() {
734 media_player_manager_->DisableFullscreenEncryptedMediaPlayback(); 734 media_player_manager_->DisableFullscreenEncryptedMediaPlayback();
735 } 735 }
736 #endif 736 #endif
737 737
738 #if defined(USE_MOJO)
739 void RenderViewHostImpl::SetWebUIHandle(mojo::ScopedMessagePipeHandle handle) {
740 // Never grant any bindings to browser plugin guests.
741 if (GetProcess()->IsGuest()) {
742 NOTREACHED() << "Never grant bindings to a guest process.";
743 return;
744 }
745
746 if ((enabled_bindings_ & BINDINGS_POLICY_WEB_UI) == 0) {
747 NOTREACHED() << "You must grant bindings before setting the handle";
748 return;
749 }
750
751 DCHECK(renderer_initialized_);
752 RenderProcessHostImpl* process =
753 static_cast<RenderProcessHostImpl*>(GetProcess());
754 process->SetWebUIHandle(GetRoutingID(), handle.Pass());
755 }
756 #endif
757
758 void RenderViewHostImpl::DragTargetDragEnter( 738 void RenderViewHostImpl::DragTargetDragEnter(
759 const DropData& drop_data, 739 const DropData& drop_data,
760 const gfx::Point& client_pt, 740 const gfx::Point& client_pt,
761 const gfx::Point& screen_pt, 741 const gfx::Point& screen_pt,
762 WebDragOperationsMask operations_allowed, 742 WebDragOperationsMask operations_allowed,
763 int key_modifiers) { 743 int key_modifiers) {
764 const int renderer_id = GetProcess()->GetID(); 744 const int renderer_id = GetProcess()->GetID();
765 ChildProcessSecurityPolicyImpl* policy = 745 ChildProcessSecurityPolicyImpl* policy =
766 ChildProcessSecurityPolicyImpl::GetInstance(); 746 ChildProcessSecurityPolicyImpl::GetInstance();
767 747
(...skipping 1165 matching lines...) Expand 10 before | Expand all | Expand 10 after
1933 return true; 1913 return true;
1934 } 1914 }
1935 1915
1936 void RenderViewHostImpl::AttachToFrameTree() { 1916 void RenderViewHostImpl::AttachToFrameTree() {
1937 FrameTree* frame_tree = delegate_->GetFrameTree(); 1917 FrameTree* frame_tree = delegate_->GetFrameTree();
1938 1918
1939 frame_tree->ResetForMainFrameSwap(); 1919 frame_tree->ResetForMainFrameSwap();
1940 } 1920 }
1941 1921
1942 } // namespace content 1922 } // namespace content
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698