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

Side by Side Diff: chrome/browser/ui/search/instant_controller.cc

Issue 1550053002: Convert Pass()→std::move() in //chrome/browser/ui (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 years, 12 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 unified diff | Download patch
OLDNEW
1 // Copyright 2012 The Chromium Authors. All rights reserved. 1 // Copyright 2012 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "chrome/browser/ui/search/instant_controller.h" 5 #include "chrome/browser/ui/search/instant_controller.h"
6 6
7 #include <stddef.h> 7 #include <stddef.h>
8 #include <utility>
8 9
9 #include "base/prefs/pref_service.h" 10 #include "base/prefs/pref_service.h"
10 #include "base/strings/stringprintf.h" 11 #include "base/strings/stringprintf.h"
11 #include "chrome/browser/chrome_notification_types.h" 12 #include "chrome/browser/chrome_notification_types.h"
12 #include "chrome/browser/platform_util.h" 13 #include "chrome/browser/platform_util.h"
13 #include "chrome/browser/profiles/profile.h" 14 #include "chrome/browser/profiles/profile.h"
14 #include "chrome/browser/search/instant_service.h" 15 #include "chrome/browser/search/instant_service.h"
15 #include "chrome/browser/search/instant_service_factory.h" 16 #include "chrome/browser/search/instant_service_factory.h"
16 #include "chrome/browser/search/search.h" 17 #include "chrome/browser/search/search.h"
17 #include "chrome/browser/search_engines/template_url_service_factory.h" 18 #include "chrome/browser/search_engines/template_url_service_factory.h"
(...skipping 38 matching lines...) Expand 10 before | Expand all | Expand 10 after
56 const content::NavigationEntry* entry = controller->GetLastCommittedEntry(); 57 const content::NavigationEntry* entry = controller->GetLastCommittedEntry();
57 scoped_ptr<content::NavigationEntry> transient = 58 scoped_ptr<content::NavigationEntry> transient =
58 controller->CreateNavigationEntry( 59 controller->CreateNavigationEntry(
59 entry->GetURL(), 60 entry->GetURL(),
60 entry->GetReferrer(), 61 entry->GetReferrer(),
61 entry->GetTransitionType(), 62 entry->GetTransitionType(),
62 false, 63 false,
63 std::string(), 64 std::string(),
64 contents->GetBrowserContext()); 65 contents->GetBrowserContext());
65 transient->SetExtraData(sessions::kSearchTermsKey, search_terms); 66 transient->SetExtraData(sessions::kSearchTermsKey, search_terms);
66 controller->SetTransientEntry(transient.Pass()); 67 controller->SetTransientEntry(std::move(transient));
67 68
68 SearchTabHelper::FromWebContents(contents)->NavigationEntryUpdated(); 69 SearchTabHelper::FromWebContents(contents)->NavigationEntryUpdated();
69 } 70 }
70 71
71 } // namespace 72 } // namespace
72 73
73 InstantController::InstantController(BrowserInstantController* browser) 74 InstantController::InstantController(BrowserInstantController* browser)
74 : browser_(browser) { 75 : browser_(browser) {
75 } 76 }
76 77
(...skipping 114 matching lines...) Expand 10 before | Expand all | Expand 10 after
191 if (instant_service) { 192 if (instant_service) {
192 instant_service->UpdateThemeInfo(); 193 instant_service->UpdateThemeInfo();
193 instant_service->UpdateMostVisitedItemsInfo(); 194 instant_service->UpdateMostVisitedItemsInfo();
194 } 195 }
195 } 196 }
196 } 197 }
197 198
198 InstantService* InstantController::GetInstantService() const { 199 InstantService* InstantController::GetInstantService() const {
199 return InstantServiceFactory::GetForProfile(profile()); 200 return InstantServiceFactory::GetForProfile(profile());
200 } 201 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698