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 #ifndef CHROME_BROWSER_UI_CONSTRAINED_WINDOW_H_ | 5 #ifndef CHROME_BROWSER_UI_CONSTRAINED_WINDOW_H_ |
6 #define CHROME_BROWSER_UI_CONSTRAINED_WINDOW_H_ | 6 #define CHROME_BROWSER_UI_CONSTRAINED_WINDOW_H_ |
7 | 7 |
8 #include "build/build_config.h" | 8 #include "build/build_config.h" |
9 #include "third_party/skia/include/core/SkColor.h" | 9 #include "third_party/skia/include/core/SkColor.h" |
10 #include "ui/base/resource/resource_bundle.h" | 10 #include "ui/base/resource/resource_bundle.h" |
11 #include "ui/gfx/native_widget_types.h" | 11 #include "ui/gfx/native_widget_types.h" |
12 | 12 |
13 /////////////////////////////////////////////////////////////////////////////// | 13 /////////////////////////////////////////////////////////////////////////////// |
14 // ConstrainedWindow | 14 // ConstrainedWindow |
15 // | 15 // |
16 // This interface represents a window that is constrained to a | 16 // This interface represents a window that is constrained to a |
17 // WebContentsView's bounds. | 17 // WebContentsView's bounds. |
18 // | 18 // |
19 class ConstrainedWindow { | 19 class ConstrainedWindow { |
20 public: | 20 public: |
21 static const int kVerticalPadding = 14; // top/bottom padding. | 21 static const int kTitleTopPadding = 15; // Padding above the title. |
Ben Goodger (Google)
2012/10/12 16:48:59
see my comment in another CL. I think you should m
please use gerrit instead
2012/10/12 18:56:08
Done.
| |
22 static const int kHorizontalPadding = 17; // left/right padding. | 22 static const int kHorizontalPadding = 20; // Left and right padding. |
23 static const int kRowPadding = 20; // Vertical margin between dialog rows. | 23 static const int kClientTopPadding = 18; // Padding above the client view. |
24 static const int kBorderRadius = 2; // Border radius for dialog corners. | 24 static const int kClientBottomPadding = 20; // Padding below the client view. |
25 static const int kCloseButtonPadding = 7; // Padding around the close button. | |
26 static const int kBorderRadius = 2; // Border radius for dialog corners. | |
27 | |
28 #if defined(OS_MACOSX) | |
29 static const int kRowPadding = 20; // Padding between rows of text. | |
30 #endif | |
25 | 31 |
26 // Font style for dialog text. | 32 // Font style for dialog text. |
27 static const ui::ResourceBundle::FontStyle kTextFontStyle = | 33 static const ui::ResourceBundle::FontStyle kTextFontStyle = |
28 ui::ResourceBundle::BaseFont; | 34 ui::ResourceBundle::BaseFont; |
29 // Font style for bold dialog text. | 35 // Font style for bold dialog text. |
30 static const ui::ResourceBundle::FontStyle kBoldTextFontStyle = | 36 static const ui::ResourceBundle::FontStyle kBoldTextFontStyle = |
31 ui::ResourceBundle::BoldFont; | 37 ui::ResourceBundle::BoldFont; |
32 // Font style for dialog title. | 38 // Font style for dialog title. |
33 static const ui::ResourceBundle::FontStyle kTitleFontStyle = | 39 static const ui::ResourceBundle::FontStyle kTitleFontStyle = |
34 ui::ResourceBundle::MediumFont; | 40 ui::ResourceBundle::MediumFont; |
(...skipping 21 matching lines...) Expand all Loading... | |
56 virtual bool CanShowConstrainedWindow(); | 62 virtual bool CanShowConstrainedWindow(); |
57 | 63 |
58 // Returns the native window of the constrained window. | 64 // Returns the native window of the constrained window. |
59 virtual gfx::NativeWindow GetNativeWindow(); | 65 virtual gfx::NativeWindow GetNativeWindow(); |
60 | 66 |
61 protected: | 67 protected: |
62 virtual ~ConstrainedWindow() {} | 68 virtual ~ConstrainedWindow() {} |
63 }; | 69 }; |
64 | 70 |
65 #endif // CHROME_BROWSER_UI_CONSTRAINED_WINDOW_H_ | 71 #endif // CHROME_BROWSER_UI_CONSTRAINED_WINDOW_H_ |
OLD | NEW |