| OLD | NEW |
| 1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2011 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_TABS_BASE_TAB_H_ | 5 #ifndef CHROME_BROWSER_UI_VIEWS_TABS_BASE_TAB_H_ |
| 6 #define CHROME_BROWSER_UI_VIEWS_TABS_BASE_TAB_H_ | 6 #define CHROME_BROWSER_UI_VIEWS_TABS_BASE_TAB_H_ |
| 7 #pragma once | 7 #pragma once |
| 8 | 8 |
| 9 #include "base/ref_counted.h" | 9 #include "base/ref_counted.h" |
| 10 #include "base/scoped_ptr.h" | 10 #include "base/scoped_ptr.h" |
| (...skipping 118 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 129 | 129 |
| 130 // views::ContextMenuController overrides: | 130 // views::ContextMenuController overrides: |
| 131 virtual void ShowContextMenu(views::View* source, | 131 virtual void ShowContextMenu(views::View* source, |
| 132 const gfx::Point& p, | 132 const gfx::Point& p, |
| 133 bool is_mouse_gesture); | 133 bool is_mouse_gesture); |
| 134 | 134 |
| 135 // Returns the bounds of the title and icon. | 135 // Returns the bounds of the title and icon. |
| 136 virtual const gfx::Rect& GetTitleBounds() const = 0; | 136 virtual const gfx::Rect& GetTitleBounds() const = 0; |
| 137 virtual const gfx::Rect& GetIconBounds() const = 0; | 137 virtual const gfx::Rect& GetIconBounds() const = 0; |
| 138 | 138 |
| 139 virtual int loading_animation_frame() const { | 139 virtual int loading_animation_frame() const; |
| 140 return loading_animation_frame_; | 140 virtual bool should_display_crashed_favicon() const; |
| 141 } | 141 virtual int fav_icon_hiding_offset() const; |
| 142 virtual bool should_display_crashed_favicon() const { | |
| 143 return should_display_crashed_favicon_; | |
| 144 } | |
| 145 virtual int fav_icon_hiding_offset() const { return fav_icon_hiding_offset_; } | |
| 146 | 142 |
| 147 static gfx::Font* font() { return font_; } | 143 static gfx::Font* font() { return font_; } |
| 148 static int font_height() { return font_height_; } | 144 static int font_height() { return font_height_; } |
| 149 | 145 |
| 150 private: | 146 private: |
| 151 // The animation object used to swap the favicon with the sad tab icon. | 147 // The animation object used to swap the favicon with the sad tab icon. |
| 152 class FavIconCrashAnimation; | 148 class FavIconCrashAnimation; |
| 153 | 149 |
| 154 // Set the temporary offset for the favicon. This is used during the crash | 150 // Set the temporary offset for the favicon. This is used during the crash |
| 155 // animation. | 151 // animation. |
| (...skipping 55 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 211 | 207 |
| 212 ui::ThemeProvider* theme_provider_; | 208 ui::ThemeProvider* theme_provider_; |
| 213 | 209 |
| 214 static gfx::Font* font_; | 210 static gfx::Font* font_; |
| 215 static int font_height_; | 211 static int font_height_; |
| 216 | 212 |
| 217 DISALLOW_COPY_AND_ASSIGN(BaseTab); | 213 DISALLOW_COPY_AND_ASSIGN(BaseTab); |
| 218 }; | 214 }; |
| 219 | 215 |
| 220 #endif // CHROME_BROWSER_UI_VIEWS_TABS_BASE_TAB_H_ | 216 #endif // CHROME_BROWSER_UI_VIEWS_TABS_BASE_TAB_H_ |
| OLD | NEW |