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

Unified Diff: chrome/browser/ui/cocoa/passwords/manage_passwords_bubble_never_save_view_controller.h

Issue 450643003: Add ManagePasswordsBubbleNeverSaveViewController and unit tests. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: style Created 6 years, 4 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 side-by-side diff with in-line comments
Download patch
Index: chrome/browser/ui/cocoa/passwords/manage_passwords_bubble_never_save_view_controller.h
diff --git a/chrome/browser/ui/cocoa/passwords/manage_passwords_bubble_never_save_view_controller.h b/chrome/browser/ui/cocoa/passwords/manage_passwords_bubble_never_save_view_controller.h
new file mode 100644
index 0000000000000000000000000000000000000000..ec942ccfbc49a343ea7b5940791b7c815a6a7687
--- /dev/null
+++ b/chrome/browser/ui/cocoa/passwords/manage_passwords_bubble_never_save_view_controller.h
@@ -0,0 +1,43 @@
+// Copyright 2014 The Chromium Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+#ifndef CHROME_BROWSER_UI_COCOA_PASSWORDS_MANAGE_PASSWORDS_BUBBLE_NEVER_SAVE_VIEW_CONTROLLER_H_
+#define CHROME_BROWSER_UI_COCOA_PASSWORDS_MANAGE_PASSWORDS_BUBBLE_NEVER_SAVE_VIEW_CONTROLLER_H_
+
+#import <Cocoa/Cocoa.h>
+
+#include "base/mac/scoped_nsobject.h"
+#import "chrome/browser/ui/cocoa/passwords/manage_passwords_bubble_content_view_controller.h"
+
+class ManagePasswordsBubbleModel;
+
+// Handles user interaction with the password never save confirmation bubble.
+@protocol ManagePasswordsBubbleNeverSaveViewDelegate<
+ ManagePasswordsBubbleContentViewDelegate>
+
+// The user chose not to never save passwords on this site.
+- (void)neverSavePasswordCancelled;
+
+@end
+
+// Manages the view that confirms that the user never wants to save passwords
+// on this site.
+@interface ManagePasswordsBubbleNeverSaveViewController
+ : ManagePasswordsBubbleContentViewController {
+ @private
+ ManagePasswordsBubbleModel* model_; // weak
+ id<ManagePasswordsBubbleNeverSaveViewDelegate> delegate_; // weak
+ base::scoped_nsobject<NSButton> confirmButton_;
+ base::scoped_nsobject<NSButton> undoButton_;
+}
+- (id)initWithModel:(ManagePasswordsBubbleModel*)model
+ delegate:(id<ManagePasswordsBubbleNeverSaveViewDelegate>)delegate;
+@end
+
+@interface ManagePasswordsBubbleNeverSaveViewController (Testing)
+@property(readonly) NSButton* confirmButton;
+@property(readonly) NSButton* undoButton;
+@end
+
+#endif // CHROME_BROWSER_UI_COCOA_PASSWORDS_MANAGE_PASSWORDS_BUBBLE_NEVER_SAVE_VIEW_CONTROLLER_H_

Powered by Google App Engine
This is Rietveld 408576698