Avoid showing IME on chrome launch 93/318793/5
authorGajendra N <gajendra.n@samsung.com>
Tue, 8 Oct 2024 10:39:12 +0000 (16:09 +0530)
committerBot Blink <blinkbot@samsung.com>
Thu, 10 Oct 2024 03:17:30 +0000 (03:17 +0000)
As per VD NextBrowser team, IME should not be shown by default on chrome
launch, hence disabling setting focus for location bar by default.

Change-Id: I5b51a513cd2f67a4ebe5bdbc8b6924976ad865f9
Signed-off-by: Gajendra N <gajendra.n@samsung.com>
chrome/browser/ui/browser.cc

index 9802ff4132caa2b6f7cc95eb454b7235f400ba71..541d588420964a9e5575828c1d756b71569d2a38 100644 (file)
@@ -1878,7 +1878,16 @@ bool Browser::ShouldFocusLocationBarByDefault(WebContents* source) {
          url.host_piece() == chrome::kChromeUINewTabHost) ||
         (virtual_url.SchemeIs(content::kChromeUIScheme) &&
          virtual_url.host_piece() == chrome::kChromeUINewTabHost)) {
+#if defined(BUILD_CHROME)
+      // As per VD NextBrowser team, IME should not be shown by default on
+      // chrome launch, hence disabling setting the focus for location bar.
+      // Currently its disabled for chrome:// new tab scenario. If the same
+      // behaviour is required for all cases, try and test early returning
+      // at top of this function body.
+      return false;
+#else
       return true;
+#endif
     }
   }