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

Side by Side Diff: ios/chrome/browser/infobars/infobar_utils.mm

Issue 1586833002: Convert Pass()→std::move() for iOS build. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Revert accidental //base change Created 4 years, 11 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 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 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 "ios/chrome/browser/infobars/infobar_utils.h" 5 #include "ios/chrome/browser/infobars/infobar_utils.h"
6 6
7 #include <utility>
8
7 #include "base/mac/scoped_nsobject.h" 9 #include "base/mac/scoped_nsobject.h"
8 #include "base/memory/scoped_ptr.h" 10 #include "base/memory/scoped_ptr.h"
9 #include "components/infobars/core/confirm_infobar_delegate.h" 11 #include "components/infobars/core/confirm_infobar_delegate.h"
10 #include "ios/chrome/browser/infobars/confirm_infobar_controller.h" 12 #include "ios/chrome/browser/infobars/confirm_infobar_controller.h"
11 #include "ios/chrome/browser/infobars/infobar.h" 13 #include "ios/chrome/browser/infobars/infobar.h"
12 14
13 scoped_ptr<infobars::InfoBar> CreateConfirmInfoBar( 15 scoped_ptr<infobars::InfoBar> CreateConfirmInfoBar(
14 scoped_ptr<ConfirmInfoBarDelegate> delegate) { 16 scoped_ptr<ConfirmInfoBarDelegate> delegate) {
15 scoped_ptr<InfoBarIOS> infobar(new InfoBarIOS(delegate.Pass())); 17 scoped_ptr<InfoBarIOS> infobar(new InfoBarIOS(std::move(delegate)));
16 base::scoped_nsobject<ConfirmInfoBarController> controller( 18 base::scoped_nsobject<ConfirmInfoBarController> controller(
17 [[ConfirmInfoBarController alloc] initWithDelegate:infobar.get()]); 19 [[ConfirmInfoBarController alloc] initWithDelegate:infobar.get()]);
18 infobar->SetController(controller); 20 infobar->SetController(controller);
19 return infobar.Pass(); 21 return std::move(infobar);
20 } 22 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698