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_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 <vector> | 8 #include <vector> |
9 | 9 |
10 #include "base/basictypes.h" | 10 #include "base/basictypes.h" |
(...skipping 18 matching lines...) Expand all Loading... |
29 #include "third_party/WebKit/public/web/WebHistoryCommitType.h" | 29 #include "third_party/WebKit/public/web/WebHistoryCommitType.h" |
30 #include "ui/gfx/range/range.h" | 30 #include "ui/gfx/range/range.h" |
31 | 31 |
32 #if defined(OS_ANDROID) | 32 #if defined(OS_ANDROID) |
33 #include "content/renderer/media/android/renderer_media_player_manager.h" | 33 #include "content/renderer/media/android/renderer_media_player_manager.h" |
34 #endif | 34 #endif |
35 | 35 |
36 class GURL; | 36 class GURL; |
37 class TransportDIB; | 37 class TransportDIB; |
38 struct FrameMsg_Navigate_Params; | 38 struct FrameMsg_Navigate_Params; |
| 39 struct FrameMsg_NewFrame_WidgetParams; |
39 | 40 |
40 namespace blink { | 41 namespace blink { |
41 class WebGeolocationClient; | 42 class WebGeolocationClient; |
42 class WebInputEvent; | 43 class WebInputEvent; |
43 class WebMouseEvent; | 44 class WebMouseEvent; |
44 class WebContentDecryptionModule; | 45 class WebContentDecryptionModule; |
45 class WebMediaPlayer; | 46 class WebMediaPlayer; |
46 class WebNotificationPresenter; | 47 class WebNotificationPresenter; |
47 class WebPushClient; | 48 class WebPushClient; |
48 class WebSecurityOrigin; | 49 class WebSecurityOrigin; |
(...skipping 49 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
98 // TODO(creis): We should structure this so that |SetWebFrame| isn't needed. | 99 // TODO(creis): We should structure this so that |SetWebFrame| isn't needed. |
99 static RenderFrameImpl* Create(RenderViewImpl* render_view, int32 routing_id); | 100 static RenderFrameImpl* Create(RenderViewImpl* render_view, int32 routing_id); |
100 | 101 |
101 // Creates a new RenderFrame with |routing_id| as a child of the RenderFrame | 102 // Creates a new RenderFrame with |routing_id| as a child of the RenderFrame |
102 // identified by |parent_routing_id| or as the top-level frame if the latter | 103 // identified by |parent_routing_id| or as the top-level frame if the latter |
103 // is MSG_ROUTING_NONE. It creates the Blink WebLocalFrame and inserts it in | 104 // is MSG_ROUTING_NONE. It creates the Blink WebLocalFrame and inserts it in |
104 // the proper place in the frame tree. | 105 // the proper place in the frame tree. |
105 // Note: This is called only when RenderFrame is being created in response to | 106 // Note: This is called only when RenderFrame is being created in response to |
106 // IPC message from the browser process. All other frame creation is driven | 107 // IPC message from the browser process. All other frame creation is driven |
107 // through Blink and Create. | 108 // through Blink and Create. |
108 static void CreateFrame(int routing_id, int parent_routing_id); | 109 static void CreateFrame(int routing_id, |
| 110 int parent_routing_id, |
| 111 const FrameMsg_NewFrame_WidgetParams& params); |
109 | 112 |
110 // Returns the RenderFrameImpl for the given routing ID. | 113 // Returns the RenderFrameImpl for the given routing ID. |
111 static RenderFrameImpl* FromRoutingID(int routing_id); | 114 static RenderFrameImpl* FromRoutingID(int routing_id); |
112 | 115 |
113 // Just like RenderFrame::FromWebFrame but returns the implementation. | 116 // Just like RenderFrame::FromWebFrame but returns the implementation. |
114 static RenderFrameImpl* FromWebFrame(blink::WebFrame* web_frame); | 117 static RenderFrameImpl* FromWebFrame(blink::WebFrame* web_frame); |
115 | 118 |
116 // Used by content_layouttest_support to hook into the creation of | 119 // Used by content_layouttest_support to hook into the creation of |
117 // RenderFrameImpls. | 120 // RenderFrameImpls. |
118 static void InstallCreateHook( | 121 static void InstallCreateHook( |
(...skipping 522 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
641 | 644 |
642 base::WeakPtr<RenderViewImpl> render_view_; | 645 base::WeakPtr<RenderViewImpl> render_view_; |
643 int routing_id_; | 646 int routing_id_; |
644 bool is_swapped_out_; | 647 bool is_swapped_out_; |
645 // RenderFrameProxy exists only when is_swapped_out_ is true. | 648 // RenderFrameProxy exists only when is_swapped_out_ is true. |
646 // TODO(nasko): This can be removed once we don't have a swapped out state on | 649 // TODO(nasko): This can be removed once we don't have a swapped out state on |
647 // RenderFrame. See https://crbug.com/357747. | 650 // RenderFrame. See https://crbug.com/357747. |
648 RenderFrameProxy* render_frame_proxy_; | 651 RenderFrameProxy* render_frame_proxy_; |
649 bool is_detaching_; | 652 bool is_detaching_; |
650 | 653 |
| 654 // Used when the RenderFrame is a local frame root; for now RenderWidgets are |
| 655 // added only when a child frame is in a different process from its parent |
| 656 // frame, but eventually this will also apply to top-level frames. |
| 657 // FIXME(kenrb): Correct the above statement when top-level frames have their |
| 658 // own RenderWidgets. |
| 659 scoped_refptr<RenderWidget> render_widget_; |
| 660 |
651 #if defined(ENABLE_PLUGINS) | 661 #if defined(ENABLE_PLUGINS) |
652 // Current text input composition text. Empty if no composition is in | 662 // Current text input composition text. Empty if no composition is in |
653 // progress. | 663 // progress. |
654 base::string16 pepper_composition_text_; | 664 base::string16 pepper_composition_text_; |
655 #endif | 665 #endif |
656 | 666 |
657 RendererWebCookieJarImpl cookie_jar_; | 667 RendererWebCookieJarImpl cookie_jar_; |
658 | 668 |
659 // All the registered observers. | 669 // All the registered observers. |
660 ObserverList<RenderFrameObserver> observers_; | 670 ObserverList<RenderFrameObserver> observers_; |
(...skipping 97 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
758 #endif | 768 #endif |
759 | 769 |
760 base::WeakPtrFactory<RenderFrameImpl> weak_factory_; | 770 base::WeakPtrFactory<RenderFrameImpl> weak_factory_; |
761 | 771 |
762 DISALLOW_COPY_AND_ASSIGN(RenderFrameImpl); | 772 DISALLOW_COPY_AND_ASSIGN(RenderFrameImpl); |
763 }; | 773 }; |
764 | 774 |
765 } // namespace content | 775 } // namespace content |
766 | 776 |
767 #endif // CONTENT_RENDERER_RENDER_FRAME_IMPL_H_ | 777 #endif // CONTENT_RENDERER_RENDER_FRAME_IMPL_H_ |
OLD | NEW |