| OLD | NEW |
| 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 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/share_group.h" | 5 #include "gpu/command_buffer/client/share_group.h" |
| 6 | 6 |
| 7 #include <stdint.h> | 7 #include <stdint.h> |
| 8 | 8 |
| 9 #include <stack> | 9 #include <stack> |
| 10 #include <vector> | 10 #include <vector> |
| (...skipping 356 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 367 id_handlers_[i].reset(new StrictIdHandler(i)); | 367 id_handlers_[i].reset(new StrictIdHandler(i)); |
| 368 } | 368 } |
| 369 } | 369 } |
| 370 } | 370 } |
| 371 program_info_manager_.reset(new ProgramInfoManager); | 371 program_info_manager_.reset(new ProgramInfoManager); |
| 372 for (auto& range_id_handler : range_id_handlers_) { | 372 for (auto& range_id_handler : range_id_handlers_) { |
| 373 range_id_handler.reset(new RangeIdHandler()); | 373 range_id_handler.reset(new RangeIdHandler()); |
| 374 } | 374 } |
| 375 } | 375 } |
| 376 | 376 |
| 377 void ShareGroup::Lose() { | 377 void ShareGroup::set_program_info_manager(ProgramInfoManager* manager) { |
| 378 base::AutoLock hold(lost_lock_); | |
| 379 lost_ = true; | |
| 380 } | |
| 381 | |
| 382 bool ShareGroup::IsLost() const { | |
| 383 base::AutoLock hold(lost_lock_); | |
| 384 return lost_; | |
| 385 } | |
| 386 | |
| 387 void ShareGroup::SetProgramInfoManagerForTesting(ProgramInfoManager* manager) { | |
| 388 program_info_manager_.reset(manager); | 378 program_info_manager_.reset(manager); |
| 389 } | 379 } |
| 390 | 380 |
| 391 ShareGroup::~ShareGroup() {} | 381 ShareGroup::~ShareGroup() {} |
| 392 | 382 |
| 393 } // namespace gles2 | 383 } // namespace gles2 |
| 394 } // namespace gpu | 384 } // namespace gpu |
| OLD | NEW |