diff options
author | ben@chromium.org <ben@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2010-04-09 00:16:08 +0000 |
---|---|---|
committer | ben@chromium.org <ben@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2010-04-09 00:16:08 +0000 |
commit | ff3142f7116a3a514cf5f0025fae7501cd7dba16 (patch) | |
tree | b687cfa9761971d1e6a9b2a4fe5efe0532ee0df5 /views | |
parent | f6afff3feb06da707b9c2bc42383ede292929476 (diff) | |
download | chromium_src-ff3142f7116a3a514cf5f0025fae7501cd7dba16.zip chromium_src-ff3142f7116a3a514cf5f0025fae7501cd7dba16.tar.gz chromium_src-ff3142f7116a3a514cf5f0025fae7501cd7dba16.tar.bz2 |
Fix client edge insets for fullscreen mode. we were incorrectly insetting the client area in fullscreen mode even though there are no non-client edges in fullscreen mode. This involves:
1. adding a check for IsFullscreen to the BrowserFrameWin code that calculates the client area insets for fullscreen state, just as it currently checks for maximized state.
2. bypass the WindowWin's sanity check for default insets in the Fullscreen case - in fullscreen mode the window should have zero non-client, not default restored non-client.
http://crbug.com/37588
http://crbug.com/39076
Review URL: http://codereview.chromium.org/1618009
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@44029 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'views')
-rw-r--r-- | views/window/window_win.cc | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/views/window/window_win.cc b/views/window/window_win.cc index 18857fa..d357768 100644 --- a/views/window/window_win.cc +++ b/views/window/window_win.cc @@ -740,10 +740,11 @@ LRESULT WindowWin::OnNCActivate(BOOL active) { } LRESULT WindowWin::OnNCCalcSize(BOOL mode, LPARAM l_param) { - // We only override WM_NCCALCSIZE if we want non-standard non-client edge - // width. + // We only override the default handling if we need to specify a custom + // non-client edge width. Note that in most cases "no insets" means no + // custom width, but in fullscreen mode we want a custom width of 0. gfx::Insets insets = GetClientAreaInsets(); - if (insets.empty()) + if (insets.empty() && !IsFullscreen()) return WidgetWin::OnNCCalcSize(mode, l_param); RECT* client_rect = mode ? |