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

Side by Side Diff: cc/test/layer_tree_test_common.cc

Issue 11474050: cc: Unify namespaces for all test files (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: rebase Created 8 years 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 | « cc/test/layer_tree_test_common.h ('k') | cc/test/mock_quad_culler.cc » ('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 2011 The Chromium Authors. All rights reserved. 1 // Copyright 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 "cc/test/layer_tree_test_common.h" 5 #include "cc/test/layer_tree_test_common.h"
6 6
7 #include "base/stl_util.h" 7 #include "base/stl_util.h"
8 #include "cc/active_animation.h" 8 #include "cc/active_animation.h"
9 #include "cc/content_layer.h" 9 #include "cc/content_layer.h"
10 #include "cc/font_atlas.h" 10 #include "cc/font_atlas.h"
(...skipping 17 matching lines...) Expand all
28 28
29 using namespace WebKit; 29 using namespace WebKit;
30 30
31 namespace cc { 31 namespace cc {
32 32
33 scoped_ptr<CompositorFakeWebGraphicsContext3DWithTextureTracking> CompositorFake WebGraphicsContext3DWithTextureTracking::create(Attributes attrs) 33 scoped_ptr<CompositorFakeWebGraphicsContext3DWithTextureTracking> CompositorFake WebGraphicsContext3DWithTextureTracking::create(Attributes attrs)
34 { 34 {
35 return make_scoped_ptr(new CompositorFakeWebGraphicsContext3DWithTextureTrac king(attrs)); 35 return make_scoped_ptr(new CompositorFakeWebGraphicsContext3DWithTextureTrac king(attrs));
36 } 36 }
37 37
38 WebGLId CompositorFakeWebGraphicsContext3DWithTextureTracking::createTexture() 38 WebKit::WebGLId CompositorFakeWebGraphicsContext3DWithTextureTracking::createTex ture()
39 { 39 {
40 WebGLId texture = m_textures.size() + 1; 40 WebKit::WebGLId texture = m_textures.size() + 1;
41 m_textures.push_back(texture); 41 m_textures.push_back(texture);
42 return texture; 42 return texture;
43 } 43 }
44 44
45 void CompositorFakeWebGraphicsContext3DWithTextureTracking::deleteTexture(WebGLI d texture) 45 void CompositorFakeWebGraphicsContext3DWithTextureTracking::deleteTexture(WebKit ::WebGLId texture)
46 { 46 {
47 std::vector<WebGLId>::iterator i(std::find(m_textures.begin(), m_textures.en d(), texture)); 47 std::vector<WebKit::WebGLId>::iterator i(std::find(m_textures.begin(), m_tex tures.end(), texture));
48 if (i != m_textures.end()) 48 if (i != m_textures.end())
49 m_textures.erase(i); 49 m_textures.erase(i);
50 } 50 }
51 51
52 void CompositorFakeWebGraphicsContext3DWithTextureTracking::bindTexture(WGC3Denu m /* target */, WebGLId texture) 52 void CompositorFakeWebGraphicsContext3DWithTextureTracking::bindTexture(WebKit:: WGC3Denum /* target */, WebKit::WebGLId texture)
53 { 53 {
54 m_usedTextures.insert(texture); 54 m_usedTextures.insert(texture);
55 } 55 }
56 56
57 int CompositorFakeWebGraphicsContext3DWithTextureTracking::numTextures() const { return static_cast<int>(m_textures.size()); } 57 int CompositorFakeWebGraphicsContext3DWithTextureTracking::numTextures() const { return static_cast<int>(m_textures.size()); }
58 int CompositorFakeWebGraphicsContext3DWithTextureTracking::texture(int i) const { return m_textures[i]; } 58 int CompositorFakeWebGraphicsContext3DWithTextureTracking::texture(int i) const { return m_textures[i]; }
59 void CompositorFakeWebGraphicsContext3DWithTextureTracking::resetTextures() { m_ textures.clear(); } 59 void CompositorFakeWebGraphicsContext3DWithTextureTracking::resetTextures() { m_ textures.clear(); }
60 60
61 int CompositorFakeWebGraphicsContext3DWithTextureTracking::numUsedTextures() con st { return static_cast<int>(m_usedTextures.size()); } 61 int CompositorFakeWebGraphicsContext3DWithTextureTracking::numUsedTextures() con st { return static_cast<int>(m_usedTextures.size()); }
62 bool CompositorFakeWebGraphicsContext3DWithTextureTracking::usedTexture(int text ure) const 62 bool CompositorFakeWebGraphicsContext3DWithTextureTracking::usedTexture(int text ure) const
(...skipping 442 matching lines...) Expand 10 before | Expand all | Expand 10 after
505 ASSERT_FALSE(m_layerTreeHost.get()); 505 ASSERT_FALSE(m_layerTreeHost.get());
506 m_client.reset(); 506 m_client.reset();
507 if (m_timedOut) { 507 if (m_timedOut) {
508 FAIL() << "Test timed out"; 508 FAIL() << "Test timed out";
509 return; 509 return;
510 } 510 }
511 afterTest(); 511 afterTest();
512 } 512 }
513 513
514 } // namespace cc 514 } // namespace cc
OLDNEW
« no previous file with comments | « cc/test/layer_tree_test_common.h ('k') | cc/test/mock_quad_culler.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698