This source file includes following definitions.
- EnsureKeepAlive
- FreeKeepAlive
#include "chrome/browser/ui/app_list/keep_alive_service_impl.h"
#include "chrome/browser/lifetime/application_lifetime.h"
ScopedKeepAlive::ScopedKeepAlive() { chrome::IncrementKeepAliveCount(); }
ScopedKeepAlive::~ScopedKeepAlive() { chrome::DecrementKeepAliveCount(); }
KeepAliveServiceImpl::KeepAliveServiceImpl() {
}
KeepAliveServiceImpl::~KeepAliveServiceImpl() {
}
void KeepAliveServiceImpl::EnsureKeepAlive() {
if (!keep_alive_)
keep_alive_.reset(new ScopedKeepAlive());
}
void KeepAliveServiceImpl::FreeKeepAlive() {
if (keep_alive_)
keep_alive_.reset();
}