OLD | NEW |
---|---|
(Empty) | |
1 // Copyright 2014 The Chromium Authors. All rights reserved. | |
2 // Use of this source code is governed by a BSD-style license that can be | |
3 // found in the LICENSE file. | |
4 | |
5 #include "ui/gl/android/surface_texture_tracker.h" | |
6 | |
7 namespace gfx { | |
8 namespace { | |
9 SurfaceTextureTracker* g_instance = NULL; | |
epennerAtGoogle
2014/03/12 00:45:06
Same on this one. Can you use LazyInstance or comm
reveman
2014/03/12 16:07:06
Same answer.
| |
10 } // namespace | |
11 | |
12 // static | |
13 SurfaceTextureTracker* SurfaceTextureTracker::GetInstance() { | |
epennerAtGoogle
2014/03/12 00:45:06
This is a lot better than an 'extern' but not _hug
reveman
2014/03/12 16:07:06
I'd like to get this working with out-of-proc GPU
epennerAtGoogle
2014/03/12 19:46:28
If sievers@ is okay with it then no worries here.
| |
14 DCHECK(g_instance); | |
15 return g_instance; | |
16 } | |
17 | |
18 // static | |
19 void SurfaceTextureTracker::InitInstance(SurfaceTextureTracker* tracker) { | |
20 DCHECK(!g_instance || !tracker); | |
21 g_instance = tracker; | |
22 } | |
23 | |
24 } // namespace gfx | |
OLD | NEW |