Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(3166)

Unified Diff: chrome/browser/ui/views/tabs/tab_strip.h

Issue 598013003: Added views::ViewModelT<T>, a type-safe template version of ViewModel. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@appsgridview-static-casts
Patch Set: Created 6 years, 3 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: chrome/browser/ui/views/tabs/tab_strip.h
diff --git a/chrome/browser/ui/views/tabs/tab_strip.h b/chrome/browser/ui/views/tabs/tab_strip.h
index 25f3610e3d2f1c594908d2b35845f93023100889..df6d7f7dd1dced9acbe0859e241af2b7aa3bf14a 100644
--- a/chrome/browser/ui/views/tabs/tab_strip.h
+++ b/chrome/browser/ui/views/tabs/tab_strip.h
@@ -143,7 +143,7 @@ class TabStrip : public views::View,
// Returns the Tab at |index|.
Tab* tab_at(int index) const {
- return static_cast<Tab*>(tabs_.view_at(index));
+ return tabs_.view_at(index);
}
// Returns the index of the specified tab in the model coordinate system, or
@@ -595,7 +595,7 @@ class TabStrip : public views::View,
// |tabs_closing_map_|. When the animation completes the tab is removed from
// |tabs_closing_map_|. The painting code ensures both sets of tabs are
// painted, and the event handling code ensures only tabs in |tabs_| are used.
- views::ViewModel tabs_;
+ views::ViewModel<Tab> tabs_;
TabsClosingMap tabs_closing_map_;
scoped_ptr<TabStripController> controller_;

Powered by Google App Engine
This is Rietveld 408576698