This source file includes following definitions.
- Get
#include "content/public/renderer/render_thread.h"
#include "base/lazy_instance.h"
#include "base/threading/thread_local.h"
namespace content {
static base::LazyInstance<base::ThreadLocalPointer<RenderThread> > lazy_tls =
LAZY_INSTANCE_INITIALIZER;
RenderThread* RenderThread::Get() {
return lazy_tls.Pointer()->Get();
}
RenderThread::RenderThread() {
lazy_tls.Pointer()->Set(this);
}
RenderThread::~RenderThread() {
lazy_tls.Pointer()->Set(NULL);
}
}