| OLD | NEW | 
|---|
| 1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2011 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_WIDGET_H_ | 5 #ifndef CONTENT_RENDERER_RENDER_WIDGET_H_ | 
| 6 #define CONTENT_RENDERER_RENDER_WIDGET_H_ | 6 #define CONTENT_RENDERER_RENDER_WIDGET_H_ | 
| 7 #pragma once | 7 #pragma once | 
| 8 | 8 | 
| 9 #include <vector> | 9 #include <vector> | 
| 10 | 10 | 
| (...skipping 181 matching lines...) Expand 10 before | Expand all | Expand 10 after  Loading... | 
| 192   virtual void OnWasRestored(bool needs_repainting); | 192   virtual void OnWasRestored(bool needs_repainting); | 
| 193   virtual void OnWasSwappedOut(); | 193   virtual void OnWasSwappedOut(); | 
| 194   void OnUpdateRectAck(); | 194   void OnUpdateRectAck(); | 
| 195   void OnCreateVideoAck(int32 video_id); | 195   void OnCreateVideoAck(int32 video_id); | 
| 196   void OnUpdateVideoAck(int32 video_id); | 196   void OnUpdateVideoAck(int32 video_id); | 
| 197   void OnRequestMoveAck(); | 197   void OnRequestMoveAck(); | 
| 198   void OnHandleInputEvent(const IPC::Message& message); | 198   void OnHandleInputEvent(const IPC::Message& message); | 
| 199   void OnMouseCaptureLost(); | 199   void OnMouseCaptureLost(); | 
| 200   virtual void OnSetFocus(bool enable); | 200   virtual void OnSetFocus(bool enable); | 
| 201   void OnSetInputMethodActive(bool is_active); | 201   void OnSetInputMethodActive(bool is_active); | 
| 202   void OnImeSetComposition( | 202   virtual void OnImeSetComposition( | 
| 203       const string16& text, | 203       const string16& text, | 
| 204       const std::vector<WebKit::WebCompositionUnderline>& underlines, | 204       const std::vector<WebKit::WebCompositionUnderline>& underlines, | 
| 205       int selection_start, | 205       int selection_start, | 
| 206       int selection_end); | 206       int selection_end); | 
| 207   void OnImeConfirmComposition(const string16& text); | 207   virtual void OnImeConfirmComposition(const string16& text); | 
| 208   void OnMsgPaintAtSize(const TransportDIB::Handle& dib_id, | 208   void OnMsgPaintAtSize(const TransportDIB::Handle& dib_id, | 
| 209                         int tag, | 209                         int tag, | 
| 210                         const gfx::Size& page_size, | 210                         const gfx::Size& page_size, | 
| 211                         const gfx::Size& desired_size); | 211                         const gfx::Size& desired_size); | 
| 212   void OnMsgRepaint(const gfx::Size& size_to_paint); | 212   void OnMsgRepaint(const gfx::Size& size_to_paint); | 
| 213   void OnSetTextDirection(WebKit::WebTextDirection direction); | 213   void OnSetTextDirection(WebKit::WebTextDirection direction); | 
| 214 | 214 | 
| 215   // Override point to notify derived classes that a paint has happened. | 215   // Override point to notify derived classes that a paint has happened. | 
| 216   // DidInitiatePaint happens when we've generated a new bitmap and sent it to | 216   // DidInitiatePaint happens when we've generated a new bitmap and sent it to | 
| 217   // the browser. DidFlushPaint happens once we've received the ACK that the | 217   // the browser. DidFlushPaint happens once we've received the ACK that the | 
| (...skipping 47 matching lines...) Expand 10 before | Expand all | Expand 10 after  Loading... | 
| 265   bool next_paint_is_resize_ack() const; | 265   bool next_paint_is_resize_ack() const; | 
| 266   bool next_paint_is_restore_ack() const; | 266   bool next_paint_is_restore_ack() const; | 
| 267   void set_next_paint_is_resize_ack(); | 267   void set_next_paint_is_resize_ack(); | 
| 268   void set_next_paint_is_restore_ack(); | 268   void set_next_paint_is_restore_ack(); | 
| 269   void set_next_paint_is_repaint_ack(); | 269   void set_next_paint_is_repaint_ack(); | 
| 270 | 270 | 
| 271   // Checks if the input method state and caret position have been changed. | 271   // Checks if the input method state and caret position have been changed. | 
| 272   // If they are changed, the new value will be sent to the browser process. | 272   // If they are changed, the new value will be sent to the browser process. | 
| 273   void UpdateInputMethod(); | 273   void UpdateInputMethod(); | 
| 274 | 274 | 
|  | 275   // Override point to obtain that the current input method state and caret | 
|  | 276   // position. | 
|  | 277   virtual WebKit::WebTextInputType GetTextInputType(); | 
|  | 278 | 
| 275   // Tells the renderer it does not have focus. Used to prevent us from getting | 279   // Tells the renderer it does not have focus. Used to prevent us from getting | 
| 276   // the focus on our own when the browser did not focus us. | 280   // the focus on our own when the browser did not focus us. | 
| 277   void ClearFocus(); | 281   void ClearFocus(); | 
| 278 | 282 | 
| 279   // Set the pending window rect. | 283   // Set the pending window rect. | 
| 280   // Because the real render_widget is hosted in another process, there is | 284   // Because the real render_widget is hosted in another process, there is | 
| 281   // a time period where we may have set a new window rect which has not yet | 285   // a time period where we may have set a new window rect which has not yet | 
| 282   // been processed by the browser.  So we maintain a pending window rect | 286   // been processed by the browser.  So we maintain a pending window rect | 
| 283   // size.  If JS code sets the WindowRect, and then immediately calls | 287   // size.  If JS code sets the WindowRect, and then immediately calls | 
| 284   // GetWindowRect() we'll use this pending window rect as the size. | 288   // GetWindowRect() we'll use this pending window rect as the size. | 
| (...skipping 138 matching lines...) Expand 10 before | Expand all | Expand 10 after  Loading... | 
| 423   bool animation_update_pending_; | 427   bool animation_update_pending_; | 
| 424   bool animation_task_posted_; | 428   bool animation_task_posted_; | 
| 425   bool invalidation_task_posted_; | 429   bool invalidation_task_posted_; | 
| 426 | 430 | 
| 427   base::TimeTicks last_do_deferred_update_time_; | 431   base::TimeTicks last_do_deferred_update_time_; | 
| 428 | 432 | 
| 429   DISALLOW_COPY_AND_ASSIGN(RenderWidget); | 433   DISALLOW_COPY_AND_ASSIGN(RenderWidget); | 
| 430 }; | 434 }; | 
| 431 | 435 | 
| 432 #endif  // CONTENT_RENDERER_RENDER_WIDGET_H_ | 436 #endif  // CONTENT_RENDERER_RENDER_WIDGET_H_ | 
| OLD | NEW | 
|---|