Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(322)

Unified Diff: content/public/test/browser_test_utils.cc

Issue 11235048: Test suite that monitors the disposition of JS-created windows based on what (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Fix style nits Created 8 years, 2 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « content/public/test/browser_test_utils.h ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
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..bf7e3dba9ccf4db2a71f7dd01471dcba1fd08538 100644
--- a/content/public/test/browser_test_utils.cc
+++ b/content/public/test/browser_test_utils.cc
@@ -223,14 +223,17 @@ void CrashTab(WebContents* web_contents) {
observer.Wait();
}
-void SimulateMouseClick(WebContents* web_contents) {
+void SimulateMouseClick(WebContents* web_contents,
+ int modifiers,
+ 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);
« no previous file with comments | « content/public/test/browser_test_utils.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698