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

Side by Side Diff: chrome/browser/sessions/tab_restore_service_factory.cc

Issue 1551503002: Convert Pass()→std::move() in //chrome (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 (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 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/sessions/tab_restore_service_factory.h" 5 #include "chrome/browser/sessions/tab_restore_service_factory.h"
6 6
7 #include <utility>
8
7 #include "build/build_config.h" 9 #include "build/build_config.h"
8 #include "chrome/browser/profiles/profile.h" 10 #include "chrome/browser/profiles/profile.h"
9 #include "chrome/browser/sessions/chrome_tab_restore_service_client.h" 11 #include "chrome/browser/sessions/chrome_tab_restore_service_client.h"
10 #include "components/keyed_service/content/browser_context_dependency_manager.h" 12 #include "components/keyed_service/content/browser_context_dependency_manager.h"
11 13
12 #if defined(OS_ANDROID) 14 #if defined(OS_ANDROID)
13 #include "components/sessions/core/in_memory_tab_restore_service.h" 15 #include "components/sessions/core/in_memory_tab_restore_service.h"
14 #else 16 #else
15 #include "components/sessions/core/persistent_tab_restore_service.h" 17 #include "components/sessions/core/persistent_tab_restore_service.h"
16 #endif 18 #endif
(...skipping 36 matching lines...) Expand 10 before | Expand all | Expand 10 after
53 } 55 }
54 56
55 KeyedService* TabRestoreServiceFactory::BuildServiceInstanceFor( 57 KeyedService* TabRestoreServiceFactory::BuildServiceInstanceFor(
56 content::BrowserContext* browser_context) const { 58 content::BrowserContext* browser_context) const {
57 Profile* profile = Profile::FromBrowserContext(browser_context); 59 Profile* profile = Profile::FromBrowserContext(browser_context);
58 DCHECK(!profile->IsOffTheRecord()); 60 DCHECK(!profile->IsOffTheRecord());
59 scoped_ptr<sessions::TabRestoreServiceClient> client( 61 scoped_ptr<sessions::TabRestoreServiceClient> client(
60 new ChromeTabRestoreServiceClient(profile)); 62 new ChromeTabRestoreServiceClient(profile));
61 63
62 #if defined(OS_ANDROID) 64 #if defined(OS_ANDROID)
63 return new sessions::InMemoryTabRestoreService(client.Pass(), nullptr); 65 return new sessions::InMemoryTabRestoreService(client.Pass(), nullptr);
Lei Zhang 2015/12/27 22:35:06 Did you miss one here?
dcheng 2015/12/27 23:09:36 This will be updated when I make a pass over the A
64 #else 66 #else
65 return new sessions::PersistentTabRestoreService(client.Pass(), nullptr); 67 return new sessions::PersistentTabRestoreService(std::move(client), nullptr);
66 #endif 68 #endif
67 } 69 }
OLDNEW
« no previous file with comments | « chrome/browser/sessions/session_service_unittest.cc ('k') | chrome/browser/signin/account_reconcilor_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698