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

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

Issue 2698213004: Start removing some pre-md constants and related code. (Closed)
Patch Set: format Created 3 years, 10 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
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/common/system/tray/tray_details_view.h" 5 #include "ash/common/system/tray/tray_details_view.h"
6 6
7 #include "ash/common/ash_view_ids.h" 7 #include "ash/common/ash_view_ids.h"
8 #include "ash/common/system/tray/hover_highlight_view.h" 8 #include "ash/common/system/tray/hover_highlight_view.h"
9 #include "ash/common/system/tray/special_popup_row.h" 9 #include "ash/common/system/tray/special_popup_row.h"
10 #include "ash/common/system/tray/system_tray.h" 10 #include "ash/common/system/tray/system_tray.h"
(...skipping 108 matching lines...) Expand 10 before | Expand all | Expand 10 after
119 tray->ShowDefaultView(BUBBLE_CREATE_NEW); 119 tray->ShowDefaultView(BUBBLE_CREATE_NEW);
120 RunAllPendingInMessageLoop(); 120 RunAllPendingInMessageLoop();
121 tray->ShowDetailedView(test_item, 0, true, BUBBLE_USE_EXISTING); 121 tray->ShowDetailedView(test_item, 0, true, BUBBLE_USE_EXISTING);
122 RunAllPendingInMessageLoop(); 122 RunAllPendingInMessageLoop();
123 123
124 return test_item->detailed_view()->tray_popup_header_button(); 124 return test_item->detailed_view()->tray_popup_header_button();
125 } 125 }
126 126
127 void TransitionFromDetailedToDefaultView(TestDetailsView* detailed) { 127 void TransitionFromDetailedToDefaultView(TestDetailsView* detailed) {
128 detailed->TransitionToDefaultView(); 128 detailed->TransitionToDefaultView();
129 scoped_task_runner_->FastForwardBy(base::TimeDelta::FromMilliseconds( 129 scoped_task_runner_->FastForwardBy(
130 GetTrayConstant(TRAY_POPUP_TRANSITION_TO_DEFAULT_DELAY))); 130 base::TimeDelta::FromMilliseconds(kTrayDetailedViewTransitionDelayMs));
131 } 131 }
132 132
133 void FocusBackButton(TestDetailsView* detailed) { 133 void FocusBackButton(TestDetailsView* detailed) {
134 detailed->back_button_->RequestFocus(); 134 detailed->back_button_->RequestFocus();
135 } 135 }
136 136
137 private: 137 private:
138 // Used to control the |transition_delay_timer_|. 138 // Used to control the |transition_delay_timer_|.
139 base::ScopedMockTimeMessageLoopTaskRunner scoped_task_runner_; 139 base::ScopedMockTimeMessageLoopTaskRunner scoped_task_runner_;
140 140
(...skipping 85 matching lines...) Expand 10 before | Expand all | Expand 10 after
226 226
227 // Sticky header layer should be above the last child's layer. 227 // Sticky header layer should be above the last child's layer.
228 EXPECT_EQ(3u, layers.size()); 228 EXPECT_EQ(3u, layers.size());
229 EXPECT_EQ(view3->layer(), layers[0]); 229 EXPECT_EQ(view3->layer(), layers[0]);
230 EXPECT_EQ(view4->layer(), layers[1]); 230 EXPECT_EQ(view4->layer(), layers[1]);
231 EXPECT_EQ(view2->layer(), layers[2]); 231 EXPECT_EQ(view2->layer(), layers[2]);
232 } 232 }
233 233
234 } // namespace test 234 } // namespace test
235 } // namespace ash 235 } // namespace ash
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698