Chromium Code Reviews| Index: chrome/browser/ui/cocoa/website_settings/website_settings_bubble_controller.mm |
| diff --git a/chrome/browser/ui/cocoa/website_settings/website_settings_bubble_controller.mm b/chrome/browser/ui/cocoa/website_settings/website_settings_bubble_controller.mm |
| index a6a2128724f92a3941a32e8b7fbfedf41b6704d3..3a8b6e70d52c3366fec2e0a7d7add3a0dd1b0432 100644 |
| --- a/chrome/browser/ui/cocoa/website_settings/website_settings_bubble_controller.mm |
| +++ b/chrome/browser/ui/cocoa/website_settings/website_settings_bubble_controller.mm |
| @@ -179,6 +179,10 @@ NSPoint AnchorPointForWindow(NSWindow* parent) { |
| @implementation WebsiteSettingsBubbleController |
| +- (Profile*)profile { |
|
tapted
2016/10/11 02:22:16
nit: move after the initializer (line ~242)
raymes
2016/10/11 03:50:02
Done.
|
| + return Profile::FromBrowserContext(webContents_->GetBrowserContext()); |
| +} |
| + |
| - (CGFloat)defaultWindowWidth { |
| return kDefaultWindowWidth; |
| } |
| @@ -737,12 +741,14 @@ bool IsInternalURL(const GURL& url) { |
| base::scoped_nsobject<PermissionSelectorButton> button( |
| [[PermissionSelectorButton alloc] initWithPermissionInfo:permissionInfo |
| forURL:url |
| - withCallback:callback]); |
| + withCallback:callback |
| + profile:[self profile]]); |
| // Determine the largest possible size for this button. |
| - CGFloat maxTitleWidth = [button |
| - maxTitleWidthForContentSettingsType:permissionInfo.type |
| - withDefaultSetting:permissionInfo.default_setting]; |
| + CGFloat maxTitleWidth = |
| + [button maxTitleWidthForContentSettingsType:permissionInfo.type |
| + withDefaultSetting:permissionInfo.default_setting |
| + profile:[self profile]]; |
| // Ensure the containing view is large enough to contain the button with its |
| // widest possible title. |