summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorsamuong <samuong@chromium.org>2015-06-08 01:43:20 -0700
committerCommit bot <commit-bot@chromium.org>2015-06-08 08:44:40 +0000
commit87dc4423d6d775443f6e7db2349b9c45e22199b7 (patch)
treee2597d8a6635052acef3b4857fcdbdb397730d0d
parent11d71f820fff62ad406cd5925c816e61403c70de (diff)
downloadchromium_src-87dc4423d6d775443f6e7db2349b9c45e22199b7.zip
chromium_src-87dc4423d6d775443f6e7db2349b9c45e22199b7.tar.gz
chromium_src-87dc4423d6d775443f6e7db2349b9c45e22199b7.tar.bz2
[chromedriver] Avoid using synthetic tap command with KitKat WebView.
BUG=chromedriver:1111 TBR=jbudorick@chromium.org Review URL: https://codereview.chromium.org/1151523013 Cr-Commit-Position: refs/heads/master@{#333253}
-rw-r--r--chrome/test/chromedriver/element_commands.cc7
1 files changed, 3 insertions, 4 deletions
diff --git a/chrome/test/chromedriver/element_commands.cc b/chrome/test/chromedriver/element_commands.cc
index b414cf7..49df717 100644
--- a/chrome/test/chromedriver/element_commands.cc
+++ b/chrome/test/chromedriver/element_commands.cc
@@ -16,7 +16,6 @@
#include "base/time/time.h"
#include "base/values.h"
#include "chrome/test/chromedriver/basic_types.h"
-#include "chrome/test/chromedriver/chrome/browser_info.h"
#include "chrome/test/chromedriver/chrome/chrome.h"
#include "chrome/test/chromedriver/chrome/js.h"
#include "chrome/test/chromedriver/chrome/status.h"
@@ -192,7 +191,7 @@ Status ExecuteTouchSingleTap(
session, web_view, element_id, &location);
if (status.IsError())
return status;
- if (session->chrome->GetBrowserInfo()->build_no < 2388) {
+ if (!session->chrome->HasTouchScreen()) {
// TODO(samuong): remove this once we stop supporting M44.
std::list<TouchEvent> events;
events.push_back(
@@ -210,7 +209,7 @@ Status ExecuteTouchDoubleTap(
const std::string& element_id,
const base::DictionaryValue& params,
scoped_ptr<base::Value>* value) {
- if (session->chrome->GetBrowserInfo()->build_no < 2388) {
+ if (!session->chrome->HasTouchScreen()) {
// TODO(samuong): remove this once we stop supporting M44.
return Status(kUnknownCommand, "Double tap command requires Chrome 44+");
}
@@ -228,7 +227,7 @@ Status ExecuteTouchLongPress(
const std::string& element_id,
const base::DictionaryValue& params,
scoped_ptr<base::Value>* value) {
- if (session->chrome->GetBrowserInfo()->build_no < 2388) {
+ if (!session->chrome->HasTouchScreen()) {
// TODO(samuong): remove this once we stop supporting M44.
return Status(kUnknownCommand, "Long press command requires Chrome 44+");
}