Commit 5095480e authored by cblume's avatar cblume Committed by Commit bot

Revert of Fix the condensed NTP layout for tablets. (patchset #2 id:20001 of...

Revert of Fix the condensed NTP layout for tablets. (patchset #2 id:20001 of https://codereview.chromium.org/2750503008/ )

Reason for revert:
This is causing KitKat Tablet Tester to fail the chrome_public_test_apk step.

Original issue's description:
> Fix the condensed NTP layout for tablets.
>
> BUG=700947
>
> Review-Url: https://codereview.chromium.org/2750503008
> Cr-Commit-Position: refs/heads/master@{#457068}
> Committed: https://chromium.googlesource.com/chromium/src/+/aa26b1a2d7c80e970051ee002dd072f37f9a3852

TBR=bauerb@chromium.org,mvanouwerkerk@chromium.org
# Skipping CQ checks because original CL landed less than 1 days ago.
NOPRESUBMIT=true
NOTREECHECKS=true
NOTRY=true
BUG=700947

Review-Url: https://codereview.chromium.org/2755883002
Cr-Commit-Position: refs/heads/master@{#457362}
parent 6da294d0
......@@ -304,11 +304,7 @@ public class NewTabPageView
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 @@ public class NewTabPageView
}
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 @@ public class NewTabPageView
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
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment