mac: Don't add subviews to NSThemeFrame on OSX 10.10.
commit30f5c966a41ba31b4d11d1804cf8d803ef1f0cc7
authorerikchen@chromium.org <erikchen@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>
Tue, 1 Jul 2014 19:40:18 +0000 (1 19:40 +0000)
committererikchen@chromium.org <erikchen@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>
Tue, 1 Jul 2014 19:40:18 +0000 (1 19:40 +0000)
treed043ad0dd9bdeb10a76f8a60ef71d45560337b22
parent28bc175c395aafc54d5d37e5b1b876ccc2c5c94d
mac: Don't add subviews to NSThemeFrame on OSX 10.10.

On 10.10, replace the NSWindow contentView with a custom NSView subclass that
is always the same size as the window. This allows us to add the tab bar,
avatar icon, etc. to the contentView instead of the NSThemeFrame (which
produces warnings).

If the bugs in the 10.10 flags/methods NSFullSizeContentViewWindowMask and
titlebarAppearsTransparent are fixed (see 380412 for more information), then
the transition to using those APIs instead of a custom NSView subclass will be
simple.

I performed a careful audit of all calls in the Chrome codebase to -[NSWindow
contentView] and determined the minimal set of changes necessary to support
differently sized contentViews.

BUG=380412

Review URL: https://codereview.chromium.org/353153003

git-svn-id: svn://svn.chromium.org/chrome/trunk/src@280868 0039d316-1c4b-4281-b951-d872f2087c98
chrome/browser/ui/cocoa/browser_window_controller.mm
chrome/browser/ui/cocoa/browser_window_controller_private.mm
chrome/browser/ui/cocoa/chrome_browser_window.h
chrome/browser/ui/cocoa/tabs/tab_window_controller.mm
chrome/browser/ui/cocoa/version_independent_window.h [new file with mode: 0644]
chrome/browser/ui/cocoa/version_independent_window.mm [new file with mode: 0644]
chrome/chrome_browser_ui.gypi