OLD | NEW |
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 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/memory_details.h" | 5 #include "chrome/browser/memory_details.h" |
6 | 6 |
7 #include <algorithm> | 7 #include <algorithm> |
8 #include <set> | 8 #include <set> |
9 | 9 |
10 #include "base/bind.h" | 10 #include "base/bind.h" |
11 #include "base/file_version_info.h" | 11 #include "base/file_version_info.h" |
12 #include "base/metrics/histogram.h" | 12 #include "base/metrics/histogram_macros.h" |
13 #include "base/strings/string_util.h" | 13 #include "base/strings/string_util.h" |
14 #include "base/strings/stringprintf.h" | 14 #include "base/strings/stringprintf.h" |
15 #include "base/strings/utf_string_conversions.h" | 15 #include "base/strings/utf_string_conversions.h" |
16 #include "build/build_config.h" | 16 #include "build/build_config.h" |
17 #include "chrome/browser/profiles/profile.h" | 17 #include "chrome/browser/profiles/profile.h" |
18 #include "chrome/grit/generated_resources.h" | 18 #include "chrome/grit/generated_resources.h" |
19 #include "components/nacl/common/nacl_process_type.h" | 19 #include "components/nacl/common/nacl_process_type.h" |
20 #include "components/strings/grit/components_strings.h" | 20 #include "components/strings/grit/components_strings.h" |
21 #include "content/public/browser/browser_child_process_host_iterator.h" | 21 #include "content/public/browser/browser_child_process_host_iterator.h" |
22 #include "content/public/browser/browser_thread.h" | 22 #include "content/public/browser/browser_thread.h" |
(...skipping 321 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
344 // Get rid of other Chrome processes that are from a different profile. | 344 // Get rid of other Chrome processes that are from a different profile. |
345 auto is_unknown = [](ProcessMemoryInformation& process) { | 345 auto is_unknown = [](ProcessMemoryInformation& process) { |
346 return process.process_type == content::PROCESS_TYPE_UNKNOWN; | 346 return process.process_type == content::PROCESS_TYPE_UNKNOWN; |
347 }; | 347 }; |
348 auto& vector = chrome_browser->processes; | 348 auto& vector = chrome_browser->processes; |
349 vector.erase(std::remove_if(vector.begin(), vector.end(), is_unknown), | 349 vector.erase(std::remove_if(vector.begin(), vector.end(), is_unknown), |
350 vector.end()); | 350 vector.end()); |
351 | 351 |
352 OnDetailsAvailable(); | 352 OnDetailsAvailable(); |
353 } | 353 } |
OLD | NEW |