| OLD | NEW |
| 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 982 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 993 IPC_MESSAGE_HANDLER(ViewHostMsg_RenderViewReady, OnRenderViewReady) | 993 IPC_MESSAGE_HANDLER(ViewHostMsg_RenderViewReady, OnRenderViewReady) |
| 994 IPC_MESSAGE_HANDLER(ViewHostMsg_RenderProcessGone, OnRenderProcessGone) | 994 IPC_MESSAGE_HANDLER(ViewHostMsg_RenderProcessGone, OnRenderProcessGone) |
| 995 IPC_MESSAGE_HANDLER(ViewHostMsg_UpdateState, OnUpdateState) | 995 IPC_MESSAGE_HANDLER(ViewHostMsg_UpdateState, OnUpdateState) |
| 996 IPC_MESSAGE_HANDLER(ViewHostMsg_UpdateTitle, OnUpdateTitle) | 996 IPC_MESSAGE_HANDLER(ViewHostMsg_UpdateTitle, OnUpdateTitle) |
| 997 IPC_MESSAGE_HANDLER(ViewHostMsg_UpdateEncoding, OnUpdateEncoding) | 997 IPC_MESSAGE_HANDLER(ViewHostMsg_UpdateEncoding, OnUpdateEncoding) |
| 998 IPC_MESSAGE_HANDLER(ViewHostMsg_UpdateTargetURL, OnUpdateTargetURL) | 998 IPC_MESSAGE_HANDLER(ViewHostMsg_UpdateTargetURL, OnUpdateTargetURL) |
| 999 IPC_MESSAGE_HANDLER(ViewHostMsg_UpdateInspectorSetting, | 999 IPC_MESSAGE_HANDLER(ViewHostMsg_UpdateInspectorSetting, |
| 1000 OnUpdateInspectorSetting) | 1000 OnUpdateInspectorSetting) |
| 1001 IPC_MESSAGE_HANDLER(ViewHostMsg_Close, OnClose) | 1001 IPC_MESSAGE_HANDLER(ViewHostMsg_Close, OnClose) |
| 1002 IPC_MESSAGE_HANDLER(ViewHostMsg_RequestMove, OnRequestMove) | 1002 IPC_MESSAGE_HANDLER(ViewHostMsg_RequestMove, OnRequestMove) |
| 1003 IPC_MESSAGE_HANDLER(ViewHostMsg_DidChangeLoadProgress, | |
| 1004 OnDidChangeLoadProgress) | |
| 1005 IPC_MESSAGE_HANDLER(ViewHostMsg_DocumentAvailableInMainFrame, | 1003 IPC_MESSAGE_HANDLER(ViewHostMsg_DocumentAvailableInMainFrame, |
| 1006 OnDocumentAvailableInMainFrame) | 1004 OnDocumentAvailableInMainFrame) |
| 1007 IPC_MESSAGE_HANDLER(ViewHostMsg_DocumentOnLoadCompletedInMainFrame, | 1005 IPC_MESSAGE_HANDLER(ViewHostMsg_DocumentOnLoadCompletedInMainFrame, |
| 1008 OnDocumentOnLoadCompletedInMainFrame) | 1006 OnDocumentOnLoadCompletedInMainFrame) |
| 1009 IPC_MESSAGE_HANDLER(ViewHostMsg_ToggleFullscreen, OnToggleFullscreen) | 1007 IPC_MESSAGE_HANDLER(ViewHostMsg_ToggleFullscreen, OnToggleFullscreen) |
| 1010 IPC_MESSAGE_HANDLER(ViewHostMsg_DidContentsPreferredSizeChange, | 1008 IPC_MESSAGE_HANDLER(ViewHostMsg_DidContentsPreferredSizeChange, |
| 1011 OnDidContentsPreferredSizeChange) | 1009 OnDidContentsPreferredSizeChange) |
| 1012 IPC_MESSAGE_HANDLER(ViewHostMsg_DidChangeScrollOffset, | 1010 IPC_MESSAGE_HANDLER(ViewHostMsg_DidChangeScrollOffset, |
| 1013 OnDidChangeScrollOffset) | 1011 OnDidChangeScrollOffset) |
| 1014 IPC_MESSAGE_HANDLER(ViewHostMsg_DidChangeScrollOffsetPinningForMainFrame, | 1012 IPC_MESSAGE_HANDLER(ViewHostMsg_DidChangeScrollOffsetPinningForMainFrame, |
| (...skipping 208 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1223 // events, and we can take the fast path. | 1221 // events, and we can take the fast path. |
| 1224 ClosePageIgnoringUnloadEvents(); | 1222 ClosePageIgnoringUnloadEvents(); |
| 1225 } | 1223 } |
| 1226 | 1224 |
| 1227 void RenderViewHostImpl::OnRequestMove(const gfx::Rect& pos) { | 1225 void RenderViewHostImpl::OnRequestMove(const gfx::Rect& pos) { |
| 1228 if (IsRVHStateActive(rvh_state_)) | 1226 if (IsRVHStateActive(rvh_state_)) |
| 1229 delegate_->RequestMove(pos); | 1227 delegate_->RequestMove(pos); |
| 1230 Send(new ViewMsg_Move_ACK(GetRoutingID())); | 1228 Send(new ViewMsg_Move_ACK(GetRoutingID())); |
| 1231 } | 1229 } |
| 1232 | 1230 |
| 1233 void RenderViewHostImpl::OnDidChangeLoadProgress(double load_progress) { | |
| 1234 delegate_->DidChangeLoadProgress(load_progress); | |
| 1235 } | |
| 1236 | |
| 1237 void RenderViewHostImpl::OnDocumentAvailableInMainFrame() { | 1231 void RenderViewHostImpl::OnDocumentAvailableInMainFrame() { |
| 1238 delegate_->DocumentAvailableInMainFrame(this); | 1232 delegate_->DocumentAvailableInMainFrame(this); |
| 1239 } | 1233 } |
| 1240 | 1234 |
| 1241 void RenderViewHostImpl::OnDocumentOnLoadCompletedInMainFrame( | 1235 void RenderViewHostImpl::OnDocumentOnLoadCompletedInMainFrame( |
| 1242 int32 page_id) { | 1236 int32 page_id) { |
| 1243 delegate_->DocumentOnLoadCompletedInMainFrame(this, page_id); | 1237 delegate_->DocumentOnLoadCompletedInMainFrame(this, page_id); |
| 1244 } | 1238 } |
| 1245 | 1239 |
| 1246 void RenderViewHostImpl::OnToggleFullscreen(bool enter_fullscreen) { | 1240 void RenderViewHostImpl::OnToggleFullscreen(bool enter_fullscreen) { |
| (...skipping 485 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1732 return true; | 1726 return true; |
| 1733 } | 1727 } |
| 1734 | 1728 |
| 1735 void RenderViewHostImpl::AttachToFrameTree() { | 1729 void RenderViewHostImpl::AttachToFrameTree() { |
| 1736 FrameTree* frame_tree = delegate_->GetFrameTree(); | 1730 FrameTree* frame_tree = delegate_->GetFrameTree(); |
| 1737 | 1731 |
| 1738 frame_tree->ResetForMainFrameSwap(); | 1732 frame_tree->ResetForMainFrameSwap(); |
| 1739 } | 1733 } |
| 1740 | 1734 |
| 1741 } // namespace content | 1735 } // namespace content |
| OLD | NEW |