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

Side by Side Diff: ui/gfx/compositor/test/compositor_test_support.cc

Issue 9288053: Remove old (pre-webkit) compositor (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: fix test Created 8 years, 11 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/gfx/compositor/layer_unittest.cc ('k') | ui/gfx/compositor/test/test_compositor.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 (c) 2011 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2011 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/gfx/compositor/test/compositor_test_support.h" 5 #include "ui/gfx/compositor/test/compositor_test_support.h"
6 6
7 #if defined(USE_WEBKIT_COMPOSITOR)
8 #include "base/compiler_specific.h" 7 #include "base/compiler_specific.h"
9 #include "third_party/WebKit/Source/WebKit/chromium/public/WebKit.h" 8 #include "third_party/WebKit/Source/WebKit/chromium/public/WebKit.h"
10 #include "webkit/glue/webkitplatformsupport_impl.h" 9 #include "webkit/glue/webkitplatformsupport_impl.h"
11 #endif
12 10
13 namespace ui { 11 namespace ui {
14 12
15 #if defined(USE_WEBKIT_COMPOSITOR)
16 class CompositorTestPlatformSupport: 13 class CompositorTestPlatformSupport:
17 public NON_EXPORTED_BASE(webkit_glue::WebKitPlatformSupportImpl) { 14 public NON_EXPORTED_BASE(webkit_glue::WebKitPlatformSupportImpl) {
18 public: 15 public:
19 virtual string16 GetLocalizedString(int message_id) OVERRIDE { 16 virtual string16 GetLocalizedString(int message_id) OVERRIDE {
20 return string16(); 17 return string16();
21 } 18 }
22 19
23 virtual base::StringPiece GetDataResource(int resource_id) OVERRIDE { 20 virtual base::StringPiece GetDataResource(int resource_id) OVERRIDE {
24 return base::StringPiece(); 21 return base::StringPiece();
25 } 22 }
(...skipping 11 matching lines...) Expand all
37 34
38 virtual webkit_glue::WebSocketStreamHandleBridge* CreateWebSocketBridge( 35 virtual webkit_glue::WebSocketStreamHandleBridge* CreateWebSocketBridge(
39 WebKit::WebSocketStreamHandle* handle, 36 WebKit::WebSocketStreamHandle* handle,
40 webkit_glue::WebSocketStreamHandleDelegate* delegate) OVERRIDE { 37 webkit_glue::WebSocketStreamHandleDelegate* delegate) OVERRIDE {
41 NOTREACHED(); 38 NOTREACHED();
42 return NULL; 39 return NULL;
43 } 40 }
44 }; 41 };
45 42
46 static CompositorTestPlatformSupport* g_webkit_support; 43 static CompositorTestPlatformSupport* g_webkit_support;
47 #endif
48 44
49 void CompositorTestSupport::Initialize() { 45 void CompositorTestSupport::Initialize() {
50 #if defined(USE_WEBKIT_COMPOSITOR)
51 DCHECK(!g_webkit_support); 46 DCHECK(!g_webkit_support);
52 g_webkit_support = new CompositorTestPlatformSupport; 47 g_webkit_support = new CompositorTestPlatformSupport;
53 WebKit::initialize(g_webkit_support); 48 WebKit::initialize(g_webkit_support);
54 #endif
55 } 49 }
56 50
57 void CompositorTestSupport::Terminate() { 51 void CompositorTestSupport::Terminate() {
58 #if defined(USE_WEBKIT_COMPOSITOR)
59 DCHECK(g_webkit_support); 52 DCHECK(g_webkit_support);
60 WebKit::shutdown(); 53 WebKit::shutdown();
61 delete g_webkit_support; 54 delete g_webkit_support;
62 g_webkit_support = NULL; 55 g_webkit_support = NULL;
63 #endif
64 } 56 }
65 57
66 } // namespace ui 58 } // namespace ui
OLDNEW
« no previous file with comments | « ui/gfx/compositor/layer_unittest.cc ('k') | ui/gfx/compositor/test/test_compositor.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698