| OLD | NEW |
| 1 // Copyright (c) 2010 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2010 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_TAB_H_ | 5 #ifndef CHROME_BROWSER_UI_VIEWS_TABS_TAB_H_ |
| 6 #define CHROME_BROWSER_UI_VIEWS_TABS_TAB_H_ | 6 #define CHROME_BROWSER_UI_VIEWS_TABS_TAB_H_ |
| 7 #pragma once | 7 #pragma once |
| 8 | 8 |
| 9 #include <string> | 9 #include <string> |
| 10 | 10 |
| 11 #include "base/scoped_ptr.h" | 11 #include "base/scoped_ptr.h" |
| 12 #include "chrome/browser/views/tabs/base_tab.h" | 12 #include "chrome/browser/views/tabs/base_tab.h" |
| 13 #include "gfx/point.h" | 13 #include "gfx/point.h" |
| 14 | 14 |
| 15 namespace ui { |
| 15 class MultiAnimation; | 16 class MultiAnimation; |
| 16 class SlideAnimation; | 17 class SlideAnimation; |
| 18 } |
| 17 | 19 |
| 18 /////////////////////////////////////////////////////////////////////////////// | 20 /////////////////////////////////////////////////////////////////////////////// |
| 19 // | 21 // |
| 20 // TabRenderer | 22 // TabRenderer |
| 21 // | 23 // |
| 22 // A View that renders a Tab, either in a TabStrip or in a DraggedTabView. | 24 // A View that renders a Tab, either in a TabStrip or in a DraggedTabView. |
| 23 // | 25 // |
| 24 /////////////////////////////////////////////////////////////////////////////// | 26 /////////////////////////////////////////////////////////////////////////////// |
| 25 class Tab : public BaseTab { | 27 class Tab : public BaseTab { |
| 26 public: | 28 public: |
| (...skipping 76 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 103 gfx::Rect favicon_bounds_; | 105 gfx::Rect favicon_bounds_; |
| 104 gfx::Rect title_bounds_; | 106 gfx::Rect title_bounds_; |
| 105 | 107 |
| 106 // The offset used to paint the inactive background image. | 108 // The offset used to paint the inactive background image. |
| 107 gfx::Point background_offset_; | 109 gfx::Point background_offset_; |
| 108 | 110 |
| 109 // The center point for the radial hover glow. | 111 // The center point for the radial hover glow. |
| 110 gfx::Point hover_point_; | 112 gfx::Point hover_point_; |
| 111 | 113 |
| 112 // Animation used when the title of an inactive mini tab changes. | 114 // Animation used when the title of an inactive mini tab changes. |
| 113 scoped_ptr<MultiAnimation> mini_title_animation_; | 115 scoped_ptr<ui::MultiAnimation> mini_title_animation_; |
| 114 | 116 |
| 115 struct TabImage { | 117 struct TabImage { |
| 116 SkBitmap* image_l; | 118 SkBitmap* image_l; |
| 117 SkBitmap* image_c; | 119 SkBitmap* image_c; |
| 118 SkBitmap* image_r; | 120 SkBitmap* image_r; |
| 119 int l_width; | 121 int l_width; |
| 120 int r_width; | 122 int r_width; |
| 121 int y_offset; | 123 int y_offset; |
| 122 }; | 124 }; |
| 123 static TabImage tab_active; | 125 static TabImage tab_active; |
| (...skipping 10 matching lines...) Expand all Loading... |
| 134 | 136 |
| 135 // The current color of the close button. | 137 // The current color of the close button. |
| 136 SkColor close_button_color_; | 138 SkColor close_button_color_; |
| 137 | 139 |
| 138 static bool initialized_; | 140 static bool initialized_; |
| 139 | 141 |
| 140 DISALLOW_COPY_AND_ASSIGN(Tab); | 142 DISALLOW_COPY_AND_ASSIGN(Tab); |
| 141 }; | 143 }; |
| 142 | 144 |
| 143 #endif // CHROME_BROWSER_UI_VIEWS_TABS_TAB_H_ | 145 #endif // CHROME_BROWSER_UI_VIEWS_TABS_TAB_H_ |
| OLD | NEW |