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/browser/frame_host/navigator_impl.h" | 5 #include "content/browser/frame_host/navigator_impl.h" |
6 | 6 |
7 #include "base/command_line.h" | 7 #include "base/command_line.h" |
8 #include "content/browser/frame_host/frame_tree.h" | 8 #include "content/browser/frame_host/frame_tree.h" |
9 #include "content/browser/frame_host/frame_tree_node.h" | 9 #include "content/browser/frame_host/frame_tree_node.h" |
10 #include "content/browser/frame_host/navigation_controller_impl.h" | 10 #include "content/browser/frame_host/navigation_controller_impl.h" |
(...skipping 354 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
365 // session history, which is what we want to do for javascript: URLs that | 365 // session history, which is what we want to do for javascript: URLs that |
366 // do not generate content. What we really need is a message from the | 366 // do not generate content. What we really need is a message from the |
367 // renderer telling us that a new page was not created. The same message | 367 // renderer telling us that a new page was not created. The same message |
368 // could be used for mailto: URLs and the like. | 368 // could be used for mailto: URLs and the like. |
369 if (entry.GetURL().SchemeIs(url::kJavaScriptScheme)) | 369 if (entry.GetURL().SchemeIs(url::kJavaScriptScheme)) |
370 return false; | 370 return false; |
371 } | 371 } |
372 | 372 |
373 // Notify observers about navigation. | 373 // Notify observers about navigation. |
374 if (delegate_) { | 374 if (delegate_) { |
375 delegate_->DidStartNavigationToPendingEntry(render_frame_host, | 375 delegate_->DidStartNavigationToPendingEntry(dest_render_frame_host, |
376 entry.GetURL(), | 376 entry.GetURL(), |
377 reload_type); | 377 reload_type); |
378 } | 378 } |
379 | 379 |
380 return true; | 380 return true; |
381 } | 381 } |
382 | 382 |
383 bool NavigatorImpl::NavigateToPendingEntry( | 383 bool NavigatorImpl::NavigateToPendingEntry( |
384 RenderFrameHostImpl* render_frame_host, | 384 RenderFrameHostImpl* render_frame_host, |
385 NavigationController::ReloadType reload_type) { | 385 NavigationController::ReloadType reload_type) { |
(...skipping 240 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
626 | 626 |
627 // Navigations in Web UI pages count as browser-initiated navigations. | 627 // Navigations in Web UI pages count as browser-initiated navigations. |
628 params.is_renderer_initiated = false; | 628 params.is_renderer_initiated = false; |
629 } | 629 } |
630 | 630 |
631 if (delegate_) | 631 if (delegate_) |
632 delegate_->RequestOpenURL(render_frame_host, params); | 632 delegate_->RequestOpenURL(render_frame_host, params); |
633 } | 633 } |
634 | 634 |
635 } // namespace content | 635 } // namespace content |
OLD | NEW |