Chromium Code Reviews| Index: content/browser/renderer_host/render_widget_host_view_mac.mm |
| diff --git a/content/browser/renderer_host/render_widget_host_view_mac.mm b/content/browser/renderer_host/render_widget_host_view_mac.mm |
| index 9500038092b8c8630da89909a8f4d2ae95452169..b50e7a7839d8a69df840b9669cea3b0ac972a1f0 100644 |
| --- a/content/browser/renderer_host/render_widget_host_view_mac.mm |
| +++ b/content/browser/renderer_host/render_widget_host_view_mac.mm |
| @@ -2355,10 +2355,9 @@ void RenderWidgetHostViewMac::OnDisplayMetricsChanged( |
| } |
| } |
| -// This is invoked only on 10.8 or newer when the user taps a word using |
| -// three fingers. |
| -- (void)quickLookWithEvent:(NSEvent*)event { |
| - NSPoint point = [self convertPoint:[event locationInWindow] fromView:nil]; |
| +- (void)showLookUpDictionaryOverlayAtPoint:(NSPoint)point { |
| + // The PDF plugin does not support getting the attributed string at point. |
|
Alexei Svitkine (slow)
2015/09/03 16:28:11
Nit: Make this a TODO().
Shu Chen
2015/09/04 01:30:20
Done.
|
| + // Please refer to crbug.com/152438. |
| TextInputClientMac::GetInstance()->GetStringAtPoint( |
| renderWidgetHostView_->render_widget_host_, |
| gfx::Point(point.x, NSHeight([self frame]) - point.y), |
| @@ -2373,6 +2372,13 @@ void RenderWidgetHostViewMac::OnDisplayMetricsChanged( |
| ); |
| } |
| +// This is invoked only on 10.8 or newer when the user taps a word using |
| +// three fingers. |
| +- (void)quickLookWithEvent:(NSEvent*)event { |
| + NSPoint point = [self convertPoint:[event locationInWindow] fromView:nil]; |
| + [self showLookUpDictionaryOverlayAtPoint:point]; |
| +} |
| + |
| // This method handles 2 different types of hardware events. |
| // (Apple does not distinguish between them). |
| // a. Scrolling the middle wheel of a mouse. |