diff options
author | pinkerton@chromium.org <pinkerton@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2009-05-13 19:48:08 +0000 |
---|---|---|
committer | pinkerton@chromium.org <pinkerton@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2009-05-13 19:48:08 +0000 |
commit | 0666aef37e02188ef4b4c8890c08c5665970d54e (patch) | |
tree | ecc6f3d21eccb33040849c37d15b28a8d65f8fa1 /chrome/browser/cocoa/browser_window_controller.mm | |
parent | 0582493ed8a6aa530c16acffb2cf2bae4bfd955f (diff) | |
download | chromium_src-0666aef37e02188ef4b4c8890c08c5665970d54e.zip chromium_src-0666aef37e02188ef4b4c8890c08c5665970d54e.tar.gz chromium_src-0666aef37e02188ef4b4c8890c08c5665970d54e.tar.bz2 |
Propagate intrinsic width notification over IPC in all cases (not just extensions) to the TabContentsView. Enable the zoom button on Mac to utilize it. Ensure we only send the IPC notification when the value changes, as WebCore tends to over-report that it has changed. Fix const-ness in delegate API where it's not necessary.
Review URL: http://codereview.chromium.org/115138
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@15988 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'chrome/browser/cocoa/browser_window_controller.mm')
-rw-r--r-- | chrome/browser/cocoa/browser_window_controller.mm | 5 |
1 files changed, 1 insertions, 4 deletions
diff --git a/chrome/browser/cocoa/browser_window_controller.mm b/chrome/browser/cocoa/browser_window_controller.mm index 0f6ef71..3dba768 100644 --- a/chrome/browser/cocoa/browser_window_controller.mm +++ b/chrome/browser/cocoa/browser_window_controller.mm @@ -213,8 +213,6 @@ willPositionSheet:(NSWindow *)sheet // regardless. - (NSRect)windowWillUseStandardFrame:(NSWindow*)window defaultFrame:(NSRect)frame { -#if 0 -// TODO(pinkerton): this is part of another CL which is out for review. const int kMinimumIntrinsicWidth = 700; const int kScrollbarWidth = 16; const int kSpaceForIcons = 50; @@ -224,12 +222,11 @@ willPositionSheet:(NSWindow *)sheet TabContents* contents = browser_->tabstrip_model()->GetSelectedTabContents(); if (contents) { - int intrinsicWidth = contents->preferred_width() + kScrollbarWidth; + int intrinsicWidth = contents->view()->preferred_width() + kScrollbarWidth; int tempWidth = std::max(intrinsicWidth, kMinimumIntrinsicWidth); frame.size.width = std::min(tempWidth, kMaxWidth); frame.size.height = screenSize.height; } -#endif return frame; } |