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
3 // found in the LICENSE file.
5 #ifndef CHROME_BROWSER_UI_COCOA_PASSWORDS_MANAGE_PASSWORDS_BUBBLE_PENDING_VIEW_CONTROLLER_H_
6 #define CHROME_BROWSER_UI_COCOA_PASSWORDS_MANAGE_PASSWORDS_BUBBLE_PENDING_VIEW_CONTROLLER_H_
8 #import <Cocoa/Cocoa.h>
10 #include "base/mac/scoped_nsobject.h"
11 #import "chrome/browser/ui/cocoa/passwords/manage_passwords_bubble_content_view_controller.h"
17 @class BubbleCombobox;
18 class ManagePasswordsBubbleModel;
19 @class ManagePasswordItemViewController;
21 // Handles user interaction with the password save bubble.
22 @protocol ManagePasswordsBubblePendingViewDelegate<
23 ManagePasswordsBubbleContentViewDelegate>
25 // The user chose to never save the password on a site that has other passwords
27 - (void)passwordShouldNeverBeSavedOnSiteWithExistingPasswords;
31 // Manages the view that offers to save the user's password.
32 @interface ManagePasswordsBubblePendingViewController
33 : ManagePasswordsBubbleContentViewController {
35 ManagePasswordsBubbleModel* model_; // weak
36 id<ManagePasswordsBubblePendingViewDelegate> delegate_; // weak
37 base::scoped_nsobject<NSButton> saveButton_;
38 base::scoped_nsobject<BubbleCombobox> nopeButton_;
39 base::scoped_nsobject<ManagePasswordItemViewController> passwordItem_;
41 - (id)initWithModel:(ManagePasswordsBubbleModel*)model
42 delegate:(id<ManagePasswordsBubblePendingViewDelegate>)delegate;
45 @interface ManagePasswordsBubblePendingViewController (Testing)
46 @property(readonly) NSButton* saveButton;
47 @property(readonly) BubbleCombobox* nopeButton;
50 #endif // CHROME_BROWSER_UI_COCOA_PASSWORDS_MANAGE_PASSWORDS_BUBBLE_PENDING_VIEW_CONTROLLER_H_