| 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 b78ef0b6ef2b28e15cafab4c4e04b14a943341af..7f075a2fd6b92a5d07db0426c9411a8f1f30391e 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
|
| @@ -6,7 +6,6 @@
|
|
|
| import android.annotation.SuppressLint;
|
| import android.content.Context;
|
| -import android.content.res.Configuration;
|
| import android.content.res.Resources;
|
| import android.graphics.Bitmap;
|
| import android.graphics.BitmapFactory;
|
| @@ -97,7 +96,6 @@
|
| private OnSearchBoxScrollListener mSearchBoxScrollListener;
|
|
|
| private NewTabPageManager mManager;
|
| - private UiConfig mUiConfig;
|
| private MostVisitedDesign mMostVisitedDesign;
|
| private MostVisitedItem[] mMostVisitedItems;
|
| private boolean mFirstShow = true;
|
| @@ -257,7 +255,6 @@
|
| public void initialize(NewTabPageManager manager, boolean searchProviderHasLogo,
|
| SnippetsBridge snippetsBridge) {
|
| mManager = manager;
|
| - mUiConfig = new UiConfig(this);
|
| ViewStub stub = (ViewStub) findViewById(R.id.new_tab_page_layout_stub);
|
|
|
| mUseCardsUi = snippetsBridge != null;
|
| @@ -308,8 +305,7 @@
|
|
|
| // Set up snippets
|
| if (mUseCardsUi) {
|
| - mNewTabPageAdapter =
|
| - new NewTabPageAdapter(mManager, mNewTabPageLayout, snippetsBridge, mUiConfig);
|
| + mNewTabPageAdapter = new NewTabPageAdapter(mManager, mNewTabPageLayout, snippetsBridge);
|
| mRecyclerView.setAdapter(mNewTabPageAdapter);
|
|
|
| // Set up swipe-to-dismiss
|
| @@ -1106,18 +1102,6 @@
|
| }
|
| }
|
|
|
| - @Override
|
| - protected void onConfigurationChanged(Configuration newConfig) {
|
| - super.onConfigurationChanged(newConfig);
|
| -
|
| - // When the viewport configuration changes, we want to update the display style so that the
|
| - // observers are aware of the new available space. Another moment to do this update could
|
| - // be through a OnLayoutChangeListener, but then we get notified of the change after the
|
| - // layout pass, which means that the new style will only be visible after layout happens
|
| - // again. We prefer updating here to avoid having to require that additional layout pass.
|
| - mUiConfig.updateDisplayStyle();
|
| - }
|
| -
|
| private int getVerticalScroll() {
|
| if (mUseCardsUi) {
|
| return mRecyclerView.computeVerticalScrollOffset();
|
|
|