Chromium Code Reviews| Index: content/browser/renderer_host/render_widget_host_view.cc |
| diff --git a/content/browser/renderer_host/render_widget_host_view.cc b/content/browser/renderer_host/render_widget_host_view.cc |
| index 649faec48c0c0a94e6989f83504b0a009990ca35..3aca8a0a0f0ede042f6e68b80388b2475dd0c75f 100644 |
| --- a/content/browser/renderer_host/render_widget_host_view.cc |
| +++ b/content/browser/renderer_host/render_widget_host_view.cc |
| @@ -45,7 +45,10 @@ void RenderWidgetHostView::GetDefaultScreenInfo( |
| #endif |
| RenderWidgetHostView::RenderWidgetHostView() |
| - : popup_type_(WebKit::WebPopupTypeNone), mouse_locked_(false) { |
| + : popup_type_(WebKit::WebPopupTypeNone), |
| + mouse_locked_(false), |
| + selection_text_offset_(0), |
| + selection_range_(ui::Range::InvalidRange()) { |
| } |
| RenderWidgetHostView::~RenderWidgetHostView() { |
| @@ -55,3 +58,12 @@ RenderWidgetHostView::~RenderWidgetHostView() { |
| void RenderWidgetHostView::SetBackground(const SkBitmap& background) { |
| background_ = background; |
| } |
| + |
| + |
| +void RenderWidgetHostView::SelectionChanged(const string16& text, |
| + size_t offset, |
| + const ui::Range& range) { |
| + selection_text_ = text; |
| + selection_text_offset_ = offset; |
| + selection_range_ = range; |
|
Hironori Bono
2011/10/27 06:17:47
nit: if ui::Range explicitly allows using copy con
Peng
2011/10/27 16:12:24
Done.
|
| +} |