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

Unified Diff: chrome/browser/ui/cocoa/autofill/autofill_notification_container.mm

Issue 21692002: Rename AutofillDialogController to AutofillDialogViewDelegate. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Rebase. Created 7 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/autofill/autofill_notification_container.mm
diff --git a/chrome/browser/ui/cocoa/autofill/autofill_notification_container.mm b/chrome/browser/ui/cocoa/autofill/autofill_notification_container.mm
index 7671ca7213bdf67613607be32d04ce8b304a9e8e..fd31a8350a07a0e995371b673797b94d6e483236 100644
--- a/chrome/browser/ui/cocoa/autofill/autofill_notification_container.mm
+++ b/chrome/browser/ui/cocoa/autofill/autofill_notification_container.mm
@@ -7,17 +7,17 @@
#include "base/logging.h"
#include "base/mac/scoped_nsobject.h"
#include "base/strings/sys_string_conversions.h"
-#include "chrome/browser/ui/autofill/autofill_dialog_controller.h"
#include "chrome/browser/ui/autofill/autofill_dialog_types.h"
+#include "chrome/browser/ui/autofill/autofill_dialog_view_delegate.h"
#include "chrome/browser/ui/cocoa/autofill/autofill_dialog_constants.h"
#import "chrome/browser/ui/cocoa/autofill/autofill_notification_controller.h"
#include "skia/ext/skia_utils_mac.h"
@implementation AutofillNotificationContainer
-- (id)initWithController:(autofill::AutofillDialogController*)controller {
+- (id)initWithDelegate:(autofill::AutofillDialogViewDelegate*)delegate {
if (self = [super init]) {
- controller_ = controller;
+ delegate_ = delegate;
[self setView:[[[NSView alloc] initWithFrame:NSZeroRect] autorelease]];
}
return self;
@@ -39,9 +39,9 @@
if (![[notificationControllers_ objectAtIndex:0] hasArrow])
preferredSize.height += kArrowHeight;
- for (AutofillNotificationController* controller in
+ for (AutofillNotificationController* delegate in
notificationControllers_.get())
- preferredSize.height += [controller preferredSizeForWidth:width].height;
+ preferredSize.height += [delegate preferredSizeForWidth:width].height;
return preferredSize;
}
@@ -55,13 +55,13 @@
if (![[notificationControllers_ objectAtIndex:0] hasArrow])
remaining.size.height -= kArrowHeight;
- for (AutofillNotificationController* controller in
+ for (AutofillNotificationController* delegate in
notificationControllers_.get()) {
NSRect viewRect;
- NSSize size = [controller preferredSizeForWidth:NSWidth(remaining)];
+ NSSize size = [delegate preferredSizeForWidth:NSWidth(remaining)];
NSDivideRect(remaining, &viewRect, &remaining, size.height, NSMaxYEdge);
- [[controller view ] setFrame:viewRect];
- [controller performLayout];
+ [[delegate view ] setFrame:viewRect];
+ [delegate performLayout];
}
DCHECK_EQ(0, NSHeight(remaining));
}
@@ -114,7 +114,7 @@
- (IBAction)checkboxClicked:(id)sender {
DCHECK(checkboxNotification_);
BOOL isChecked = ([sender state] == NSOnState);
- controller_->NotificationCheckboxStateChanged(checkboxNotification_->type(),
+ delegate_->NotificationCheckboxStateChanged(checkboxNotification_->type(),
isChecked);
}

Powered by Google App Engine
This is Rietveld 408576698