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_VIEWS_SAD_TAB_VIEW_H_ | 5 #ifndef CHROME_BROWSER_UI_VIEWS_SAD_TAB_VIEW_H_ |
6 #define CHROME_BROWSER_UI_VIEWS_SAD_TAB_VIEW_H_ | 6 #define CHROME_BROWSER_UI_VIEWS_SAD_TAB_VIEW_H_ |
7 | 7 |
8 #include "base/basictypes.h" | 8 #include "base/basictypes.h" |
9 #include "base/compiler_specific.h" | 9 #include "base/compiler_specific.h" |
10 #include "chrome/browser/ui/sad_tab_types.h" | 10 #include "chrome/browser/ui/sad_tab_types.h" |
11 #include "ui/views/controls/button/button.h" | 11 #include "ui/views/controls/button/button.h" |
12 #include "ui/views/controls/link_listener.h" | 12 #include "ui/views/controls/link_listener.h" |
13 #include "ui/views/view.h" | 13 #include "ui/views/view.h" |
14 | 14 |
15 namespace content { | 15 namespace content { |
16 class WebContents; | 16 class WebContents; |
17 } | 17 } |
18 | 18 |
19 namespace gfx { | |
20 class Font; | |
21 } | |
22 | |
23 namespace views { | 19 namespace views { |
24 class Label; | 20 class Label; |
25 class TextButton; | 21 class TextButton; |
26 } | 22 } |
27 | 23 |
28 /////////////////////////////////////////////////////////////////////////////// | 24 /////////////////////////////////////////////////////////////////////////////// |
29 // | 25 // |
30 // SadTabView | 26 // SadTabView |
31 // | 27 // |
32 // A views::View subclass used to render the presentation of the crashed | 28 // A views::View subclass used to render the presentation of the crashed |
(...skipping 24 matching lines...) Expand all Loading... |
57 views::View* child) OVERRIDE; | 53 views::View* child) OVERRIDE; |
58 virtual void OnPaint(gfx::Canvas* canvas) OVERRIDE; | 54 virtual void OnPaint(gfx::Canvas* canvas) OVERRIDE; |
59 | 55 |
60 private: | 56 private: |
61 views::Label* CreateLabel(const string16& text); | 57 views::Label* CreateLabel(const string16& text); |
62 views::Link* CreateLink(const string16& text); | 58 views::Link* CreateLink(const string16& text); |
63 | 59 |
64 content::WebContents* web_contents_; | 60 content::WebContents* web_contents_; |
65 chrome::SadTabKind kind_; | 61 chrome::SadTabKind kind_; |
66 bool painted_; | 62 bool painted_; |
67 const gfx::Font& base_font_; | |
68 views::Label* message_; | 63 views::Label* message_; |
69 views::Link* help_link_; | 64 views::Link* help_link_; |
70 views::Link* feedback_link_; | 65 views::Link* feedback_link_; |
71 views::TextButton* reload_button_; | 66 views::TextButton* reload_button_; |
72 | 67 |
73 DISALLOW_COPY_AND_ASSIGN(SadTabView); | 68 DISALLOW_COPY_AND_ASSIGN(SadTabView); |
74 }; | 69 }; |
75 | 70 |
76 #endif // CHROME_BROWSER_UI_VIEWS_SAD_TAB_VIEW_H__ | 71 #endif // CHROME_BROWSER_UI_VIEWS_SAD_TAB_VIEW_H__ |
OLD | NEW |