| OLD | NEW |
| 1 // Copyright 2013 The Chromium Authors. All rights reserved. | 1 // Copyright 2013 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/renderer/render_frame_impl.h" | 5 #include "content/renderer/render_frame_impl.h" |
| 6 | 6 |
| 7 #include <map> | 7 #include <map> |
| 8 #include <string> | 8 #include <string> |
| 9 | 9 |
| 10 #include "base/auto_reset.h" | 10 #include "base/auto_reset.h" |
| (...skipping 2545 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 2556 didCommitProvisionalLoad(frame, item, commit_type); | 2556 didCommitProvisionalLoad(frame, item, commit_type); |
| 2557 } | 2557 } |
| 2558 | 2558 |
| 2559 void RenderFrameImpl::didUpdateCurrentHistoryItem(blink::WebLocalFrame* frame) { | 2559 void RenderFrameImpl::didUpdateCurrentHistoryItem(blink::WebLocalFrame* frame) { |
| 2560 DCHECK(!frame_ || frame_ == frame); | 2560 DCHECK(!frame_ || frame_ == frame); |
| 2561 // TODO(nasko): Move implementation here. Needed methods: | 2561 // TODO(nasko): Move implementation here. Needed methods: |
| 2562 // * StartNavStateSyncTimerIfNecessary | 2562 // * StartNavStateSyncTimerIfNecessary |
| 2563 render_view_->didUpdateCurrentHistoryItem(frame); | 2563 render_view_->didUpdateCurrentHistoryItem(frame); |
| 2564 } | 2564 } |
| 2565 | 2565 |
| 2566 // TODO(zhenw): This will be removed once the blink side implementation is done. | |
| 2567 void RenderFrameImpl::addNavigationTransitionData( | |
| 2568 const blink::WebString& allowed_destination_host_pattern, | |
| 2569 const blink::WebString& selector, | |
| 2570 const blink::WebString& markup, | |
| 2571 const blink::WebVector<blink::WebString>& web_ids, | |
| 2572 const blink::WebVector<blink::WebRect>& web_rects) { | |
| 2573 FrameHostMsg_AddNavigationTransitionData_Params params; | |
| 2574 params.render_frame_id = routing_id_; | |
| 2575 params.allowed_destination_host_pattern = | |
| 2576 allowed_destination_host_pattern.utf8(); | |
| 2577 params.selector = selector.utf8(); | |
| 2578 params.markup = markup.utf8(); | |
| 2579 params.elements.resize(web_ids.size()); | |
| 2580 for (size_t i = 0; i < web_ids.size(); i++) { | |
| 2581 params.elements[i].id = web_ids[i].utf8(); | |
| 2582 params.elements[i].rect = gfx::Rect(web_rects[i]); | |
| 2583 } | |
| 2584 | |
| 2585 Send(new FrameHostMsg_AddNavigationTransitionData(params)); | |
| 2586 } | |
| 2587 | |
| 2588 void RenderFrameImpl::addNavigationTransitionData( | 2566 void RenderFrameImpl::addNavigationTransitionData( |
| 2589 const blink::WebTransitionElementData& data) { | 2567 const blink::WebTransitionElementData& data) { |
| 2590 FrameHostMsg_AddNavigationTransitionData_Params params; | 2568 FrameHostMsg_AddNavigationTransitionData_Params params; |
| 2591 params.render_frame_id = routing_id_; | 2569 params.render_frame_id = routing_id_; |
| 2592 params.allowed_destination_host_pattern = | 2570 params.allowed_destination_host_pattern = |
| 2593 data.scope.utf8(); | 2571 data.scope.utf8(); |
| 2594 params.selector = data.selector.utf8(); | 2572 params.selector = data.selector.utf8(); |
| 2595 params.markup = data.markup.utf8(); | 2573 params.markup = data.markup.utf8(); |
| 2596 params.elements.resize(data.elements.size()); | 2574 params.elements.resize(data.elements.size()); |
| 2597 for (size_t i = 0; i < data.elements.size(); i++) { | 2575 for (size_t i = 0; i < data.elements.size(); i++) { |
| (...skipping 1601 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 4199 | 4177 |
| 4200 #if defined(ENABLE_BROWSER_CDMS) | 4178 #if defined(ENABLE_BROWSER_CDMS) |
| 4201 RendererCdmManager* RenderFrameImpl::GetCdmManager() { | 4179 RendererCdmManager* RenderFrameImpl::GetCdmManager() { |
| 4202 if (!cdm_manager_) | 4180 if (!cdm_manager_) |
| 4203 cdm_manager_ = new RendererCdmManager(this); | 4181 cdm_manager_ = new RendererCdmManager(this); |
| 4204 return cdm_manager_; | 4182 return cdm_manager_; |
| 4205 } | 4183 } |
| 4206 #endif // defined(ENABLE_BROWSER_CDMS) | 4184 #endif // defined(ENABLE_BROWSER_CDMS) |
| 4207 | 4185 |
| 4208 } // namespace content | 4186 } // namespace content |
| OLD | NEW |