| Index: chrome/android/java/src/org/chromium/chrome/browser/suggestions/SuggestionsBottomSheetContent.java
|
| diff --git a/chrome/android/java/src/org/chromium/chrome/browser/suggestions/SuggestionsBottomSheetContent.java b/chrome/android/java/src/org/chromium/chrome/browser/suggestions/SuggestionsBottomSheetContent.java
|
| index 07dfcb11ae925884c1a1b619f8013f9681cb6788..dcf1ba5a57ad6bc892af17e7983064f30dec2122 100644
|
| --- a/chrome/android/java/src/org/chromium/chrome/browser/suggestions/SuggestionsBottomSheetContent.java
|
| +++ b/chrome/android/java/src/org/chromium/chrome/browser/suggestions/SuggestionsBottomSheetContent.java
|
| @@ -1,4 +1,4 @@
|
| -// Copyright 2016 The Chromium Authors. All rights reserved.
|
| +// Copyright 2017 The Chromium Authors. All rights reserved.
|
| // Use of this source code is governed by a BSD-style license that can be
|
| // found in the LICENSE file.
|
|
|
| @@ -30,6 +30,7 @@ public class SuggestionsBottomSheetContent {
|
| private final ContextMenuManager mContextMenuManager;
|
| private final SuggestionsUiDelegateImpl mSuggestionsManager;
|
| private final SnippetsBridge mSnippetsBridge;
|
| + private final TileGroup.Delegate mTileGroupDelegate;
|
|
|
| public SuggestionsBottomSheetContent(
|
| ChromeActivity activity, Tab tab, TabModelSelector tabModelSelector) {
|
| @@ -46,9 +47,12 @@ public class SuggestionsBottomSheetContent {
|
| mSuggestionsManager = new SuggestionsUiDelegateImpl(
|
| mSnippetsBridge, mSnippetsBridge, navigationDelegate, profile, tab);
|
| mContextMenuManager = new ContextMenuManager(activity, navigationDelegate, mRecyclerView);
|
| + mTileGroupDelegate =
|
| + new TileGroupDelegateImpl(activity, tab, tabModelSelector, navigationDelegate);
|
|
|
| - NewTabPageAdapter adapter = new NewTabPageAdapter(mSuggestionsManager, null, uiConfig,
|
| - OfflinePageBridge.getForProfile(profile), mContextMenuManager);
|
| + NewTabPageAdapter adapter = new NewTabPageAdapter(mSuggestionsManager,
|
| + /* aboveTheFoldView = */ null, uiConfig, OfflinePageBridge.getForProfile(profile),
|
| + mContextMenuManager, mTileGroupDelegate);
|
| mRecyclerView.setAdapter(adapter);
|
| mRecyclerView.setUpSwipeToDismiss();
|
| }
|
| @@ -64,5 +68,6 @@ public class SuggestionsBottomSheetContent {
|
| public void destroy() {
|
| mSnippetsBridge.destroy();
|
| mSuggestionsManager.onDestroy();
|
| + mTileGroupDelegate.destroy();
|
| }
|
| }
|
|
|