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 #ifndef CONTENT_BROWSER_RENDERER_HOST_RENDER_VIEW_HOST_IMPL_H_ | 5 #ifndef CONTENT_BROWSER_RENDERER_HOST_RENDER_VIEW_HOST_IMPL_H_ |
6 #define CONTENT_BROWSER_RENDERER_HOST_RENDER_VIEW_HOST_IMPL_H_ | 6 #define CONTENT_BROWSER_RENDERER_HOST_RENDER_VIEW_HOST_IMPL_H_ |
7 | 7 |
8 #include <map> | 8 #include <map> |
9 #include <string> | 9 #include <string> |
10 #include <vector> | 10 #include <vector> |
(...skipping 404 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
415 const std::string& frame_tree); | 415 const std::string& frame_tree); |
416 | 416 |
417 void set_save_accessibility_tree_for_testing(bool save) { | 417 void set_save_accessibility_tree_for_testing(bool save) { |
418 save_accessibility_tree_for_testing_ = save; | 418 save_accessibility_tree_for_testing_ = save; |
419 } | 419 } |
420 | 420 |
421 const AccessibilityNodeData& accessibility_tree_for_testing() { | 421 const AccessibilityNodeData& accessibility_tree_for_testing() { |
422 return accessibility_tree_; | 422 return accessibility_tree_; |
423 } | 423 } |
424 | 424 |
| 425 // Set accessibility callbacks. |
| 426 void SetAccessibilityLayoutCompleteCallbackForTesting( |
| 427 const base::Closure& callback); |
| 428 void SetAccessibilityLoadCompleteCallbackForTesting( |
| 429 const base::Closure& callback); |
| 430 void SetAccessibilityOtherCallbackForTesting( |
| 431 const base::Closure& callback); |
| 432 |
425 bool is_waiting_for_unload_ack_for_testing() { | 433 bool is_waiting_for_unload_ack_for_testing() { |
426 return is_waiting_for_unload_ack_; | 434 return is_waiting_for_unload_ack_; |
427 } | 435 } |
428 | 436 |
429 // Checks that the given renderer can request |url|, if not it sets it to | 437 // Checks that the given renderer can request |url|, if not it sets it to |
430 // about:blank. | 438 // about:blank. |
431 // empty_allowed must be set to false for navigations for security reasons. | 439 // empty_allowed must be set to false for navigations for security reasons. |
432 static void FilterURL(ChildProcessSecurityPolicyImpl* policy, | 440 static void FilterURL(ChildProcessSecurityPolicyImpl* policy, |
433 const RenderProcessHost* process, | 441 const RenderProcessHost* process, |
434 bool empty_allowed, | 442 bool empty_allowed, |
(...skipping 205 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
640 // the case of a cross-site transition ( = true). | 648 // the case of a cross-site transition ( = true). |
641 bool unload_ack_is_for_cross_site_transition_; | 649 bool unload_ack_is_for_cross_site_transition_; |
642 | 650 |
643 bool are_javascript_messages_suppressed_; | 651 bool are_javascript_messages_suppressed_; |
644 | 652 |
645 // The mapping of pending javascript calls created by | 653 // The mapping of pending javascript calls created by |
646 // ExecuteJavascriptInWebFrameCallbackResult and their corresponding | 654 // ExecuteJavascriptInWebFrameCallbackResult and their corresponding |
647 // callbacks. | 655 // callbacks. |
648 std::map<int, JavascriptResultCallback> javascript_callbacks_; | 656 std::map<int, JavascriptResultCallback> javascript_callbacks_; |
649 | 657 |
| 658 // Accessibility callbacks. |
| 659 base::Closure accessibility_layout_callback_; |
| 660 base::Closure accessibility_load_callback_; |
| 661 base::Closure accessibility_other_callback_; |
| 662 |
650 // True if the render view can be shut down suddenly. | 663 // True if the render view can be shut down suddenly. |
651 bool sudden_termination_allowed_; | 664 bool sudden_termination_allowed_; |
652 | 665 |
653 // The session storage namespace to be used by the associated render view. | 666 // The session storage namespace to be used by the associated render view. |
654 scoped_refptr<SessionStorageNamespaceImpl> session_storage_namespace_; | 667 scoped_refptr<SessionStorageNamespaceImpl> session_storage_namespace_; |
655 | 668 |
656 // Whether the accessibility tree should be saved, for unit testing. | 669 // Whether the accessibility tree should be saved, for unit testing. |
657 bool save_accessibility_tree_for_testing_; | 670 bool save_accessibility_tree_for_testing_; |
658 | 671 |
659 // A JSON serialized representation of the frame tree for the current document | 672 // A JSON serialized representation of the frame tree for the current document |
(...skipping 27 matching lines...) Expand all Loading... |
687 DISALLOW_COPY_AND_ASSIGN(RenderViewHostImpl); | 700 DISALLOW_COPY_AND_ASSIGN(RenderViewHostImpl); |
688 }; | 701 }; |
689 | 702 |
690 #if defined(COMPILER_MSVC) | 703 #if defined(COMPILER_MSVC) |
691 #pragma warning(pop) | 704 #pragma warning(pop) |
692 #endif | 705 #endif |
693 | 706 |
694 } // namespace content | 707 } // namespace content |
695 | 708 |
696 #endif // CONTENT_BROWSER_RENDERER_HOST_RENDER_VIEW_HOST_IMPL_H_ | 709 #endif // CONTENT_BROWSER_RENDERER_HOST_RENDER_VIEW_HOST_IMPL_H_ |
OLD | NEW |