Index: chrome/test/pyautolib/pyauto.py |
diff --git a/chrome/test/pyautolib/pyauto.py b/chrome/test/pyautolib/pyauto.py |
index 3638e10225870212dd68a97d26113d040b6d5370..d09c663bc88eb55dc937c52d6c60a6166bb6c494 100755 |
--- a/chrome/test/pyautolib/pyauto.py |
+++ b/chrome/test/pyautolib/pyauto.py |
@@ -1840,13 +1840,14 @@ class PyUITest(pyautolib.PyUITestBase, unittest.TestCase): |
} |
self._GetResultFromJSONRequest(cmd_dict) |
- def TriggerPageActionById(self, id, windex=0): |
+ def TriggerPageActionById(self, id, tab_index=0, windex=0): |
"""Trigger page action asynchronously in the active tab. |
The page action icon must be displayed before invoking this function. |
Args: |
id: The string id of the extension. |
+ tab_index: Integer index of the tab to use; defaults to 0 (first tab). |
windex: Integer index of the browser window to use; defaults to 0 |
(first window). |
""" |
@@ -1854,14 +1855,16 @@ class PyUITest(pyautolib.PyUITestBase, unittest.TestCase): |
'command': 'TriggerPageActionById', |
'id': id, |
'windex': windex, |
+ 'tab_index': tab_index, |
} |
self._GetResultFromJSONRequest(cmd_dict, windex=windex) |
- def TriggerBrowserActionById(self, id, windex=0): |
+ def TriggerBrowserActionById(self, id, tab_index=0, windex=0): |
"""Trigger browser action asynchronously in the active tab. |
Args: |
id: The string id of the extension. |
+ tab_index: Integer index of the tab to use; defaults to 0 (first tab). |
windex: Integer index of the browser window to use; defaults to 0 |
(first window). |
""" |
@@ -1869,6 +1872,7 @@ class PyUITest(pyautolib.PyUITestBase, unittest.TestCase): |
'command': 'TriggerBrowserActionById', |
'id': id, |
'windex': windex, |
+ 'tab_index': tab_index, |
} |
self._GetResultFromJSONRequest(cmd_dict, windex=windex) |