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

Side by Side Diff: content/browser/gpu/compositor_util_browsertest.cc

Issue 26853004: Enable delegated rendering on Aura Windows and Linux (not Chrome OS) (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 7 years, 2 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 | « content/browser/gpu/compositor_util.cc ('k') | no next file » | 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 "content/browser/gpu/compositor_util.h" 5 #include "content/browser/gpu/compositor_util.h"
6 #include "content/test/content_browser_test.h" 6 #include "content/test/content_browser_test.h"
7 7
8 #if defined(OS_MACOSX) 8 #if defined(OS_MACOSX)
9 #include "base/mac/mac_util.h" 9 #include "base/mac/mac_util.h"
10 #elif defined(OS_WIN) 10 #elif defined(OS_WIN)
11 #include "base/win/windows_version.h" 11 #include "base/win/windows_version.h"
12 #endif 12 #endif
13 13
14 namespace content { 14 namespace content {
15 15
16 typedef ContentBrowserTest CompositorUtilTest; 16 typedef ContentBrowserTest CompositorUtilTest;
17 17
18 // Test that threaded compositing and FCM are in the expected mode on the bots 18 // Test that threaded compositing and FCM are in the expected mode on the bots
19 // for all platforms. 19 // for all platforms.
20 IN_PROC_BROWSER_TEST_F(CompositorUtilTest, CompositingModeAsExpected) { 20 IN_PROC_BROWSER_TEST_F(CompositorUtilTest, CompositingModeAsExpected) {
21 enum CompositingMode { 21 enum CompositingMode {
22 DISABLED, 22 DISABLED,
23 ENABLED, 23 ENABLED,
24 THREADED, 24 THREADED, // Implies FCM
25 DELEGATED, // Implies threaded
25 } expected_mode = DISABLED; 26 } expected_mode = DISABLED;
26 #if defined(OS_ANDROID) || defined(USE_AURA) 27 #if defined(USE_AURA)
28 #if defined(OS_CHROMEOS)
29 expected_mode = THREADED;
30 #else
31 expected_mode = DELEGATED;
32 #endif
33 #elif defined(OS_ANDROID)
27 expected_mode = THREADED; 34 expected_mode = THREADED;
28 #elif defined(OS_MACOSX) 35 #elif defined(OS_MACOSX)
29 if (base::mac::IsOSMountainLionOrLater()) 36 if (base::mac::IsOSMountainLionOrLater())
30 expected_mode = ENABLED; 37 expected_mode = ENABLED;
31 #elif defined(OS_WIN) 38 #elif defined(OS_WIN)
32 if (base::win::GetVersion() >= base::win::VERSION_VISTA) 39 if (base::win::GetVersion() >= base::win::VERSION_VISTA)
33 expected_mode = ENABLED; 40 expected_mode = ENABLED;
34 #endif 41 #endif
35 42
36 EXPECT_EQ(expected_mode == ENABLED || expected_mode == THREADED, 43 EXPECT_EQ(expected_mode == ENABLED ||
44 expected_mode == THREADED ||
45 expected_mode == DELEGATED,
37 IsForceCompositingModeEnabled()); 46 IsForceCompositingModeEnabled());
38 EXPECT_EQ(expected_mode == THREADED, IsThreadedCompositingEnabled()); 47 EXPECT_EQ(expected_mode == THREADED ||
48 expected_mode == DELEGATED,
49 IsThreadedCompositingEnabled());
50 EXPECT_EQ(expected_mode == DELEGATED,
51 IsDelegatedRendererEnabled());
39 } 52 }
40 53
41 } 54 }
OLDNEW
« no previous file with comments | « content/browser/gpu/compositor_util.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698