Chromium Code Reviews| Index: content/public/test/browser_test_utils.cc |
| diff --git a/content/public/test/browser_test_utils.cc b/content/public/test/browser_test_utils.cc |
| index f6b9361c2f7d1a16db976294a11f3c4799c078cd..88e375e4dbaa86574fbe41ae6394e174ab414592 100644 |
| --- a/content/public/test/browser_test_utils.cc |
| +++ b/content/public/test/browser_test_utils.cc |
| @@ -223,14 +223,16 @@ void CrashTab(WebContents* web_contents) { |
| observer.Wait(); |
| } |
| -void SimulateMouseClick(WebContents* web_contents) { |
| +void SimulateMouseClick(WebContents* web_contents, int modifiers, |
|
sky
2012/10/23 23:09:28
nit: wrap each param to a new line.
ericu
2012/10/23 23:15:44
Done.
|
| + WebKit::WebMouseEvent::Button button) { |
| int x = web_contents->GetView()->GetContainerSize().width() / 2; |
| int y = web_contents->GetView()->GetContainerSize().height() / 2; |
| WebKit::WebMouseEvent mouse_event; |
| mouse_event.type = WebKit::WebInputEvent::MouseDown; |
| - mouse_event.button = WebKit::WebMouseEvent::ButtonLeft; |
| + mouse_event.button = button; |
| mouse_event.x = x; |
| mouse_event.y = y; |
| + mouse_event.modifiers = modifiers; |
| // Mac needs globalX/globalY for events to plugins. |
| gfx::Rect offset; |
| web_contents->GetView()->GetContainerBounds(&offset); |