OLD | NEW |
1 // Copyright 2015 The Chromium Authors. All rights reserved. | 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 | 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 "chrome/browser/task_management/providers/web_contents/web_contents_tag
s_manager.h" | 5 #include "chrome/browser/task_management/providers/web_contents/web_contents_tag
s_manager.h" |
6 | 6 |
7 #include "base/memory/singleton.h" | 7 #include "base/memory/singleton.h" |
8 #include "chrome/browser/task_management/providers/web_contents/web_contents_tas
k_provider.h" | 8 #include "chrome/browser/task_management/providers/web_contents/web_contents_tas
k_provider.h" |
9 | 9 |
10 namespace task_management { | 10 namespace task_management { |
11 | 11 |
12 // static | 12 // static |
13 WebContentsTagsManager* WebContentsTagsManager::GetInstance() { | 13 WebContentsTagsManager* WebContentsTagsManager::GetInstance() { |
14 return Singleton<WebContentsTagsManager>::get(); | 14 return base::Singleton<WebContentsTagsManager>::get(); |
15 } | 15 } |
16 | 16 |
17 void WebContentsTagsManager::AddTag(WebContentsTag* tag) { | 17 void WebContentsTagsManager::AddTag(WebContentsTag* tag) { |
18 DCHECK(tag); | 18 DCHECK(tag); |
19 tracked_tags_.push_back(tag); | 19 tracked_tags_.push_back(tag); |
20 | 20 |
21 if (provider_) | 21 if (provider_) |
22 provider_->OnWebContentsTagCreated(tag); | 22 provider_->OnWebContentsTagCreated(tag); |
23 } | 23 } |
24 | 24 |
(...skipping 30 matching lines...) Expand all Loading... |
55 } | 55 } |
56 | 56 |
57 WebContentsTagsManager::WebContentsTagsManager() | 57 WebContentsTagsManager::WebContentsTagsManager() |
58 : provider_(nullptr) { | 58 : provider_(nullptr) { |
59 } | 59 } |
60 | 60 |
61 WebContentsTagsManager::~WebContentsTagsManager() { | 61 WebContentsTagsManager::~WebContentsTagsManager() { |
62 } | 62 } |
63 | 63 |
64 } // namespace task_management | 64 } // namespace task_management |
OLD | NEW |