| OLD | NEW |
| 1 // Copyright (c) 2013 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2013 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 #include "ash/shell.h" | 5 #include "ash/shell.h" |
| 6 #include "base/strings/string_number_conversions.h" | 6 #include "base/strings/string_number_conversions.h" |
| 7 #include "base/strings/string_split.h" | 7 #include "base/strings/string_split.h" |
| 8 #include "base/strings/string_util.h" | 8 #include "base/strings/string_util.h" |
| 9 #include "base/strings/utf_string_conversions.h" | 9 #include "base/strings/utf_string_conversions.h" |
| 10 #include "chrome/browser/chromeos/input_method/textinput_test_helper.h" | 10 #include "chrome/browser/chromeos/input_method/textinput_test_helper.h" |
| (...skipping 182 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 193 &coordinate)) | 193 &coordinate)) |
| 194 return false; | 194 return false; |
| 195 gfx::Rect rect; | 195 gfx::Rect rect; |
| 196 if (!ConvertRectFromString(coordinate, &rect)) | 196 if (!ConvertRectFromString(coordinate, &rect)) |
| 197 return false; | 197 return false; |
| 198 | 198 |
| 199 blink::WebMouseEvent mouse_event(blink::WebInputEvent::MouseDown, | 199 blink::WebMouseEvent mouse_event(blink::WebInputEvent::MouseDown, |
| 200 blink::WebInputEvent::NoModifiers, | 200 blink::WebInputEvent::NoModifiers, |
| 201 blink::WebInputEvent::TimeStampForTesting); | 201 blink::WebInputEvent::TimeStampForTesting); |
| 202 mouse_event.button = blink::WebMouseEvent::Button::Left; | 202 mouse_event.button = blink::WebMouseEvent::Button::Left; |
| 203 mouse_event.x = rect.CenterPoint().x(); | 203 mouse_event.setPositionInWidget(rect.CenterPoint().x(), |
| 204 mouse_event.y = rect.CenterPoint().y(); | 204 rect.CenterPoint().y()); |
| 205 mouse_event.clickCount = 1; | 205 mouse_event.clickCount = 1; |
| 206 tab->GetRenderViewHost()->GetWidget()->ForwardMouseEvent(mouse_event); | 206 tab->GetRenderViewHost()->GetWidget()->ForwardMouseEvent(mouse_event); |
| 207 | 207 |
| 208 mouse_event.setType(blink::WebInputEvent::MouseUp); | 208 mouse_event.setType(blink::WebInputEvent::MouseUp); |
| 209 tab->GetRenderViewHost()->GetWidget()->ForwardMouseEvent(mouse_event); | 209 tab->GetRenderViewHost()->GetWidget()->ForwardMouseEvent(mouse_event); |
| 210 return true; | 210 return true; |
| 211 } | 211 } |
| 212 | 212 |
| 213 } // namespace chromeos | 213 } // namespace chromeos |
| OLD | NEW |