| OLD | NEW |
| 1 // Copyright 2015 The Chromium Authors. All rights reserved. | 1 // Copyright 2015 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 #ifndef CONTENT_BROWSER_FRAME_HOST_NAVIGATION_HANDLE_IMPL_H_ | 5 #ifndef CONTENT_BROWSER_FRAME_HOST_NAVIGATION_HANDLE_IMPL_H_ |
| 6 #define CONTENT_BROWSER_FRAME_HOST_NAVIGATION_HANDLE_IMPL_H_ | 6 #define CONTENT_BROWSER_FRAME_HOST_NAVIGATION_HANDLE_IMPL_H_ |
| 7 | 7 |
| 8 #include "content/public/browser/navigation_handle.h" | 8 #include "content/public/browser/navigation_handle.h" |
| 9 | 9 |
| 10 #include <stddef.h> | 10 #include <stddef.h> |
| (...skipping 352 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 363 } | 363 } |
| 364 | 364 |
| 365 void set_base_url_for_data_url(const GURL& url) { | 365 void set_base_url_for_data_url(const GURL& url) { |
| 366 base_url_for_data_url_ = url; | 366 base_url_for_data_url_ = url; |
| 367 } | 367 } |
| 368 | 368 |
| 369 CSPDisposition should_check_main_world_csp() const { | 369 CSPDisposition should_check_main_world_csp() const { |
| 370 return should_check_main_world_csp_; | 370 return should_check_main_world_csp_; |
| 371 } | 371 } |
| 372 | 372 |
| 373 const SourceLocation& source_location() const { return source_location_; } |
| 374 void set_source_location(const SourceLocation& source_location) { |
| 375 source_location_ = source_location; |
| 376 } |
| 377 |
| 373 private: | 378 private: |
| 374 friend class NavigationHandleImplTest; | 379 friend class NavigationHandleImplTest; |
| 375 | 380 |
| 376 NavigationHandleImpl(const GURL& url, | 381 NavigationHandleImpl(const GURL& url, |
| 377 const std::vector<GURL>& redirect_chain, | 382 const std::vector<GURL>& redirect_chain, |
| 378 FrameTreeNode* frame_tree_node, | 383 FrameTreeNode* frame_tree_node, |
| 379 bool is_renderer_initiated, | 384 bool is_renderer_initiated, |
| 380 bool is_same_page, | 385 bool is_same_page, |
| 381 const base::TimeTicks& navigation_start, | 386 const base::TimeTicks& navigation_start, |
| 382 int pending_nav_entry_id, | 387 int pending_nav_entry_id, |
| (...skipping 156 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 539 NavigationType navigation_type_; | 544 NavigationType navigation_type_; |
| 540 | 545 |
| 541 // Whether or not the CSP of the main world should apply. When the navigation | 546 // Whether or not the CSP of the main world should apply. When the navigation |
| 542 // is initiated from a content script in an isolated world, the CSP defined | 547 // is initiated from a content script in an isolated world, the CSP defined |
| 543 // in the main world should not apply. | 548 // in the main world should not apply. |
| 544 CSPDisposition should_check_main_world_csp_; | 549 CSPDisposition should_check_main_world_csp_; |
| 545 | 550 |
| 546 // Whether or not the navigation results from the submission of a form. | 551 // Whether or not the navigation results from the submission of a form. |
| 547 bool is_form_submission_; | 552 bool is_form_submission_; |
| 548 | 553 |
| 554 // PlzNavigate |
| 555 // Information about the JavaScript that started the navigation. For |
| 556 // navigations initiated by Javascript. |
| 557 SourceLocation source_location_; |
| 558 |
| 549 base::WeakPtrFactory<NavigationHandleImpl> weak_factory_; | 559 base::WeakPtrFactory<NavigationHandleImpl> weak_factory_; |
| 550 | 560 |
| 551 DISALLOW_COPY_AND_ASSIGN(NavigationHandleImpl); | 561 DISALLOW_COPY_AND_ASSIGN(NavigationHandleImpl); |
| 552 }; | 562 }; |
| 553 | 563 |
| 554 } // namespace content | 564 } // namespace content |
| 555 | 565 |
| 556 #endif // CONTENT_BROWSER_FRAME_HOST_NAVIGATION_HANDLE_IMPL_H_ | 566 #endif // CONTENT_BROWSER_FRAME_HOST_NAVIGATION_HANDLE_IMPL_H_ |
| OLD | NEW |