1 // Copyright 2015 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.
5 #include "chrome/browser/task_management/providers/browser_process_task_provider.h"
7 namespace task_management
{
9 BrowserProcessTaskProvider::BrowserProcessTaskProvider()
10 : browser_process_task_() {
13 BrowserProcessTaskProvider::~BrowserProcessTaskProvider() {
16 Task
* BrowserProcessTaskProvider::GetTaskOfUrlRequest(int origin_pid
,
19 if (origin_pid
== 0 && child_id
== -1)
20 return &browser_process_task_
;
25 void BrowserProcessTaskProvider::StartUpdating() {
26 NotifyObserverTaskAdded(&browser_process_task_
);
29 void BrowserProcessTaskProvider::StopUpdating() {
30 // There's nothing to do here. The browser process task live as long as the
31 // browser lives and when StopUpdating() is called the |observer_| has already
35 } // namespace task_management