Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(18)

Side by Side Diff: content/renderer/render_frame_impl.h

Issue 1964273002: Add FrameHost mojo service (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: unbind Created 4 years, 7 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
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_RENDERER_RENDER_FRAME_IMPL_H_ 5 #ifndef CONTENT_RENDERER_RENDER_FRAME_IMPL_H_
6 #define CONTENT_RENDERER_RENDER_FRAME_IMPL_H_ 6 #define CONTENT_RENDERER_RENDER_FRAME_IMPL_H_
7 7
8 #include <stddef.h> 8 #include <stddef.h>
9 #include <stdint.h> 9 #include <stdint.h>
10 10
11 #include <memory> 11 #include <memory>
12 #include <string> 12 #include <string>
13 #include <vector> 13 #include <vector>
14 14
15 #include "base/files/file_path.h" 15 #include "base/files/file_path.h"
16 #include "base/gtest_prod_util.h" 16 #include "base/gtest_prod_util.h"
17 #include "base/id_map.h" 17 #include "base/id_map.h"
18 #include "base/macros.h" 18 #include "base/macros.h"
19 #include "base/memory/linked_ptr.h" 19 #include "base/memory/linked_ptr.h"
20 #include "base/memory/weak_ptr.h" 20 #include "base/memory/weak_ptr.h"
21 #include "base/observer_list.h" 21 #include "base/observer_list.h"
22 #include "base/process/process_handle.h" 22 #include "base/process/process_handle.h"
23 #include "build/build_config.h" 23 #include "build/build_config.h"
24 #include "content/common/accessibility_mode_enums.h" 24 #include "content/common/accessibility_mode_enums.h"
25 #include "content/common/frame_host.mojom.h"
25 #include "content/common/frame_message_enums.h" 26 #include "content/common/frame_message_enums.h"
26 #include "content/common/mojo/service_registry_impl.h" 27 #include "content/common/mojo/service_registry_impl.h"
27 #include "content/public/common/console_message_level.h" 28 #include "content/public/common/console_message_level.h"
28 #include "content/public/common/javascript_message_type.h" 29 #include "content/public/common/javascript_message_type.h"
29 #include "content/public/common/referrer.h" 30 #include "content/public/common/referrer.h"
30 #include "content/public/common/stop_find_action.h" 31 #include "content/public/common/stop_find_action.h"
31 #include "content/public/renderer/render_frame.h" 32 #include "content/public/renderer/render_frame.h"
32 #include "content/renderer/frame_blame_context.h" 33 #include "content/renderer/frame_blame_context.h"
33 #include "content/renderer/mojo/blink_service_registry_impl.h" 34 #include "content/renderer/mojo/blink_service_registry_impl.h"
34 #include "content/renderer/render_frame_proxy.h" 35 #include "content/renderer/render_frame_proxy.h"
(...skipping 649 matching lines...) Expand 10 before | Expand all | Expand 10 after
684 friend class RenderFrameImplTest; 685 friend class RenderFrameImplTest;
685 friend class RenderFrameObserver; 686 friend class RenderFrameObserver;
686 friend class RendererAccessibilityTest; 687 friend class RendererAccessibilityTest;
687 friend class TestRenderFrame; 688 friend class TestRenderFrame;
688 FRIEND_TEST_ALL_PREFIXES(ExternalPopupMenuDisplayNoneTest, SelectItem); 689 FRIEND_TEST_ALL_PREFIXES(ExternalPopupMenuDisplayNoneTest, SelectItem);
689 FRIEND_TEST_ALL_PREFIXES(ExternalPopupMenuRemoveTest, RemoveOnChange); 690 FRIEND_TEST_ALL_PREFIXES(ExternalPopupMenuRemoveTest, RemoveOnChange);
690 FRIEND_TEST_ALL_PREFIXES(ExternalPopupMenuTest, NormalCase); 691 FRIEND_TEST_ALL_PREFIXES(ExternalPopupMenuTest, NormalCase);
691 FRIEND_TEST_ALL_PREFIXES(ExternalPopupMenuTest, ShowPopupThenNavigate); 692 FRIEND_TEST_ALL_PREFIXES(ExternalPopupMenuTest, ShowPopupThenNavigate);
692 FRIEND_TEST_ALL_PREFIXES(RendererAccessibilityTest, 693 FRIEND_TEST_ALL_PREFIXES(RendererAccessibilityTest,
693 AccessibilityMessagesQueueWhileSwappedOut); 694 AccessibilityMessagesQueueWhileSwappedOut);
695 FRIEND_TEST_ALL_PREFIXES(RenderFrameImplTest, ZoomLimit);
694 696
695 // A wrapper class used as the callback for JavaScript executed 697 // A wrapper class used as the callback for JavaScript executed
696 // in an isolated world. 698 // in an isolated world.
697 class JavaScriptIsolatedWorldRequest 699 class JavaScriptIsolatedWorldRequest
698 : public blink::WebScriptExecutionCallback { 700 : public blink::WebScriptExecutionCallback {
699 public: 701 public:
700 JavaScriptIsolatedWorldRequest( 702 JavaScriptIsolatedWorldRequest(
701 int id, 703 int id,
702 bool notify_result, 704 bool notify_result,
703 int routing_id, 705 int routing_id,
(...skipping 303 matching lines...) Expand 10 before | Expand all | Expand 10 after
1007 // Sends a reply to the current find operation handling if it was a 1009 // Sends a reply to the current find operation handling if it was a
1008 // synchronous find request. 1010 // synchronous find request.
1009 void SendFindReply(int request_id, 1011 void SendFindReply(int request_id,
1010 int match_count, 1012 int match_count,
1011 int ordinal, 1013 int ordinal,
1012 const blink::WebRect& selection_rect, 1014 const blink::WebRect& selection_rect,
1013 bool final_status_update); 1015 bool final_status_update);
1014 1016
1015 void InitializeBlameContext(RenderFrameImpl* parent_frame); 1017 void InitializeBlameContext(RenderFrameImpl* parent_frame);
1016 1018
1019 void OnGotZoomLevel(const GURL& url, double zoom_level);
1020
1017 // Stores the WebLocalFrame we are associated with. This is null from the 1021 // Stores the WebLocalFrame we are associated with. This is null from the
1018 // constructor until BindToWebFrame is called, and it is null after 1022 // constructor until BindToWebFrame is called, and it is null after
1019 // frameDetached is called until destruction (which is asynchronous in the 1023 // frameDetached is called until destruction (which is asynchronous in the
1020 // case of the main frame, but not subframes). 1024 // case of the main frame, but not subframes).
1021 blink::WebLocalFrame* frame_; 1025 blink::WebLocalFrame* frame_;
1022 1026
1023 // Boolean value indicating whether this RenderFrameImpl object is for the 1027 // Boolean value indicating whether this RenderFrameImpl object is for the
1024 // main frame or not. It remains accurate during destruction, even when 1028 // main frame or not. It remains accurate during destruction, even when
1025 // |frame_| has been invalidated. 1029 // |frame_| has been invalidated.
1026 bool is_main_frame_; 1030 bool is_main_frame_;
(...skipping 176 matching lines...) Expand 10 before | Expand all | Expand 10 after
1203 // Only valid if |accessibility_mode_| is anything other than 1207 // Only valid if |accessibility_mode_| is anything other than
1204 // AccessibilityModeOff. 1208 // AccessibilityModeOff.
1205 RendererAccessibility* renderer_accessibility_; 1209 RendererAccessibility* renderer_accessibility_;
1206 1210
1207 std::unique_ptr<PermissionDispatcher> permission_client_; 1211 std::unique_ptr<PermissionDispatcher> permission_client_;
1208 1212
1209 std::unique_ptr<blink::WebAppBannerClient> app_banner_client_; 1213 std::unique_ptr<blink::WebAppBannerClient> app_banner_client_;
1210 1214
1211 std::unique_ptr<blink::WebBluetooth> bluetooth_; 1215 std::unique_ptr<blink::WebBluetooth> bluetooth_;
1212 1216
1217 HostZoomLevels host_zoom_levels_;
1218 mojom::FrameHostPtr frame_host_;
1219
1213 // Manages play, pause notifications for WebMediaPlayer implementations; its 1220 // Manages play, pause notifications for WebMediaPlayer implementations; its
1214 // lifetime is tied to the RenderFrame via the RenderFrameObserver interface. 1221 // lifetime is tied to the RenderFrame via the RenderFrameObserver interface.
1215 media::RendererWebMediaPlayerDelegate* media_player_delegate_; 1222 media::RendererWebMediaPlayerDelegate* media_player_delegate_;
1216 1223
1217 // Whether or not this RenderFrame is using Lo-Fi mode. 1224 // Whether or not this RenderFrame is using Lo-Fi mode.
1218 bool is_using_lofi_; 1225 bool is_using_lofi_;
1219 1226
1220 // Effective connection type when the document of this frame was fetched. 1227 // Effective connection type when the document of this frame was fetched.
1221 blink::WebEffectiveConnectionType effective_connection_type_; 1228 blink::WebEffectiveConnectionType effective_connection_type_;
1222 1229
(...skipping 28 matching lines...) Expand all
1251 #endif 1258 #endif
1252 1259
1253 base::WeakPtrFactory<RenderFrameImpl> weak_factory_; 1260 base::WeakPtrFactory<RenderFrameImpl> weak_factory_;
1254 1261
1255 DISALLOW_COPY_AND_ASSIGN(RenderFrameImpl); 1262 DISALLOW_COPY_AND_ASSIGN(RenderFrameImpl);
1256 }; 1263 };
1257 1264
1258 } // namespace content 1265 } // namespace content
1259 1266
1260 #endif // CONTENT_RENDERER_RENDER_FRAME_IMPL_H_ 1267 #endif // CONTENT_RENDERER_RENDER_FRAME_IMPL_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698