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

Unified Diff: chrome/browser/ui/search/search_delegate.cc

Issue 2885853002: Instant: remove InstantSupportState (Closed)
Patch Set: Created 3 years, 7 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 | « chrome/browser/ui/search/search_delegate.h ('k') | chrome/browser/ui/search/search_model.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/ui/search/search_delegate.cc
diff --git a/chrome/browser/ui/search/search_delegate.cc b/chrome/browser/ui/search/search_delegate.cc
index 31e763d16d1943b1ba367a35da0cc4be3266c241..d9f431009672eeb7a0099a297f5e98a5d98b1f33 100644
--- a/chrome/browser/ui/search/search_delegate.cc
+++ b/chrome/browser/ui/search/search_delegate.cc
@@ -8,24 +8,22 @@
#include "chrome/browser/ui/search/search_tab_helper.h"
SearchDelegate::SearchDelegate(SearchModel* browser_search_model)
- : browser_model_(browser_search_model),
- tab_model_() {
-}
+ : browser_model_(browser_search_model), tab_model_(nullptr) {}
SearchDelegate::~SearchDelegate() {
DCHECK(!tab_model_) << "All tabs should have been deactivated or closed.";
}
-void SearchDelegate::ModelChanged(const SearchModel::State& old_state,
- const SearchModel::State& new_state) {
- browser_model_->SetState(new_state);
+void SearchDelegate::ModelChanged(const SearchMode& old_mode,
+ const SearchMode& new_mode) {
+ browser_model_->SetMode(new_mode);
}
void SearchDelegate::OnTabActivated(content::WebContents* web_contents) {
if (tab_model_)
tab_model_->RemoveObserver(this);
tab_model_ = SearchTabHelper::FromWebContents(web_contents)->model();
- browser_model_->SetState(tab_model_->state());
+ browser_model_->SetMode(tab_model_->mode());
tab_model_->AddObserver(this);
}
« no previous file with comments | « chrome/browser/ui/search/search_delegate.h ('k') | chrome/browser/ui/search/search_model.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698