| OLD | NEW |
| 1 // Copyright 2016 The Chromium Authors. All rights reserved. | 1 // Copyright 2016 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 #import "ios/chrome/browser/passwords/update_password_infobar_controller.h" | 5 #import "ios/chrome/browser/passwords/update_password_infobar_controller.h" |
| 6 | 6 |
| 7 #import "base/mac/objc_property_releaser.h" | 7 #import "base/mac/objc_property_releaser.h" |
| 8 #include "base/strings/string_util.h" | 8 #include "base/strings/string_util.h" |
| 9 #include "base/strings/sys_string_conversions.h" | 9 #include "base/strings/sys_string_conversions.h" |
| 10 #include "ios/chrome/browser/infobars/confirm_infobar_controller+protected.h" | 10 #include "ios/chrome/browser/infobars/confirm_infobar_controller+protected.h" |
| 11 #include "ios/chrome/browser/passwords/ios_chrome_update_password_infobar_delega
te.h" | 11 #include "ios/chrome/browser/passwords/ios_chrome_update_password_infobar_delega
te.h" |
| 12 #import "ios/chrome/browser/ui/elements/selector_coordinator.h" | 12 #import "ios/chrome/browser/ui/elements/selector_coordinator.h" |
| 13 #import "ios/public/provider/chrome/browser/ui/infobar_view_protocol.h" | 13 #import "ios/chrome/browser/ui/infobars/infobar_view_protocol.h" |
| 14 | 14 |
| 15 namespace { | 15 namespace { |
| 16 // Tag for the account link in the info bar message. Set to 10 to avoid conflict | 16 // Tag for the account link in the info bar message. Set to 10 to avoid conflict |
| 17 // with tags from superclass ConfirmInfoBarController, which uses tags 1-4. | 17 // with tags from superclass ConfirmInfoBarController, which uses tags 1-4. |
| 18 NSUInteger kAccountTag = 10; | 18 NSUInteger kAccountTag = 10; |
| 19 } | 19 } |
| 20 | 20 |
| 21 @interface UpdatePasswordInfoBarController ()<SelectorCoordinatorDelegate> { | 21 @interface UpdatePasswordInfoBarController ()<SelectorCoordinatorDelegate> { |
| 22 base::mac::ObjCPropertyReleaser | 22 base::mac::ObjCPropertyReleaser |
| 23 _propertyReleaser_UpdatePasswordInfoBarController; | 23 _propertyReleaser_UpdatePasswordInfoBarController; |
| (...skipping 61 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 85 | 85 |
| 86 #pragma mark SelectorCoordinatorDelegate | 86 #pragma mark SelectorCoordinatorDelegate |
| 87 | 87 |
| 88 - (void)selectorCoordinator:(SelectorCoordinator*)coordinator | 88 - (void)selectorCoordinator:(SelectorCoordinator*)coordinator |
| 89 didCompleteWithSelection:(NSString*)selection { | 89 didCompleteWithSelection:(NSString*)selection { |
| 90 _delegate->set_selected_account(base::SysNSStringToUTF16(selection)); | 90 _delegate->set_selected_account(base::SysNSStringToUTF16(selection)); |
| 91 [self updateInfobarLabel:self.view]; | 91 [self updateInfobarLabel:self.view]; |
| 92 } | 92 } |
| 93 | 93 |
| 94 @end | 94 @end |
| OLD | NEW |