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

Unified Diff: chrome/android/java/src/org/chromium/chrome/browser/ntp/NewTabPageView.java

Issue 2755883002: Revert of Fix the condensed NTP layout for tablets. (Closed)
Patch Set: Created 3 years, 9 months 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/android/java/src/org/chromium/chrome/browser/ntp/NewTabPageView.java
diff --git a/chrome/android/java/src/org/chromium/chrome/browser/ntp/NewTabPageView.java b/chrome/android/java/src/org/chromium/chrome/browser/ntp/NewTabPageView.java
index baf1a596ad0812ba8fb3701f898e1cec62b28c3b..c833e891153f96956274def1610a2c790249cd9e 100644
--- a/chrome/android/java/src/org/chromium/chrome/browser/ntp/NewTabPageView.java
+++ b/chrome/android/java/src/org/chromium/chrome/browser/ntp/NewTabPageView.java
@@ -304,11 +304,7 @@
final TextView searchBoxTextView = (TextView) mSearchBoxView
.findViewById(R.id.search_box_text);
- boolean isTablet = DeviceFormFactor.isTablet(getContext());
-
- // If the Google G should not be shown then clear it because it is shown by default in xml.
- if (isTablet
- || !ChromeFeatureList.isEnabled(ChromeFeatureList.NTP_SHOW_GOOGLE_G_IN_OMNIBOX)) {
+ if (!ChromeFeatureList.isEnabled(ChromeFeatureList.NTP_SHOW_GOOGLE_G_IN_OMNIBOX)) {
searchBoxTextView.setCompoundDrawablePadding(0);
// Not using the relative version of this call because we only want to clear
@@ -317,7 +313,7 @@
}
String hintText = getResources().getString(R.string.search_or_type_url);
- if (!isTablet || mManager.isFakeOmniboxTextEnabledTablet()) {
+ if (!DeviceFormFactor.isTablet(getContext()) || mManager.isFakeOmniboxTextEnabledTablet()) {
searchBoxTextView.setHint(hintText);
} else {
searchBoxTextView.setContentDescription(hintText);
@@ -523,8 +519,7 @@
if (hasLogo == mSearchProviderHasLogo && mInitialized) return;
mSearchProviderHasLogo = hasLogo;
boolean showLogo = mSearchProviderHasLogo
- && (DeviceFormFactor.isTablet(getContext())
- || !ChromeFeatureList.isEnabled(ChromeFeatureList.NTP_CONDENSED_LAYOUT));
+ && !ChromeFeatureList.isEnabled(ChromeFeatureList.NTP_CONDENSED_LAYOUT);
// Set a bit more top padding on the tile grid if there is no logo.
int paddingTop = getResources().getDimensionPixelSize(showLogo
« 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