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

Side by Side Diff: content/browser/renderer_host/render_widget_host_impl.h

Issue 10823077: Throttle SelectRange IPC (Closed) Base URL: http://git.chromium.org/chromium/src.git@master
Patch Set: Better member variable names Created 8 years, 4 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 (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 <string> 9 #include <string>
10 #include <utility>
10 #include <vector> 11 #include <vector>
11 12
12 #include "base/callback.h" 13 #include "base/callback.h"
13 #include "base/gtest_prod_util.h" 14 #include "base/gtest_prod_util.h"
14 #include "base/memory/scoped_ptr.h" 15 #include "base/memory/scoped_ptr.h"
15 #include "base/memory/weak_ptr.h" 16 #include "base/memory/weak_ptr.h"
16 #include "base/process_util.h" 17 #include "base/process_util.h"
17 #include "base/property_bag.h" 18 #include "base/property_bag.h"
18 #include "base/string16.h" 19 #include "base/string16.h"
19 #include "base/timer.h" 20 #include "base/timer.h"
(...skipping 478 matching lines...) Expand 10 before | Expand all | Expand 10 after
498 void OnMsgPaintAtSizeAck(int tag, const gfx::Size& size); 499 void OnMsgPaintAtSizeAck(int tag, const gfx::Size& size);
499 void OnCompositorSurfaceBuffersSwapped(int32 surface_id, 500 void OnCompositorSurfaceBuffersSwapped(int32 surface_id,
500 uint64 surface_handle, 501 uint64 surface_handle,
501 int32 route_id, 502 int32 route_id,
502 int32 gpu_process_host_id); 503 int32 gpu_process_host_id);
503 void OnMsgUpdateRect(const ViewHostMsg_UpdateRect_Params& params); 504 void OnMsgUpdateRect(const ViewHostMsg_UpdateRect_Params& params);
504 void OnMsgUpdateIsDelayed(); 505 void OnMsgUpdateIsDelayed();
505 void OnMsgInputEventAck(WebKit::WebInputEvent::Type event_type, 506 void OnMsgInputEventAck(WebKit::WebInputEvent::Type event_type,
506 bool processed); 507 bool processed);
507 void OnMsgBeginSmoothScroll(bool scroll_down, bool scroll_far); 508 void OnMsgBeginSmoothScroll(bool scroll_down, bool scroll_far);
509 void OnMsgSelectRangeAck();
508 virtual void OnMsgFocus(); 510 virtual void OnMsgFocus();
509 virtual void OnMsgBlur(); 511 virtual void OnMsgBlur();
510 void OnMsgHasTouchEventHandlers(bool has_handlers); 512 void OnMsgHasTouchEventHandlers(bool has_handlers);
511 513
512 void OnMsgSetCursor(const WebCursor& cursor); 514 void OnMsgSetCursor(const WebCursor& cursor);
513 void OnMsgTextInputStateChanged(ui::TextInputType type, 515 void OnMsgTextInputStateChanged(ui::TextInputType type,
514 bool can_compose_inline); 516 bool can_compose_inline);
515 void OnMsgImeCompositionRangeChanged( 517 void OnMsgImeCompositionRangeChanged(
516 const ui::Range& range, 518 const ui::Range& range,
517 const std::vector<gfx::Rect>& character_bounds); 519 const std::vector<gfx::Rect>& character_bounds);
(...skipping 161 matching lines...) Expand 10 before | Expand all | Expand 10 after
679 // (Similar to |mouse_wheel_pending_|.). True if gesture event was sent and 681 // (Similar to |mouse_wheel_pending_|.). True if gesture event was sent and
680 // we are waiting for a corresponding ack. 682 // we are waiting for a corresponding ack.
681 bool gesture_event_pending_; 683 bool gesture_event_pending_;
682 684
683 typedef std::deque<WebKit::WebGestureEvent> GestureEventQueue; 685 typedef std::deque<WebKit::WebGestureEvent> GestureEventQueue;
684 686
685 // (Similar to |coalesced_mouse_wheel_events_|.) GestureScrollUpdate events 687 // (Similar to |coalesced_mouse_wheel_events_|.) GestureScrollUpdate events
686 // are coalesced by merging deltas in a similar fashion as wheel events. 688 // are coalesced by merging deltas in a similar fashion as wheel events.
687 GestureEventQueue coalesced_gesture_events_; 689 GestureEventQueue coalesced_gesture_events_;
688 690
691 // (Similar to |mouse_move_pending_|.) True while waiting for SelectRange_ACK.
692 bool select_range_pending_;
693
694 // (Similar to |next_mouse_move_|.) The next SelectRange to send, if any.
695 scoped_ptr<std::pair<gfx::Point, gfx::Point> > next_select_range_;
darin (slow to review) 2012/08/02 16:37:17 Please just define a struct instead of using std::
Iain Merrick 2012/08/06 11:28:45 Done.
696
689 // The time when an input event was sent to the RenderWidget. 697 // The time when an input event was sent to the RenderWidget.
690 base::TimeTicks input_event_start_time_; 698 base::TimeTicks input_event_start_time_;
691 699
692 // Keyboard event listeners. 700 // Keyboard event listeners.
693 std::list<KeyboardListener*> keyboard_listeners_; 701 std::list<KeyboardListener*> keyboard_listeners_;
694 702
695 // If true, then we should repaint when restoring even if we have a 703 // If true, then we should repaint when restoring even if we have a
696 // backingstore. This flag is set to true if we receive a paint message 704 // backingstore. This flag is set to true if we receive a paint message
697 // while is_hidden_ to true. Even though we tell the render widget to hide 705 // while is_hidden_ to true. Even though we tell the render widget to hide
698 // itself, a paint message could already be in flight at that point. 706 // itself, a paint message could already be in flight at that point.
(...skipping 79 matching lines...) Expand 10 before | Expand all | Expand 10 after
778 scoped_ptr<TapSuppressionController> tap_suppression_controller_; 786 scoped_ptr<TapSuppressionController> tap_suppression_controller_;
779 787
780 scoped_ptr<SmoothScrollGesture> active_smooth_scroll_gesture_; 788 scoped_ptr<SmoothScrollGesture> active_smooth_scroll_gesture_;
781 789
782 DISALLOW_COPY_AND_ASSIGN(RenderWidgetHostImpl); 790 DISALLOW_COPY_AND_ASSIGN(RenderWidgetHostImpl);
783 }; 791 };
784 792
785 } // namespace content 793 } // namespace content
786 794
787 #endif // CONTENT_BROWSER_RENDERER_HOST_RENDER_WIDGET_HOST_IMPL_H_ 795 #endif // CONTENT_BROWSER_RENDERER_HOST_RENDER_WIDGET_HOST_IMPL_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698