summaryrefslogtreecommitdiff
path: root/chromium/content/browser/renderer_host/render_widget_host_impl.h
diff options
context:
space:
mode:
Diffstat (limited to 'chromium/content/browser/renderer_host/render_widget_host_impl.h')
-rw-r--r--chromium/content/browser/renderer_host/render_widget_host_impl.h50
1 files changed, 24 insertions, 26 deletions
diff --git a/chromium/content/browser/renderer_host/render_widget_host_impl.h b/chromium/content/browser/renderer_host/render_widget_host_impl.h
index d5d9d5ad654..04984b1e87f 100644
--- a/chromium/content/browser/renderer_host/render_widget_host_impl.h
+++ b/chromium/content/browser/renderer_host/render_widget_host_impl.h
@@ -46,10 +46,14 @@
#include "ui/events/latency_info.h"
#include "ui/gfx/native_widget_types.h"
+struct FrameHostMsg_HittestData_Params;
struct ViewHostMsg_SelectionBounds_Params;
struct ViewHostMsg_TextInputState_Params;
struct ViewHostMsg_UpdateRect_Params;
-struct ViewMsg_Resize_Params;
+
+namespace base {
+class RefCountedBytes;
+}
namespace blink {
class WebInputEvent;
@@ -81,6 +85,7 @@ class TimeoutMonitor;
class TouchEmulator;
class WebCursor;
struct EditCommand;
+struct ResizeParams;
// This implements the RenderWidgetHost interface that is exposed to
// embedders of content, and adds things only visible to content.
@@ -289,7 +294,7 @@ class CONTENT_EXPORT RenderWidgetHostImpl : public RenderWidgetHost,
// when it has received a message.
void ForwardGestureEventWithLatencyInfo(
const blink::WebGestureEvent& gesture_event,
- const ui::LatencyInfo& ui_latency);
+ const ui::LatencyInfo& ui_latency) override;
void ForwardTouchEventWithLatencyInfo(
const blink::WebTouchEvent& touch_event,
const ui::LatencyInfo& ui_latency);
@@ -338,6 +343,7 @@ class CONTENT_EXPORT RenderWidgetHostImpl : public RenderWidgetHost,
void ImeSetComposition(
const base::string16& text,
const std::vector<blink::WebCompositionUnderline>& underlines,
+ const gfx::Range& replacement_range,
int selection_start,
int selection_end);
@@ -469,10 +475,6 @@ class CONTENT_EXPORT RenderWidgetHostImpl : public RenderWidgetHost,
void RejectMouseLockOrUnlockIfNecessary();
-#if defined(OS_WIN)
- gfx::NativeViewAccessible GetParentNativeViewAccessible();
-#endif
-
void set_renderer_initialized(bool renderer_initialized) {
renderer_initialized_ = renderer_initialized;
}
@@ -485,11 +487,11 @@ class CONTENT_EXPORT RenderWidgetHostImpl : public RenderWidgetHost,
// Fills in the |resize_params| struct.
// Returns |false| if the update is redundant, |true| otherwise.
- bool GetResizeParams(ViewMsg_Resize_Params* resize_params);
+ bool GetResizeParams(ResizeParams* resize_params);
// Sets the |resize_params| that were sent to the renderer bundled with the
// request to create a new RenderWidget.
- void SetInitialRenderSizeParams(const ViewMsg_Resize_Params& resize_params);
+ void SetInitialRenderSizeParams(const ResizeParams& resize_params);
// Called when we receive a notification indicating that the renderer process
// is gone. This will reset our state so that our state will be consistent if
@@ -506,6 +508,11 @@ class CONTENT_EXPORT RenderWidgetHostImpl : public RenderWidgetHost,
bool renderer_initialized() const { return renderer_initialized_; }
+ bool scale_input_to_viewport() const { return scale_input_to_viewport_; }
+ void set_scale_input_to_viewport(bool scale_input_to_viewport) {
+ scale_input_to_viewport_ = scale_input_to_viewport;
+ }
+
protected:
// Retrieves an id the renderer can use to refer to its view.
// This is used for various IPC messages, including plugins.
@@ -578,18 +585,13 @@ class CONTENT_EXPORT RenderWidgetHostImpl : public RenderWidgetHost,
void OnShowDisambiguationPopup(const gfx::Rect& rect_pixels,
const gfx::Size& size,
const cc::SharedBitmapId& id);
-#if defined(OS_WIN)
- void OnWindowlessPluginDummyWindowCreated(
- gfx::NativeViewId dummy_activation_window);
- void OnWindowlessPluginDummyWindowDestroyed(
- gfx::NativeViewId dummy_activation_window);
-#endif
void OnSelectionChanged(const base::string16& text,
- size_t offset,
+ uint32_t offset,
const gfx::Range& range);
void OnSelectionBoundsChanged(
const ViewHostMsg_SelectionBounds_Params& params);
void OnForwardCompositorProto(const std::vector<uint8_t>& proto);
+ void OnHittestData(const FrameHostMsg_HittestData_Params& params);
// Called (either immediately or asynchronously) after we're done with our
// BackingStore and can send an ACK to the renderer so it can paint onto it
@@ -684,7 +686,7 @@ class CONTENT_EXPORT RenderWidgetHostImpl : public RenderWidgetHost,
gfx::Size current_size_;
// Resize information that was previously sent to the renderer.
- scoped_ptr<ViewMsg_Resize_Params> old_resize_params_;
+ scoped_ptr<ResizeParams> old_resize_params_;
// The next auto resize to send.
gfx::Size new_auto_size_;
@@ -767,7 +769,8 @@ class CONTENT_EXPORT RenderWidgetHostImpl : public RenderWidgetHost,
// TODO(wjmaclean) Remove the code for supporting resending gesture events
// when WebView transitions to OOPIF and BrowserPlugin is removed.
// http://crbug.com/533069
- bool is_in_gesture_scroll_;
+ bool is_in_touchpad_gesture_scroll_;
+ bool is_in_touchscreen_gesture_scroll_;
scoped_ptr<SyntheticGestureController> synthetic_gesture_controller_;
@@ -792,10 +795,6 @@ class CONTENT_EXPORT RenderWidgetHostImpl : public RenderWidgetHost,
// being sent, in which case the timer should fire).
bool received_paint_after_load_;
-#if defined(OS_WIN)
- std::list<HWND> dummy_windows_for_activation_;
-#endif
-
RenderWidgetHostLatencyTracker latency_tracker_;
int next_browser_snapshot_id_;
@@ -812,6 +811,10 @@ class CONTENT_EXPORT RenderWidgetHostImpl : public RenderWidgetHost,
// causing HasFocus to return false when is_focused_ is true.
bool is_focused_;
+ // When true, the host will scale the input to viewport.
+ // TODO(oshima): Remove this once crbug.com/563730 is addressed.
+ bool scale_input_to_viewport_;
+
// This value indicates how long to wait before we consider a renderer hung.
base::TimeDelta hung_renderer_delay_;
@@ -819,11 +822,6 @@ class CONTENT_EXPORT RenderWidgetHostImpl : public RenderWidgetHost,
// renderer process before clearing any previously displayed content.
base::TimeDelta new_content_rendering_delay_;
- // Timer used to batch together mouse wheel events for the delegate
- // OnUserInteraction method. A wheel event is only dispatched when a wheel
- // event has not been seen for kMouseWheelCoalesceInterval seconds prior.
- scoped_ptr<base::ElapsedTimer> mouse_wheel_coalesce_timer_;
-
base::WeakPtrFactory<RenderWidgetHostImpl> weak_factory_;
DISALLOW_COPY_AND_ASSIGN(RenderWidgetHostImpl);