| 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_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 | 7 |
| 8 #include <list> | 8 #include <list> |
| 9 #include <string> | 9 #include <string> |
| 10 | 10 |
| (...skipping 162 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 173 virtual bool OnMousePressed(const ui::MouseEvent& event) OVERRIDE; | 173 virtual bool OnMousePressed(const ui::MouseEvent& event) OVERRIDE; |
| 174 virtual bool OnMouseDragged(const ui::MouseEvent& event) OVERRIDE; | 174 virtual bool OnMouseDragged(const ui::MouseEvent& event) OVERRIDE; |
| 175 virtual void OnMouseReleased(const ui::MouseEvent& event) OVERRIDE; | 175 virtual void OnMouseReleased(const ui::MouseEvent& event) OVERRIDE; |
| 176 virtual void OnMouseCaptureLost() OVERRIDE; | 176 virtual void OnMouseCaptureLost() OVERRIDE; |
| 177 virtual void OnMouseEntered(const ui::MouseEvent& event) OVERRIDE; | 177 virtual void OnMouseEntered(const ui::MouseEvent& event) OVERRIDE; |
| 178 virtual void OnMouseMoved(const ui::MouseEvent& event) OVERRIDE; | 178 virtual void OnMouseMoved(const ui::MouseEvent& event) OVERRIDE; |
| 179 virtual void OnMouseExited(const ui::MouseEvent& event) OVERRIDE; | 179 virtual void OnMouseExited(const ui::MouseEvent& event) OVERRIDE; |
| 180 virtual void GetAccessibleState(ui::AccessibleViewState* state) OVERRIDE; | 180 virtual void GetAccessibleState(ui::AccessibleViewState* state) OVERRIDE; |
| 181 | 181 |
| 182 // Overridden from ui::EventHandler: | 182 // Overridden from ui::EventHandler: |
| 183 virtual ui::EventResult OnGestureEvent(ui::GestureEvent* event) OVERRIDE; | 183 virtual void OnGestureEvent(ui::GestureEvent* event) OVERRIDE; |
| 184 | 184 |
| 185 // Returns the bounds of the title and icon. | 185 // Returns the bounds of the title and icon. |
| 186 const gfx::Rect& GetTitleBounds() const; | 186 const gfx::Rect& GetTitleBounds() const; |
| 187 const gfx::Rect& GetIconBounds() const; | 187 const gfx::Rect& GetIconBounds() const; |
| 188 | 188 |
| 189 // Invoked from SetData after |data_| has been updated to the new data. | 189 // Invoked from SetData after |data_| has been updated to the new data. |
| 190 void DataChanged(const TabRendererData& old); | 190 void DataChanged(const TabRendererData& old); |
| 191 | 191 |
| 192 // Paint with the normal tab style. | 192 // Paint with the normal tab style. |
| 193 void PaintTab(gfx::Canvas* canvas); | 193 void PaintTab(gfx::Canvas* canvas); |
| (...skipping 156 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 350 static int font_height_; | 350 static int font_height_; |
| 351 | 351 |
| 352 // As the majority of the tabs are inactive, and painting tabs is slowish, | 352 // As the majority of the tabs are inactive, and painting tabs is slowish, |
| 353 // we cache a handful of the inactive tab backgrounds here. | 353 // we cache a handful of the inactive tab backgrounds here. |
| 354 static ImageCache* image_cache_; | 354 static ImageCache* image_cache_; |
| 355 | 355 |
| 356 DISALLOW_COPY_AND_ASSIGN(Tab); | 356 DISALLOW_COPY_AND_ASSIGN(Tab); |
| 357 }; | 357 }; |
| 358 | 358 |
| 359 #endif // CHROME_BROWSER_UI_VIEWS_TABS_TAB_H_ | 359 #endif // CHROME_BROWSER_UI_VIEWS_TABS_TAB_H_ |
| OLD | NEW |