Index: chrome/test/android/javatests/src/org/chromium/chrome/test/util/browser/contextmenu/ContextMenuUtils.java |
diff --git a/chrome/test/android/javatests/src/org/chromium/chrome/test/util/browser/contextmenu/ContextMenuUtils.java b/chrome/test/android/javatests/src/org/chromium/chrome/test/util/browser/contextmenu/ContextMenuUtils.java |
index a0635e399c28a204be59becb1d9c62b498d57220..abbdc747d0d19c2503f807bc8465040420586a89 100644 |
--- a/chrome/test/android/javatests/src/org/chromium/chrome/test/util/browser/contextmenu/ContextMenuUtils.java |
+++ b/chrome/test/android/javatests/src/org/chromium/chrome/test/util/browser/contextmenu/ContextMenuUtils.java |
@@ -87,7 +87,6 @@ |
* @param tab The tab to open a context menu for. |
* @param openerDOMNodeId The DOM node to long press to open the context menu for. |
* @param itemId The context menu item ID to select. |
- * @param activity The activity to assert for gaining focus after click or null. |
* @throws InterruptedException |
* @throws TimeoutException |
*/ |
@@ -104,7 +103,6 @@ |
* @param jsCode The javascript to get the DOM node to long press |
* to open the context menu for. |
* @param itemId The context menu item ID to select. |
- * @param activity The activity to assert for gaining focus after click or null. |
* @throws InterruptedException |
* @throws TimeoutException |
*/ |
@@ -159,14 +157,11 @@ |
} |
}); |
- if (activity != null) { |
- CriteriaHelper.pollInstrumentationThread( |
- new Criteria("Activity did not regain focus.") { |
- @Override |
- public boolean isSatisfied() { |
- return activity.hasWindowFocus(); |
- } |
- }); |
- } |
+ CriteriaHelper.pollInstrumentationThread(new Criteria("Activity did not regain focus.") { |
+ @Override |
+ public boolean isSatisfied() { |
+ return activity.hasWindowFocus(); |
+ } |
+ }); |
} |
} |