| 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 #ifndef CONTENT_BROWSER_FRAME_HOST_RENDER_FRAME_HOST_IMPL_H_ | 5 #ifndef CONTENT_BROWSER_FRAME_HOST_RENDER_FRAME_HOST_IMPL_H_ |
| 6 #define CONTENT_BROWSER_FRAME_HOST_RENDER_FRAME_HOST_IMPL_H_ | 6 #define CONTENT_BROWSER_FRAME_HOST_RENDER_FRAME_HOST_IMPL_H_ |
| 7 | 7 |
| 8 #include <stddef.h> | 8 #include <stddef.h> |
| 9 #include <stdint.h> | 9 #include <stdint.h> |
| 10 | 10 |
| (...skipping 452 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 463 // renderer process, and the accessibility tree it sent can be | 463 // renderer process, and the accessibility tree it sent can be |
| 464 // retrieved using GetAXTreeForTesting(). | 464 // retrieved using GetAXTreeForTesting(). |
| 465 void SetAccessibilityCallbackForTesting( | 465 void SetAccessibilityCallbackForTesting( |
| 466 const base::Callback<void(ui::AXEvent, int)>& callback); | 466 const base::Callback<void(ui::AXEvent, int)>& callback); |
| 467 | 467 |
| 468 // Called when the metadata about the accessibility tree for this frame | 468 // Called when the metadata about the accessibility tree for this frame |
| 469 // changes due to a browser-side change, as opposed to due to an IPC from | 469 // changes due to a browser-side change, as opposed to due to an IPC from |
| 470 // a renderer. | 470 // a renderer. |
| 471 void UpdateAXTreeData(); | 471 void UpdateAXTreeData(); |
| 472 | 472 |
| 473 // Set the AX tree ID of the embedder RFHI, if this is a browser plugin guest. |
| 474 void SetBrowserPluginEmbedderAXTreeID(AXTreeIDRegistry::AXTreeID ax_tree_id); |
| 475 |
| 473 // Send a message to the render process to change text track style settings. | 476 // Send a message to the render process to change text track style settings. |
| 474 void SetTextTrackSettings(const FrameMsg_TextTrackSettings_Params& params); | 477 void SetTextTrackSettings(const FrameMsg_TextTrackSettings_Params& params); |
| 475 | 478 |
| 476 // Returns a snapshot of the accessibility tree received from the | 479 // Returns a snapshot of the accessibility tree received from the |
| 477 // renderer as of the last time an accessibility notification was | 480 // renderer as of the last time an accessibility notification was |
| 478 // received. | 481 // received. |
| 479 const ui::AXTree* GetAXTreeForTesting(); | 482 const ui::AXTree* GetAXTreeForTesting(); |
| 480 | 483 |
| 481 // Access the BrowserAccessibilityManager if it already exists. | 484 // Access the BrowserAccessibilityManager if it already exists. |
| 482 BrowserAccessibilityManager* browser_accessibility_manager() const { | 485 BrowserAccessibilityManager* browser_accessibility_manager() const { |
| (...skipping 402 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 885 // assigned) and a complete replacement accessibility tree. | 888 // assigned) and a complete replacement accessibility tree. |
| 886 int accessibility_reset_token_; | 889 int accessibility_reset_token_; |
| 887 | 890 |
| 888 // A count of the number of times we needed to reset accessibility, so | 891 // A count of the number of times we needed to reset accessibility, so |
| 889 // we don't keep trying to reset forever. | 892 // we don't keep trying to reset forever. |
| 890 int accessibility_reset_count_; | 893 int accessibility_reset_count_; |
| 891 | 894 |
| 892 // The last AXContentTreeData for this frame received from the RenderFrame. | 895 // The last AXContentTreeData for this frame received from the RenderFrame. |
| 893 AXContentTreeData ax_content_tree_data_; | 896 AXContentTreeData ax_content_tree_data_; |
| 894 | 897 |
| 898 // The AX tree ID of the embedder, if this is a browser plugin guest. |
| 899 AXTreeIDRegistry::AXTreeID browser_plugin_embedder_ax_tree_id_; |
| 900 |
| 895 // The mapping from callback id to corresponding callback for pending | 901 // The mapping from callback id to corresponding callback for pending |
| 896 // accessibility tree snapshot calls created by RequestAXTreeSnapshot. | 902 // accessibility tree snapshot calls created by RequestAXTreeSnapshot. |
| 897 std::map<int, AXTreeSnapshotCallback> ax_tree_snapshot_callbacks_; | 903 std::map<int, AXTreeSnapshotCallback> ax_tree_snapshot_callbacks_; |
| 898 | 904 |
| 899 // Callback when an event is received, for testing. | 905 // Callback when an event is received, for testing. |
| 900 base::Callback<void(ui::AXEvent, int)> accessibility_testing_callback_; | 906 base::Callback<void(ui::AXEvent, int)> accessibility_testing_callback_; |
| 901 // The most recently received accessibility tree - for testing only. | 907 // The most recently received accessibility tree - for testing only. |
| 902 scoped_ptr<ui::AXTree> ax_tree_for_testing_; | 908 scoped_ptr<ui::AXTree> ax_tree_for_testing_; |
| 903 // Flag to not create a BrowserAccessibilityManager, for testing. If one | 909 // Flag to not create a BrowserAccessibilityManager, for testing. If one |
| 904 // already exists it will still be used. | 910 // already exists it will still be used. |
| (...skipping 37 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 942 | 948 |
| 943 // NOTE: This must be the last member. | 949 // NOTE: This must be the last member. |
| 944 base::WeakPtrFactory<RenderFrameHostImpl> weak_ptr_factory_; | 950 base::WeakPtrFactory<RenderFrameHostImpl> weak_ptr_factory_; |
| 945 | 951 |
| 946 DISALLOW_COPY_AND_ASSIGN(RenderFrameHostImpl); | 952 DISALLOW_COPY_AND_ASSIGN(RenderFrameHostImpl); |
| 947 }; | 953 }; |
| 948 | 954 |
| 949 } // namespace content | 955 } // namespace content |
| 950 | 956 |
| 951 #endif // CONTENT_BROWSER_FRAME_HOST_RENDER_FRAME_HOST_IMPL_H_ | 957 #endif // CONTENT_BROWSER_FRAME_HOST_RENDER_FRAME_HOST_IMPL_H_ |
| OLD | NEW |