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

Side by Side Diff: ash/system/tray/tray_details_view_unittest.cc

Issue 2831023003: Refactor AddScrollListItem() in system menu detailed views (Closed)
Patch Set: Rebased Created 3 years, 8 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 unified diff | Download patch
« no previous file with comments | « ash/system/tray/tray_details_view.cc ('k') | ash/system/tray/tray_popup_utils.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2013 The Chromium Authors. All rights reserved. 1 // Copyright 2013 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 "ash/system/tray/tray_details_view.h" 5 #include "ash/system/tray/tray_details_view.h"
6 6
7 #include "ash/ash_view_ids.h" 7 #include "ash/ash_view_ids.h"
8 #include "ash/resources/grit/ash_resources.h" 8 #include "ash/resources/grit/ash_resources.h"
9 #include "ash/strings/grit/ash_strings.h" 9 #include "ash/strings/grit/ash_strings.h"
10 #include "ash/system/tray/system_tray.h" 10 #include "ash/system/tray/system_tray.h"
(...skipping 25 matching lines...) Expand all
36 } 36 }
37 37
38 ~TestDetailsView() override {} 38 ~TestDetailsView() override {}
39 39
40 TrayPopupHeaderButton* tray_popup_header_button() { 40 TrayPopupHeaderButton* tray_popup_header_button() {
41 return tray_popup_header_button_; 41 return tray_popup_header_button_;
42 } 42 }
43 43
44 void CreateScrollerViews() { CreateScrollableList(); } 44 void CreateScrollerViews() { CreateScrollableList(); }
45 45
46 views::View* scroll_content() const {
47 return TrayDetailsView::scroll_content();
48 }
49
46 private: 50 private:
47 TrayPopupHeaderButton* tray_popup_header_button_; 51 TrayPopupHeaderButton* tray_popup_header_button_;
48 52
49 DISALLOW_COPY_AND_ASSIGN(TestDetailsView); 53 DISALLOW_COPY_AND_ASSIGN(TestDetailsView);
50 }; 54 };
51 55
52 // Trivial item implementation that tracks its views for testing. 56 // Trivial item implementation that tracks its views for testing.
53 class TestItem : public SystemTrayItem { 57 class TestItem : public SystemTrayItem {
54 public: 58 public:
55 TestItem() 59 TestItem()
(...skipping 166 matching lines...) Expand 10 before | Expand all | Expand 10 after
222 226
223 // Sticky header layer should be above the last child's layer. 227 // Sticky header layer should be above the last child's layer.
224 EXPECT_EQ(3u, layers.size()); 228 EXPECT_EQ(3u, layers.size());
225 EXPECT_EQ(view3->layer(), layers[0]); 229 EXPECT_EQ(view3->layer(), layers[0]);
226 EXPECT_EQ(view4->layer(), layers[1]); 230 EXPECT_EQ(view4->layer(), layers[1]);
227 EXPECT_EQ(view2->layer(), layers[2]); 231 EXPECT_EQ(view2->layer(), layers[2]);
228 } 232 }
229 233
230 } // namespace test 234 } // namespace test
231 } // namespace ash 235 } // namespace ash
OLDNEW
« no previous file with comments | « ash/system/tray/tray_details_view.cc ('k') | ash/system/tray/tray_popup_utils.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698