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 #ifndef CHROME_BROWSER_EXTENSIONS_API_FEEDBACK_PRIVATE_FEEDBACK_PRIVATE_API_H_ | 5 #ifndef CHROME_BROWSER_EXTENSIONS_API_FEEDBACK_PRIVATE_FEEDBACK_PRIVATE_API_H_ |
6 #define CHROME_BROWSER_EXTENSIONS_API_FEEDBACK_PRIVATE_FEEDBACK_PRIVATE_API_H_ | 6 #define CHROME_BROWSER_EXTENSIONS_API_FEEDBACK_PRIVATE_FEEDBACK_PRIVATE_API_H_ |
7 | 7 |
8 #include "chrome/browser/extensions/chrome_extension_function.h" | 8 #include "chrome/browser/extensions/chrome_extension_function.h" |
9 #include "chrome/common/extensions/api/feedback_private.h" | 9 #include "chrome/common/extensions/api/feedback_private.h" |
10 #include "extensions/browser/browser_context_keyed_api_factory.h" | 10 #include "extensions/browser/browser_context_keyed_api_factory.h" |
(...skipping 67 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
78 }; | 78 }; |
79 | 79 |
80 class FeedbackPrivateGetSystemInformationFunction | 80 class FeedbackPrivateGetSystemInformationFunction |
81 : public ChromeAsyncExtensionFunction { | 81 : public ChromeAsyncExtensionFunction { |
82 public: | 82 public: |
83 DECLARE_EXTENSION_FUNCTION("feedbackPrivate.getSystemInformation", | 83 DECLARE_EXTENSION_FUNCTION("feedbackPrivate.getSystemInformation", |
84 FEEDBACKPRIVATE_GETSYSTEMINFORMATION); | 84 FEEDBACKPRIVATE_GETSYSTEMINFORMATION); |
85 | 85 |
86 protected: | 86 protected: |
87 virtual ~FeedbackPrivateGetSystemInformationFunction() {} | 87 virtual ~FeedbackPrivateGetSystemInformationFunction() {} |
88 virtual bool RunImpl() OVERRIDE; | 88 virtual bool RunAsync() OVERRIDE; |
89 | 89 |
90 private: | 90 private: |
91 void OnCompleted( | 91 void OnCompleted( |
92 const std::vector<linked_ptr<SystemInformation> >& sys_info); | 92 const std::vector<linked_ptr<SystemInformation> >& sys_info); |
93 }; | 93 }; |
94 | 94 |
95 class FeedbackPrivateSendFeedbackFunction | 95 class FeedbackPrivateSendFeedbackFunction |
96 : public ChromeAsyncExtensionFunction { | 96 : public ChromeAsyncExtensionFunction { |
97 public: | 97 public: |
98 DECLARE_EXTENSION_FUNCTION("feedbackPrivate.sendFeedback", | 98 DECLARE_EXTENSION_FUNCTION("feedbackPrivate.sendFeedback", |
99 FEEDBACKPRIVATE_SENDFEEDBACK); | 99 FEEDBACKPRIVATE_SENDFEEDBACK); |
100 | 100 |
101 protected: | 101 protected: |
102 virtual ~FeedbackPrivateSendFeedbackFunction() {} | 102 virtual ~FeedbackPrivateSendFeedbackFunction() {} |
103 virtual bool RunImpl() OVERRIDE; | 103 virtual bool RunAsync() OVERRIDE; |
104 | 104 |
105 private: | 105 private: |
106 void OnCompleted(bool success); | 106 void OnCompleted(bool success); |
107 }; | 107 }; |
108 | 108 |
109 } // namespace extensions | 109 } // namespace extensions |
110 | 110 |
111 #endif // CHROME_BROWSER_EXTENSIONS_API_FEEDBACK_PRIVATE_FEEDBACK_PRIVATE_API_H
_ | 111 #endif // CHROME_BROWSER_EXTENSIONS_API_FEEDBACK_PRIVATE_FEEDBACK_PRIVATE_API_H
_ |
OLD | NEW |