| 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 #include "chrome/browser/ui/views/tabs/tab_strip.h" | 5 #include "chrome/browser/ui/views/tabs/tab_strip.h" |
| 6 | 6 |
| 7 #include <stddef.h> | 7 #include <stddef.h> |
| 8 | 8 |
| 9 #include <algorithm> | 9 #include <algorithm> |
| 10 #include <iterator> | 10 #include <iterator> |
| (...skipping 1306 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1317 } | 1317 } |
| 1318 | 1318 |
| 1319 bool TabStrip::IsImmersiveStyle() const { | 1319 bool TabStrip::IsImmersiveStyle() const { |
| 1320 return immersive_style_; | 1320 return immersive_style_; |
| 1321 } | 1321 } |
| 1322 | 1322 |
| 1323 SkColor TabStrip::GetToolbarTopSeparatorColor() const { | 1323 SkColor TabStrip::GetToolbarTopSeparatorColor() const { |
| 1324 return controller_->GetToolbarTopSeparatorColor(); | 1324 return controller_->GetToolbarTopSeparatorColor(); |
| 1325 } | 1325 } |
| 1326 | 1326 |
| 1327 // Returns the accessible tab name for the tab. | |
| 1328 base::string16 TabStrip::GetAccessibleTabName() const { | |
| 1329 return controller_->GetAccessibleTabName(); | |
| 1330 } | |
| 1331 | |
| 1332 int TabStrip::GetBackgroundResourceId(bool* custom_image) const { | 1327 int TabStrip::GetBackgroundResourceId(bool* custom_image) const { |
| 1333 const ui::ThemeProvider* tp = GetThemeProvider(); | 1328 const ui::ThemeProvider* tp = GetThemeProvider(); |
| 1334 | 1329 |
| 1335 if (GetWidget()->ShouldWindowContentsBeTransparent()) { | 1330 if (GetWidget()->ShouldWindowContentsBeTransparent()) { |
| 1336 const int kBackgroundIdGlass = IDR_THEME_TAB_BACKGROUND_V; | 1331 const int kBackgroundIdGlass = IDR_THEME_TAB_BACKGROUND_V; |
| 1337 *custom_image = tp->HasCustomImage(kBackgroundIdGlass); | 1332 *custom_image = tp->HasCustomImage(kBackgroundIdGlass); |
| 1338 return kBackgroundIdGlass; | 1333 return kBackgroundIdGlass; |
| 1339 } | 1334 } |
| 1340 | 1335 |
| 1341 // If a custom theme does not provide a replacement tab background, but does | 1336 // If a custom theme does not provide a replacement tab background, but does |
| (...skipping 1458 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 2800 ConvertPointToViewAndGetEventHandler(this, newtab_button_, point); | 2795 ConvertPointToViewAndGetEventHandler(this, newtab_button_, point); |
| 2801 if (view) | 2796 if (view) |
| 2802 return view; | 2797 return view; |
| 2803 } | 2798 } |
| 2804 Tab* tab = FindTabForEvent(point); | 2799 Tab* tab = FindTabForEvent(point); |
| 2805 if (tab) | 2800 if (tab) |
| 2806 return ConvertPointToViewAndGetEventHandler(this, tab, point); | 2801 return ConvertPointToViewAndGetEventHandler(this, tab, point); |
| 2807 } | 2802 } |
| 2808 return this; | 2803 return this; |
| 2809 } | 2804 } |
| OLD | NEW |