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

Side by Side Diff: ui/views/test/views_test_helper_mac.mm

Issue 378663002: MacViews: Disable animations when running views_unittests. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Create ViewsTestHelperMac Created 6 years, 5 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 | Annotate | Revision Log
« no previous file with comments | « ui/views/test/views_test_helper_mac.h ('k') | ui/views/views.gyp » ('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 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 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 "ui/views/test/views_test_helper.h" 5 #include "ui/views/test/views_test_helper_mac.h"
6
7 #include "ui/compositor/scoped_animation_duration_scale_mode.h"
6 8
7 namespace views { 9 namespace views {
8 10
9 #if !defined(USE_AURA)
10 // static 11 // static
11 ViewsTestHelper* ViewsTestHelper::Create(base::MessageLoopForUI* message_loop, 12 ViewsTestHelper* ViewsTestHelper::Create(base::MessageLoopForUI* message_loop,
12 ui::ContextFactory* context_factory) { 13 ui::ContextFactory* context_factory) {
13 return new ViewsTestHelper; 14 return new ViewsTestHelperMac;
14 }
15 #endif
16
17 ViewsTestHelper::ViewsTestHelper() {
18 } 15 }
19 16
20 ViewsTestHelper::~ViewsTestHelper() { 17 ViewsTestHelperMac::ViewsTestHelperMac()
18 : zero_duration_mode_(new ui::ScopedAnimationDurationScaleMode(
19 ui::ScopedAnimationDurationScaleMode::ZERO_DURATION)) {
21 } 20 }
22 21
23 void ViewsTestHelper::SetUp() { 22 ViewsTestHelperMac::~ViewsTestHelperMac() {
24 }
25
26 void ViewsTestHelper::TearDown() {
27 }
28
29 gfx::NativeView ViewsTestHelper::GetContext() {
30 return NULL;
31 } 23 }
32 24
33 } // namespace views 25 } // namespace views
OLDNEW
« no previous file with comments | « ui/views/test/views_test_helper_mac.h ('k') | ui/views/views.gyp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698