Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(2769)

Unified Diff: chrome/test/chromedriver/chrome/web_view_impl.cc

Issue 782133002: [chromedriver] Use error status code decide when to fall back for GoBack/GoForward (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@back-forward-webview
Patch Set: Created 6 years ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/test/chromedriver/chrome/web_view_impl.cc
diff --git a/chrome/test/chromedriver/chrome/web_view_impl.cc b/chrome/test/chromedriver/chrome/web_view_impl.cc
index 806a82c7145d6f26c7679ced3c221bfb44e3384c..a6affc7b7a857588bff5c6811e1ae1c51b12505e 100644
--- a/chrome/test/chromedriver/chrome/web_view_impl.cc
+++ b/chrome/test/chromedriver/chrome/web_view_impl.cc
@@ -177,14 +177,9 @@ Status WebViewImpl::TraverseHistory(int delta) {
// Older versions of WebView on Android (on KitKat and earlier) do not have
// the Page.getNavigationHistory DevTools command handler, so fall back to
// using JavaScript to navigate back and forward. WebView reports its build
- // number as 0, so use the error message to detect if we can't use the
+ // number as 0, so use the error status to detect if we can't use the
// DevTools command.
- std::string message;
- result->GetString("message", &message);
- if (message == "'Page.getNavigationHistory' wasn't found")
- return TraverseHistoryWithJavaScript(delta);
- else
- return status;
+ return TraverseHistoryWithJavaScript(delta);
}
int current_index;
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698