OLD | NEW |
---|---|
1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2011 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/browser_about_handler.h" | 5 #include "chrome/browser/browser_about_handler.h" |
6 | 6 |
7 #include <algorithm> | 7 #include <algorithm> |
8 #include <string> | 8 #include <string> |
9 #include <vector> | 9 #include <vector> |
10 | 10 |
(...skipping 764 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
775 it.Advance(); | 775 it.Advance(); |
776 } | 776 } |
777 | 777 |
778 return data; | 778 return data; |
779 } | 779 } |
780 #endif | 780 #endif |
781 | 781 |
782 std::string AboutHistograms(const std::string& query) { | 782 std::string AboutHistograms(const std::string& query) { |
783 TimeDelta wait_time = TimeDelta::FromMilliseconds(10000); | 783 TimeDelta wait_time = TimeDelta::FromMilliseconds(10000); |
784 | 784 |
785 base::StatisticsRecorder::CollectHistogramStats("Browser"); | |
jar (doing other things)
2011/10/04 22:32:38
We probably don't want to collect these here, as t
ramant (doing other things)
2011/10/19 01:09:52
Done.
| |
786 | |
785 HistogramSynchronizer* current_synchronizer = | 787 HistogramSynchronizer* current_synchronizer = |
786 HistogramSynchronizer::CurrentSynchronizer(); | 788 HistogramSynchronizer::CurrentSynchronizer(); |
787 DCHECK(current_synchronizer != NULL); | 789 DCHECK(current_synchronizer != NULL); |
788 current_synchronizer->FetchRendererHistogramsSynchronously(wait_time); | 790 current_synchronizer->FetchRendererHistogramsSynchronously(wait_time); |
789 | 791 |
790 std::string unescaped_query; | 792 std::string unescaped_query; |
791 std::string unescaped_title("About Histograms"); | 793 std::string unescaped_title("About Histograms"); |
792 if (!query.empty()) { | 794 if (!query.empty()) { |
793 unescaped_query = UnescapeURLComponent(query, UnescapeRule::NORMAL); | 795 unescaped_query = UnescapeURLComponent(query, UnescapeRule::NORMAL); |
794 unescaped_title += " - " + unescaped_query; | 796 unescaped_title += " - " + unescaped_query; |
(...skipping 730 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
1525 return false; | 1527 return false; |
1526 } | 1528 } |
1527 | 1529 |
1528 std::vector<std::string> ChromePaths() { | 1530 std::vector<std::string> ChromePaths() { |
1529 std::vector<std::string> paths; | 1531 std::vector<std::string> paths; |
1530 paths.reserve(arraysize(kChromePaths)); | 1532 paths.reserve(arraysize(kChromePaths)); |
1531 for (size_t i = 0; i < arraysize(kChromePaths); i++) | 1533 for (size_t i = 0; i < arraysize(kChromePaths); i++) |
1532 paths.push_back(kChromePaths[i]); | 1534 paths.push_back(kChromePaths[i]); |
1533 return paths; | 1535 return paths; |
1534 } | 1536 } |
OLD | NEW |