| OLD | NEW |
| 1 // Copyright 2015 The Chromium Authors. All rights reserved. | 1 // Copyright 2015 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 "base/memory/ptr_util.h" |
| 5 #include "chrome/browser/password_manager/save_password_infobar_delegate.h" | 6 #include "chrome/browser/password_manager/save_password_infobar_delegate.h" |
| 6 #include "chrome/browser/translate/chrome_translate_client.h" | 7 #include "chrome/browser/translate/chrome_translate_client.h" |
| 7 #include "chrome/browser/ui/views/infobars/confirm_infobar.h" | 8 #include "chrome/browser/ui/views/infobars/confirm_infobar.h" |
| 8 | 9 |
| 9 // On Mac, some infobars are still used that have been migrated to a bubble UI | 10 // On Mac, some infobars are still used that have been migrated to a bubble UI |
| 10 // on other views platforms. When building the toolkit-views browser window on | 11 // on other views platforms. When building the toolkit-views browser window on |
| 11 // Mac, the bubble UI can be used, but interfaces built for Cocoa on Mac still | 12 // Mac, the bubble UI can be used, but interfaces built for Cocoa on Mac still |
| 12 // depend on symbols to provide infobars. This file provides the symbols wanted | 13 // depend on symbols to provide infobars. This file provides the symbols wanted |
| 13 // elsewhere for OS_MACOSX, but aren't otherwise needed for a views browser. | 14 // elsewhere for OS_MACOSX, but aren't otherwise needed for a views browser. |
| 14 // TODO(tapted): Delete this file when Mac uses the bubbles by default. | 15 // TODO(tapted): Delete this file when Mac uses the bubbles by default. |
| 15 | 16 |
| 16 scoped_ptr<infobars::InfoBar> CreateSavePasswordInfoBar( | 17 std::unique_ptr<infobars::InfoBar> CreateSavePasswordInfoBar( |
| 17 scoped_ptr<SavePasswordInfoBarDelegate> delegate) { | 18 std::unique_ptr<SavePasswordInfoBarDelegate> delegate) { |
| 18 return make_scoped_ptr(new ConfirmInfoBar(std::move(delegate))); | 19 return base::WrapUnique(new ConfirmInfoBar(std::move(delegate))); |
| 19 } | 20 } |
| 20 | 21 |
| 21 scoped_ptr<infobars::InfoBar> ChromeTranslateClient::CreateInfoBar( | 22 std::unique_ptr<infobars::InfoBar> ChromeTranslateClient::CreateInfoBar( |
| 22 scoped_ptr<translate::TranslateInfoBarDelegate> delegate) const { | 23 std::unique_ptr<translate::TranslateInfoBarDelegate> delegate) const { |
| 23 NOTREACHED(); | 24 NOTREACHED(); |
| 24 return nullptr; | 25 return nullptr; |
| 25 } | 26 } |
| OLD | NEW |