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

Side by Side Diff: gpu/command_buffer/client/mapped_memory_unittest.cc

Issue 3828009: Move scoped_nsdisable_screen_update from base to app/mac... (Closed) Base URL: svn://chrome-svn/chrome/trunk/src/
Patch Set: '' Created 10 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
OLDNEW
1 // Copyright (c) 2009 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2009 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 "gpu/command_buffer/client/mapped_memory.h" 5 #include "gpu/command_buffer/client/mapped_memory.h"
6 #include "base/callback.h" 6 #include "base/callback.h"
7 #include "base/message_loop.h" 7 #include "base/message_loop.h"
8 #include "base/scoped_nsautorelease_pool.h" 8 #include "base/mac/scoped_nsautorelease_pool.h"
9 #include "base/scoped_ptr.h" 9 #include "base/scoped_ptr.h"
10 #include "gpu/command_buffer/client/cmd_buffer_helper.h" 10 #include "gpu/command_buffer/client/cmd_buffer_helper.h"
11 #include "gpu/command_buffer/service/mocks.h" 11 #include "gpu/command_buffer/service/mocks.h"
12 #include "gpu/command_buffer/service/command_buffer_service.h" 12 #include "gpu/command_buffer/service/command_buffer_service.h"
13 #include "gpu/command_buffer/service/gpu_processor.h" 13 #include "gpu/command_buffer/service/gpu_processor.h"
14 #include "testing/gtest/include/gtest/gtest.h" 14 #include "testing/gtest/include/gtest/gtest.h"
15 15
16 namespace gpu { 16 namespace gpu {
17 17
18 using testing::Return; 18 using testing::Return;
(...skipping 38 matching lines...) Expand 10 before | Expand all | Expand 10 after
57 api_mock_->set_engine(gpu_processor_.get()); 57 api_mock_->set_engine(gpu_processor_.get());
58 58
59 helper_.reset(new CommandBufferHelper(command_buffer_.get())); 59 helper_.reset(new CommandBufferHelper(command_buffer_.get()));
60 helper_->Initialize(kBufferSize); 60 helper_->Initialize(kBufferSize);
61 } 61 }
62 62
63 int32 GetToken() { 63 int32 GetToken() {
64 return command_buffer_->GetState().token; 64 return command_buffer_->GetState().token;
65 } 65 }
66 66
67 base::ScopedNSAutoreleasePool autorelease_pool_; 67 base::mac::ScopedNSAutoreleasePool autorelease_pool_;
68 MessageLoop message_loop_; 68 MessageLoop message_loop_;
69 scoped_ptr<AsyncAPIMock> api_mock_; 69 scoped_ptr<AsyncAPIMock> api_mock_;
70 scoped_ptr<CommandBufferService> command_buffer_; 70 scoped_ptr<CommandBufferService> command_buffer_;
71 scoped_ptr<GPUProcessor> gpu_processor_; 71 scoped_ptr<GPUProcessor> gpu_processor_;
72 CommandParser* parser_; 72 CommandParser* parser_;
73 scoped_ptr<CommandBufferHelper> helper_; 73 scoped_ptr<CommandBufferHelper> helper_;
74 }; 74 };
75 75
76 #ifndef _MSC_VER 76 #ifndef _MSC_VER
77 const unsigned int MappedMemoryTestBase::kBufferSize; 77 const unsigned int MappedMemoryTestBase::kBufferSize;
(...skipping 171 matching lines...) Expand 10 before | Expand all | Expand 10 after
249 // Check we can alloc. 249 // Check we can alloc.
250 int32 id1 = -1; 250 int32 id1 = -1;
251 unsigned int offset1 = 0xFFFFFFFFU; 251 unsigned int offset1 = 0xFFFFFFFFU;
252 void* mem1 = manager_->Alloc(kSize, &id1, &offset1); 252 void* mem1 = manager_->Alloc(kSize, &id1, &offset1);
253 ASSERT_TRUE(mem1); 253 ASSERT_TRUE(mem1);
254 } 254 }
255 255
256 } // namespace gpu 256 } // namespace gpu
257 257
258 258
OLDNEW
« no previous file with comments | « gpu/command_buffer/client/fenced_allocator_test.cc ('k') | gpu/command_buffer/client/ring_buffer_test.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698