Commit 93f4a877 authored by treib's avatar treib Committed by Commit bot

Remove InstantController::InstantSupportChanged

This is part of a series of CLs to get rid of the notion of
"Instant support" entirely, see
https://bugs.chromium.org/p/chromium/issues/detail?id=627747#c41

BUG=627747

Review-Url: https://codereview.chromium.org/2847083002
Cr-Commit-Position: refs/heads/master@{#467976}
parent ea3be622
......@@ -163,9 +163,6 @@ void BrowserInstantController::ModelChanged(
instant_.SearchModeChanged(old_state.mode, new_mode);
}
if (old_state.instant_support != new_state.instant_support)
instant_.InstantSupportChanged(new_state.instant_support);
}
void BrowserInstantController::DefaultSearchProviderChanged(
......
......@@ -62,17 +62,6 @@ void InstantController::ClearDebugEvents() {
debug_events_.clear();
}
void InstantController::InstantSupportChanged(
InstantSupportState instant_support) {
// Handle INSTANT_SUPPORT_YES here because InstantTab is not hooked up to the
// active tab. Search model changed listener in InstantTab will handle other
// cases.
if (instant_support != INSTANT_SUPPORT_YES)
return;
ResetInstantTab();
}
void InstantController::InstantTabAboutToNavigateMainFrame(
const content::WebContents* contents,
const GURL& url) {
......@@ -80,6 +69,7 @@ void InstantController::InstantTabAboutToNavigateMainFrame(
// The Instant tab navigated. Send it the data it needs to display
// properly.
// TODO(treib): Doesn't seem to be necessary. crbug.com/627747
UpdateInfoForInstantTab();
}
......@@ -97,13 +87,11 @@ void InstantController::ResetInstantTab() {
}
void InstantController::UpdateInfoForInstantTab() {
if (instant_tab_) {
// Update theme details.
InstantService* instant_service = GetInstantService();
if (instant_service) {
instant_service->UpdateThemeInfo();
instant_service->UpdateMostVisitedItemsInfo();
}
DCHECK(instant_tab_);
InstantService* instant_service = GetInstantService();
if (instant_service) {
instant_service->UpdateThemeInfo();
instant_service->UpdateMostVisitedItemsInfo();
}
}
......
......@@ -49,10 +49,6 @@ class InstantController : public InstantTab::Delegate {
// Instant search results page.
void ActiveTabChanged();
// Used by BrowserInstantController to notify InstantController about the
// instant support change event for the active web contents.
void InstantSupportChanged(InstantSupportState instant_support);
// Resets list of debug events.
void ClearDebugEvents();
......
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