OLD | NEW |
1 // Copyright 2013 The Chromium Authors. All rights reserved. | 1 // Copyright 2013 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/extensions/api/feedback_private/feedback_service.h" | 5 #include "chrome/browser/extensions/api/feedback_private/feedback_service.h" |
6 | 6 |
7 #include "base/callback.h" | 7 #include "base/callback.h" |
8 #include "base/memory/weak_ptr.h" | 8 #include "base/memory/weak_ptr.h" |
9 #include "base/sys_info.h" | 9 #include "base/sys_info.h" |
10 #include "chrome/browser/profiles/profile.h" | 10 #include "chrome/browser/profiles/profile.h" |
(...skipping 16 matching lines...) Expand all Loading... |
27 class FeedbackServiceImpl | 27 class FeedbackServiceImpl |
28 : public FeedbackService, | 28 : public FeedbackService, |
29 public base::SupportsWeakPtr<FeedbackServiceImpl> { | 29 public base::SupportsWeakPtr<FeedbackServiceImpl> { |
30 public: | 30 public: |
31 FeedbackServiceImpl(); | 31 FeedbackServiceImpl(); |
32 virtual ~FeedbackServiceImpl(); | 32 virtual ~FeedbackServiceImpl(); |
33 | 33 |
34 virtual std::string GetUserEmail() OVERRIDE; | 34 virtual std::string GetUserEmail() OVERRIDE; |
35 virtual void GetSystemInformation( | 35 virtual void GetSystemInformation( |
36 const GetSystemInformationCallback& callback) OVERRIDE; | 36 const GetSystemInformationCallback& callback) OVERRIDE; |
| 37 virtual void GetHistograms(std::string* histograms) OVERRIDE; |
37 | 38 |
38 private: | 39 private: |
39 // Overridden from FeedbackService: | 40 // Overridden from FeedbackService: |
40 virtual base::WeakPtr<FeedbackService> GetWeakPtr() OVERRIDE; | 41 virtual base::WeakPtr<FeedbackService> GetWeakPtr() OVERRIDE; |
41 | 42 |
42 DISALLOW_COPY_AND_ASSIGN(FeedbackServiceImpl); | 43 DISALLOW_COPY_AND_ASSIGN(FeedbackServiceImpl); |
43 }; | 44 }; |
44 | 45 |
45 FeedbackService* FeedbackService::CreateInstance() { | 46 FeedbackService* FeedbackService::CreateInstance() { |
46 return new FeedbackServiceImpl; | 47 return new FeedbackServiceImpl; |
(...skipping 28 matching lines...) Expand all Loading... |
75 &sys_info_list, kChromeVersionTag, version_info.CreateVersionString()); | 76 &sys_info_list, kChromeVersionTag, version_info.CreateVersionString()); |
76 | 77 |
77 std::string os_version = base::SysInfo::OperatingSystemName() + ": " + | 78 std::string os_version = base::SysInfo::OperatingSystemName() + ": " + |
78 base::SysInfo::OperatingSystemVersion(); | 79 base::SysInfo::OperatingSystemVersion(); |
79 FeedbackService::PopulateSystemInfo( | 80 FeedbackService::PopulateSystemInfo( |
80 &sys_info_list, kOsVersionTag, os_version); | 81 &sys_info_list, kOsVersionTag, os_version); |
81 | 82 |
82 system_information_callback_.Run(sys_info_list); | 83 system_information_callback_.Run(sys_info_list); |
83 } | 84 } |
84 | 85 |
| 86 void FeedbackServiceImpl::GetHistograms(std::string* histograms) { |
| 87 } |
| 88 |
85 base::WeakPtr<FeedbackService> FeedbackServiceImpl::GetWeakPtr() { | 89 base::WeakPtr<FeedbackService> FeedbackServiceImpl::GetWeakPtr() { |
86 return AsWeakPtr(); | 90 return AsWeakPtr(); |
87 } | 91 } |
88 | 92 |
89 } // namespace extensions | 93 } // namespace extensions |
OLD | NEW |