[Android] Restricting Smart Go Next only in Android

Current implementation of Smart Go Next will execute for
all platforms because of calculation logic touches blink.
Now restricting this logic only in Android platform. Due to
a regression in blink wrt element focus time, currently applying
a threshold of focus calculation.

Bug: 781026
Change-Id: I96c60e15186bddae087345f2d5b25a359dd4ac48
Reviewed-on: https://chromium-review.googlesource.com/758481
Commit-Queue: Takayoshi Kochi <[email protected]>
Reviewed-by: Daniel Cheng <[email protected]>
Reviewed-by: Changwan Ryu <[email protected]>
Reviewed-by: Nasko Oskov <[email protected]>
Reviewed-by: Takayoshi Kochi <[email protected]>
Cr-Commit-Position: refs/heads/master@{#516124}
diff --git a/content/renderer/render_widget.cc b/content/renderer/render_widget.cc
index c257286..316edef0 100644
--- a/content/renderer/render_widget.cc
+++ b/content/renderer/render_widget.cc
@@ -1200,6 +1200,7 @@
     params.type = new_type;
     params.mode = new_mode;
     params.flags = new_info.flags;
+#if defined(OS_ANDROID)
     if (next_previous_flags_ == kInvalidNextPreviousFlagsValue) {
       // Due to a focus change, values will be reset by the frame.
       // That case we only need fresh NEXT/PREVIOUS information.
@@ -1214,6 +1215,9 @@
         next_previous_flags_ = 0;
       }
     }
+#else
+    next_previous_flags_ = 0;
+#endif
     params.flags |= next_previous_flags_;
     params.value = new_info.value.Utf8();
     params.selection_start = new_info.selection_start;