summaryrefslogtreecommitdiff
path: root/test-runner
diff options
context:
space:
mode:
Diffstat (limited to 'test-runner')
-rw-r--r--test-runner/src/android/test/TouchUtils.java3
1 files changed, 2 insertions, 1 deletions
diff --git a/test-runner/src/android/test/TouchUtils.java b/test-runner/src/android/test/TouchUtils.java
index 28dc7b2f900c..bb4e00ba1ef9 100644
--- a/test-runner/src/android/test/TouchUtils.java
+++ b/test-runner/src/android/test/TouchUtils.java
@@ -222,7 +222,8 @@ public class TouchUtils {
*/
public static void dragViewToBottom(InstrumentationTestCase test, Activity activity, View v,
int stepCount) {
- int screenHeight = activity.getWindowManager().getDefaultDisplay().getHeight();
+ int screenHeight =
+ activity.getWindowManager().getCurrentWindowMetrics().getSize().getHeight();
int[] xy = new int[2];
v.getLocationOnScreen(xy);