OLD | NEW |
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. |
2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
4 | 4 |
5 #include "chrome/browser/ui/views/frame/opaque_browser_frame_view.h" | 5 #include "chrome/browser/ui/views/frame/opaque_browser_frame_view.h" |
6 | 6 |
7 #include <algorithm> | 7 #include <algorithm> |
8 #include <string> | 8 #include <string> |
9 | 9 |
10 #include "base/command_line.h" | 10 #include "base/command_line.h" |
(...skipping 10 matching lines...) Expand all Loading... |
21 #include "chrome/browser/ui/views/tabs/tab_strip.h" | 21 #include "chrome/browser/ui/views/tabs/tab_strip.h" |
22 #include "chrome/browser/ui/views/toolbar_view.h" | 22 #include "chrome/browser/ui/views/toolbar_view.h" |
23 #include "chrome/common/chrome_notification_types.h" | 23 #include "chrome/common/chrome_notification_types.h" |
24 #include "chrome/common/chrome_switches.h" | 24 #include "chrome/common/chrome_switches.h" |
25 #include "chrome/common/pref_names.h" | 25 #include "chrome/common/pref_names.h" |
26 #include "content/public/browser/notification_service.h" | 26 #include "content/public/browser/notification_service.h" |
27 #include "content/public/browser/web_contents.h" | 27 #include "content/public/browser/web_contents.h" |
28 #include "grit/chromium_strings.h" | 28 #include "grit/chromium_strings.h" |
29 #include "grit/generated_resources.h" | 29 #include "grit/generated_resources.h" |
30 #include "grit/theme_resources.h" | 30 #include "grit/theme_resources.h" |
31 #include "grit/theme_resources_standard.h" | |
32 #include "grit/ui_resources.h" | 31 #include "grit/ui_resources.h" |
33 #include "ui/base/accessibility/accessible_view_state.h" | 32 #include "ui/base/accessibility/accessible_view_state.h" |
34 #include "ui/base/hit_test.h" | 33 #include "ui/base/hit_test.h" |
35 #include "ui/base/l10n/l10n_util.h" | 34 #include "ui/base/l10n/l10n_util.h" |
36 #include "ui/base/resource/resource_bundle.h" | 35 #include "ui/base/resource/resource_bundle.h" |
37 #include "ui/base/theme_provider.h" | 36 #include "ui/base/theme_provider.h" |
38 #include "ui/gfx/canvas.h" | 37 #include "ui/gfx/canvas.h" |
39 #include "ui/gfx/font.h" | 38 #include "ui/gfx/font.h" |
40 #include "ui/gfx/image/image.h" | 39 #include "ui/gfx/image/image.h" |
41 #include "ui/gfx/path.h" | 40 #include "ui/gfx/path.h" |
(...skipping 965 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1007 | 1006 |
1008 gfx::Rect OpaqueBrowserFrameView::CalculateClientAreaBounds(int width, | 1007 gfx::Rect OpaqueBrowserFrameView::CalculateClientAreaBounds(int width, |
1009 int height) const { | 1008 int height) const { |
1010 int top_height = NonClientTopBorderHeight(false); | 1009 int top_height = NonClientTopBorderHeight(false); |
1011 int border_thickness = NonClientBorderThickness(); | 1010 int border_thickness = NonClientBorderThickness(); |
1012 return gfx::Rect(border_thickness, top_height, | 1011 return gfx::Rect(border_thickness, top_height, |
1013 std::max(0, width - (2 * border_thickness)), | 1012 std::max(0, width - (2 * border_thickness)), |
1014 std::max(0, height - GetReservedHeight() - | 1013 std::max(0, height - GetReservedHeight() - |
1015 top_height - border_thickness)); | 1014 top_height - border_thickness)); |
1016 } | 1015 } |
OLD | NEW |