Bug 1357590 - Add default button to pointer_up and pointer_down; r=ato
authorMaja Frydrychowicz <mjzffr@gmail.com>
Tue, 18 Apr 2017 18:31:48 -0400
changeset 353855 4750ab2b56f22fb0ead804b0b159585322590d72
parent 353854 c6798f51e462fbc7b44e49abff6ca6443214dd86
child 353856 8fd376fc906071d384783e5c9bd228ba640f7483
push id31680
push userkwierso@gmail.com
push dateWed, 19 Apr 2017 23:57:00 +0000
treeherdermozilla-central@e9a5d4f62461 [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersato
bugs1357590
milestone55.0a1
first release with
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
last release without
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
Bug 1357590 - Add default button to pointer_up and pointer_down; r=ato MozReview-Commit-ID: Ll7O3peSrme
testing/web-platform/tests/tools/webdriver/webdriver/client.py
--- a/testing/web-platform/tests/tools/webdriver/webdriver/client.py
+++ b/testing/web-platform/tests/tools/webdriver/webdriver/client.py
@@ -146,28 +146,30 @@ class ActionSequence(object):
         }
         if duration is not None:
             action["duration"] = duration
         if origin is not None:
             action["origin"] = origin if isinstance(origin, basestring) else origin.json()
         self._actions.append(action)
         return self
 
-    def pointer_up(self, button):
+    def pointer_up(self, button=0):
         """Queue a pointerUp action for `button`.
 
         :param button: Pointer button to perform action with.
+                       Default: 0, which represents main device button.
         """
         self._pointer_action("pointerUp", button)
         return self
 
-    def pointer_down(self, button):
+    def pointer_down(self, button=0):
         """Queue a pointerDown action for `button`.
 
         :param button: Pointer button to perform action with.
+                       Default: 0, which represents main device button.
         """
         self._pointer_action("pointerDown", button)
         return self
 
     def click(self, element=None, button=0):
         """Queue a click with the specified button.
 
         If an element is given, move the pointer to that element first,