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_RENDERER_RENDER_VIEW_IMPL_H_ | 5 #ifndef CONTENT_RENDERER_RENDER_VIEW_IMPL_H_ |
6 #define CONTENT_RENDERER_RENDER_VIEW_IMPL_H_ | 6 #define CONTENT_RENDERER_RENDER_VIEW_IMPL_H_ |
7 | 7 |
8 #include <stddef.h> | 8 #include <stddef.h> |
9 #include <stdint.h> | 9 #include <stdint.h> |
10 | 10 |
(...skipping 240 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
251 PepperPluginInstanceImpl* focused_pepper_plugin() { | 251 PepperPluginInstanceImpl* focused_pepper_plugin() { |
252 return focused_pepper_plugin_; | 252 return focused_pepper_plugin_; |
253 } | 253 } |
254 PepperPluginInstanceImpl* pepper_last_mouse_event_target() { | 254 PepperPluginInstanceImpl* pepper_last_mouse_event_target() { |
255 return pepper_last_mouse_event_target_; | 255 return pepper_last_mouse_event_target_; |
256 } | 256 } |
257 void set_pepper_last_mouse_event_target(PepperPluginInstanceImpl* plugin) { | 257 void set_pepper_last_mouse_event_target(PepperPluginInstanceImpl* plugin) { |
258 pepper_last_mouse_event_target_ = plugin; | 258 pepper_last_mouse_event_target_ = plugin; |
259 } | 259 } |
260 | 260 |
261 #if defined(OS_MACOSX) | |
262 // Informs the render view that the given plugin has gained or lost focus. | |
263 void PluginFocusChanged(bool focused, int plugin_id); | |
264 | |
265 // Starts plugin IME. | |
266 void StartPluginIme(); | |
267 #endif | |
268 | |
269 // Indicates that the given instance has been created. | 261 // Indicates that the given instance has been created. |
270 void PepperInstanceCreated(PepperPluginInstanceImpl* instance); | 262 void PepperInstanceCreated(PepperPluginInstanceImpl* instance); |
271 | 263 |
272 // Indicates that the given instance is being destroyed. This is called from | 264 // Indicates that the given instance is being destroyed. This is called from |
273 // the destructor, so it's important that the instance is not dereferenced | 265 // the destructor, so it's important that the instance is not dereferenced |
274 // from this call. | 266 // from this call. |
275 void PepperInstanceDeleted(PepperPluginInstanceImpl* instance); | 267 void PepperInstanceDeleted(PepperPluginInstanceImpl* instance); |
276 | 268 |
277 // Notification that the given plugin is focused or unfocused. | 269 // Notification that the given plugin is focused or unfocused. |
278 void PepperFocusChanged(PepperPluginInstanceImpl* instance, bool focused); | 270 void PepperFocusChanged(PepperPluginInstanceImpl* instance, bool focused); |
279 | |
280 void RegisterPluginDelegate(WebPluginDelegateProxy* delegate); | |
281 void UnregisterPluginDelegate(WebPluginDelegateProxy* delegate); | |
282 #endif // ENABLE_PLUGINS | 271 #endif // ENABLE_PLUGINS |
283 | 272 |
284 void TransferActiveWheelFlingAnimation( | 273 void TransferActiveWheelFlingAnimation( |
285 const blink::WebActiveWheelFlingParameters& params); | 274 const blink::WebActiveWheelFlingParameters& params); |
286 | 275 |
287 // Starts a timer to send an UpdateState message on behalf of |frame|, if the | 276 // Starts a timer to send an UpdateState message on behalf of |frame|, if the |
288 // timer isn't already running. This allows multiple state changing events to | 277 // timer isn't already running. This allows multiple state changing events to |
289 // be coalesced into one update. | 278 // be coalesced into one update. |
290 void StartNavStateSyncTimerIfNecessary(RenderFrameImpl* frame); | 279 void StartNavStateSyncTimerIfNecessary(RenderFrameImpl* frame); |
291 | 280 |
(...skipping 385 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
677 void OnForceRedraw(int request_id); | 666 void OnForceRedraw(int request_id); |
678 void OnSelectWordAroundCaret(); | 667 void OnSelectWordAroundCaret(); |
679 #if defined(OS_ANDROID) | 668 #if defined(OS_ANDROID) |
680 void OnUndoScrollFocusedEditableNodeIntoRect(); | 669 void OnUndoScrollFocusedEditableNodeIntoRect(); |
681 void OnUpdateTopControlsState(bool enable_hiding, | 670 void OnUpdateTopControlsState(bool enable_hiding, |
682 bool enable_showing, | 671 bool enable_showing, |
683 bool animate); | 672 bool animate); |
684 void OnExtractSmartClipData(const gfx::Rect& rect); | 673 void OnExtractSmartClipData(const gfx::Rect& rect); |
685 #elif defined(OS_MACOSX) | 674 #elif defined(OS_MACOSX) |
686 void OnGetRenderedText(); | 675 void OnGetRenderedText(); |
687 void OnPluginImeCompositionCompleted(const base::string16& text, | |
688 int plugin_id); | |
689 void OnSetWindowVisibility(bool visible); | |
690 void OnWindowFrameChanged(const gfx::Rect& window_frame, | |
691 const gfx::Rect& view_frame); | |
692 #endif | 676 #endif |
693 | 677 |
694 // Page message handlers ----------------------------------------------------- | 678 // Page message handlers ----------------------------------------------------- |
695 void OnUpdateWindowScreenRect(gfx::Rect window_screen_rect); | 679 void OnUpdateWindowScreenRect(gfx::Rect window_screen_rect); |
696 | 680 |
697 // Adding a new message handler? Please add it in alphabetical order above | 681 // Adding a new message handler? Please add it in alphabetical order above |
698 // and put it in the same position in the .cc file. | 682 // and put it in the same position in the .cc file. |
699 | 683 |
700 // Misc private functions ---------------------------------------------------- | 684 // Misc private functions ---------------------------------------------------- |
701 // Check whether the preferred size has changed. | 685 // Check whether the preferred size has changed. |
(...skipping 224 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
926 size_t expected_content_intent_id_; | 910 size_t expected_content_intent_id_; |
927 | 911 |
928 // List of click-based content detectors. | 912 // List of click-based content detectors. |
929 std::vector<scoped_ptr<ContentDetector>> content_detectors_; | 913 std::vector<scoped_ptr<ContentDetector>> content_detectors_; |
930 | 914 |
931 // A date/time picker object for date and time related input elements. | 915 // A date/time picker object for date and time related input elements. |
932 scoped_ptr<RendererDateTimePicker> date_time_picker_client_; | 916 scoped_ptr<RendererDateTimePicker> date_time_picker_client_; |
933 #endif | 917 #endif |
934 | 918 |
935 // Plugins ------------------------------------------------------------------- | 919 // Plugins ------------------------------------------------------------------- |
936 | |
937 // All the currently active plugin delegates for this RenderView; kept so | |
938 // that we can enumerate them to send updates about things like window | |
939 // location or tab focus and visibily. These are non-owning references. | |
940 std::set<WebPluginDelegateProxy*> plugin_delegates_; | |
941 | |
942 #if defined(ENABLE_PLUGINS) | 920 #if defined(ENABLE_PLUGINS) |
943 typedef std::set<PepperPluginInstanceImpl*> PepperPluginSet; | 921 typedef std::set<PepperPluginInstanceImpl*> PepperPluginSet; |
944 PepperPluginSet active_pepper_instances_; | 922 PepperPluginSet active_pepper_instances_; |
945 | 923 |
946 // TODO(jam): these belong on RenderFrame, once the browser knows which frame | 924 // TODO(jam): these belong on RenderFrame, once the browser knows which frame |
947 // is focused and sends the IPCs which use these to the correct frame. Until | 925 // is focused and sends the IPCs which use these to the correct frame. Until |
948 // then, we must store these on RenderView as that's the one place that knows | 926 // then, we must store these on RenderView as that's the one place that knows |
949 // about all the RenderFrames for a page. | 927 // about all the RenderFrames for a page. |
950 | 928 |
951 // Whether or not the focus is on a PPAPI plugin | 929 // Whether or not the focus is on a PPAPI plugin |
(...skipping 55 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1007 // use the Observer interface to filter IPC messages and receive frame change | 985 // use the Observer interface to filter IPC messages and receive frame change |
1008 // notifications. | 986 // notifications. |
1009 // --------------------------------------------------------------------------- | 987 // --------------------------------------------------------------------------- |
1010 | 988 |
1011 DISALLOW_COPY_AND_ASSIGN(RenderViewImpl); | 989 DISALLOW_COPY_AND_ASSIGN(RenderViewImpl); |
1012 }; | 990 }; |
1013 | 991 |
1014 } // namespace content | 992 } // namespace content |
1015 | 993 |
1016 #endif // CONTENT_RENDERER_RENDER_VIEW_IMPL_H_ | 994 #endif // CONTENT_RENDERER_RENDER_VIEW_IMPL_H_ |
OLD | NEW |