| 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_WIDGET_HOST_IMPL_H_ | 5 #ifndef CONTENT_BROWSER_RENDERER_HOST_RENDER_WIDGET_HOST_IMPL_H_ | 
| 6 #define CONTENT_BROWSER_RENDERER_HOST_RENDER_WIDGET_HOST_IMPL_H_ | 6 #define CONTENT_BROWSER_RENDERER_HOST_RENDER_WIDGET_HOST_IMPL_H_ | 
| 7 | 7 | 
| 8 #include <deque> | 8 #include <deque> | 
| 9 #include <list> | 9 #include <list> | 
| 10 #include <map> | 10 #include <map> | 
| 11 #include <queue> | 11 #include <queue> | 
| 12 #include <string> | 12 #include <string> | 
|  | 13 #include <utility> | 
| 13 #include <vector> | 14 #include <vector> | 
| 14 | 15 | 
| 15 #include "base/callback.h" | 16 #include "base/callback.h" | 
| 16 #include "base/gtest_prod_util.h" | 17 #include "base/gtest_prod_util.h" | 
| 17 #include "base/memory/scoped_ptr.h" | 18 #include "base/memory/scoped_ptr.h" | 
| 18 #include "base/memory/weak_ptr.h" | 19 #include "base/memory/weak_ptr.h" | 
| 19 #include "base/process_util.h" | 20 #include "base/process_util.h" | 
| 20 #include "base/string16.h" | 21 #include "base/string16.h" | 
| 21 #include "base/time.h" | 22 #include "base/time.h" | 
| 22 #include "base/timer.h" | 23 #include "base/timer.h" | 
| (...skipping 116 matching lines...) Expand 10 before | Expand all | Expand 10 after  Loading... | 
| 139   virtual void Replace(const string16& word) OVERRIDE; | 140   virtual void Replace(const string16& word) OVERRIDE; | 
| 140   virtual void ReplaceMisspelling(const string16& word) OVERRIDE; | 141   virtual void ReplaceMisspelling(const string16& word) OVERRIDE; | 
| 141   virtual void ResizeRectChanged(const gfx::Rect& new_rect) OVERRIDE; | 142   virtual void ResizeRectChanged(const gfx::Rect& new_rect) OVERRIDE; | 
| 142   virtual void RestartHangMonitorTimeout() OVERRIDE; | 143   virtual void RestartHangMonitorTimeout() OVERRIDE; | 
| 143   virtual void SetIgnoreInputEvents(bool ignore_input_events) OVERRIDE; | 144   virtual void SetIgnoreInputEvents(bool ignore_input_events) OVERRIDE; | 
| 144   virtual void Stop() OVERRIDE; | 145   virtual void Stop() OVERRIDE; | 
| 145   virtual void WasResized() OVERRIDE; | 146   virtual void WasResized() OVERRIDE; | 
| 146   virtual void AddKeyboardListener(KeyboardListener* listener) OVERRIDE; | 147   virtual void AddKeyboardListener(KeyboardListener* listener) OVERRIDE; | 
| 147   virtual void RemoveKeyboardListener(KeyboardListener* listener) OVERRIDE; | 148   virtual void RemoveKeyboardListener(KeyboardListener* listener) OVERRIDE; | 
| 148   virtual void GetWebScreenInfo(WebKit::WebScreenInfo* result) OVERRIDE; | 149   virtual void GetWebScreenInfo(WebKit::WebScreenInfo* result) OVERRIDE; | 
|  | 150   virtual void GetSnapshotFromRenderer( | 
|  | 151       const gfx::Rect& src_subrect, | 
|  | 152       const gfx::Size& dst_size, | 
|  | 153       const base::Callback<void(bool, const SkBitmap&)>& callback) OVERRIDE; | 
| 149 | 154 | 
| 150   // Notification that the screen info has changed. | 155   // Notification that the screen info has changed. | 
| 151   void NotifyScreenInfoChanged(); | 156   void NotifyScreenInfoChanged(); | 
| 152 | 157 | 
| 153   // Sets the View of this RenderWidgetHost. | 158   // Sets the View of this RenderWidgetHost. | 
| 154   void SetView(RenderWidgetHostView* view); | 159   void SetView(RenderWidgetHostView* view); | 
| 155 | 160 | 
| 156   int surface_id() const { return surface_id_; } | 161   int surface_id() const { return surface_id_; } | 
| 157 | 162 | 
| 158   bool empty() const { return current_size_.IsEmpty(); } | 163   bool empty() const { return current_size_.IsEmpty(); } | 
| (...skipping 436 matching lines...) Expand 10 before | Expand all | Expand 10 after  Loading... | 
| 595   void OnUnlockMouse(); | 600   void OnUnlockMouse(); | 
| 596   void OnShowDisambiguationPopup(const gfx::Rect& rect, | 601   void OnShowDisambiguationPopup(const gfx::Rect& rect, | 
| 597                                  const gfx::Size& size, | 602                                  const gfx::Size& size, | 
| 598                                  const TransportDIB::Id& id); | 603                                  const TransportDIB::Id& id); | 
| 599 #if defined(OS_WIN) | 604 #if defined(OS_WIN) | 
| 600   void OnWindowlessPluginDummyWindowCreated( | 605   void OnWindowlessPluginDummyWindowCreated( | 
| 601       gfx::NativeViewId dummy_activation_window); | 606       gfx::NativeViewId dummy_activation_window); | 
| 602   void OnWindowlessPluginDummyWindowDestroyed( | 607   void OnWindowlessPluginDummyWindowDestroyed( | 
| 603       gfx::NativeViewId dummy_activation_window); | 608       gfx::NativeViewId dummy_activation_window); | 
| 604 #endif | 609 #endif | 
|  | 610   void OnSnapshot(bool success, const SkBitmap& bitmap); | 
| 605 | 611 | 
| 606   // Called (either immediately or asynchronously) after we're done with our | 612   // Called (either immediately or asynchronously) after we're done with our | 
| 607   // BackingStore and can send an ACK to the renderer so it can paint onto it | 613   // BackingStore and can send an ACK to the renderer so it can paint onto it | 
| 608   // again. | 614   // again. | 
| 609   void DidUpdateBackingStore(const ViewHostMsg_UpdateRect_Params& params, | 615   void DidUpdateBackingStore(const ViewHostMsg_UpdateRect_Params& params, | 
| 610                              const base::TimeTicks& paint_start); | 616                              const base::TimeTicks& paint_start); | 
| 611 | 617 | 
| 612   // Paints the given bitmap to the current backing store at the given | 618   // Paints the given bitmap to the current backing store at the given | 
| 613   // location.  Returns true if the passed callback was asynchronously | 619   // location.  Returns true if the passed callback was asynchronously | 
| 614   // scheduled in the future (and thus the caller must manually synchronously | 620   // scheduled in the future (and thus the caller must manually synchronously | 
| (...skipping 235 matching lines...) Expand 10 before | Expand all | Expand 10 after  Loading... | 
| 850   typedef std::map<int, scoped_refptr<SmoothScrollGesture> > | 856   typedef std::map<int, scoped_refptr<SmoothScrollGesture> > | 
| 851       SmoothScrollGestureMap; | 857       SmoothScrollGestureMap; | 
| 852   SmoothScrollGestureMap active_smooth_scroll_gestures_; | 858   SmoothScrollGestureMap active_smooth_scroll_gestures_; | 
| 853   base::TimeTicks last_smooth_scroll_gestures_tick_time_; | 859   base::TimeTicks last_smooth_scroll_gestures_tick_time_; | 
| 854   bool tick_active_smooth_scroll_gestures_task_posted_; | 860   bool tick_active_smooth_scroll_gestures_task_posted_; | 
| 855 | 861 | 
| 856   scoped_ptr<TouchEventQueue> touch_event_queue_; | 862   scoped_ptr<TouchEventQueue> touch_event_queue_; | 
| 857   scoped_ptr<GestureEventFilter> gesture_event_filter_; | 863   scoped_ptr<GestureEventFilter> gesture_event_filter_; | 
| 858   scoped_ptr<OverscrollController> overscroll_controller_; | 864   scoped_ptr<OverscrollController> overscroll_controller_; | 
| 859 | 865 | 
|  | 866   typedef std::pair<gfx::Size, base::Callback<void(bool, const SkBitmap&)> > | 
|  | 867       PendingSnapshotInfo; | 
|  | 868   std::queue<PendingSnapshotInfo> pending_snapshots_; | 
|  | 869 | 
| 860 #if defined(OS_WIN) | 870 #if defined(OS_WIN) | 
| 861   std::list<HWND> dummy_windows_for_activation_; | 871   std::list<HWND> dummy_windows_for_activation_; | 
| 862 #endif | 872 #endif | 
| 863 | 873 | 
| 864   DISALLOW_COPY_AND_ASSIGN(RenderWidgetHostImpl); | 874   DISALLOW_COPY_AND_ASSIGN(RenderWidgetHostImpl); | 
| 865 }; | 875 }; | 
| 866 | 876 | 
| 867 }  // namespace content | 877 }  // namespace content | 
| 868 | 878 | 
| 869 #endif  // CONTENT_BROWSER_RENDERER_HOST_RENDER_WIDGET_HOST_IMPL_H_ | 879 #endif  // CONTENT_BROWSER_RENDERER_HOST_RENDER_WIDGET_HOST_IMPL_H_ | 
| OLD | NEW | 
|---|