Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(3129)

Unified Diff: chrome/browser/extensions/api/webrtc_logging_private/webrtc_logging_private_api.h

Issue 1530863002: Allow audio debug recordings through a private API extension. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Callback updates tommi's comments Created 5 years ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: chrome/browser/extensions/api/webrtc_logging_private/webrtc_logging_private_api.h
diff --git a/chrome/browser/extensions/api/webrtc_logging_private/webrtc_logging_private_api.h b/chrome/browser/extensions/api/webrtc_logging_private/webrtc_logging_private_api.h
index 202c7276aecd1aacd791ccc72178e64248d8ecfc..41085adcad8bb168e7dfa4f4d5d6992de9c21de9 100644
--- a/chrome/browser/extensions/api/webrtc_logging_private/webrtc_logging_private_api.h
+++ b/chrome/browser/extensions/api/webrtc_logging_private/webrtc_logging_private_api.h
@@ -5,6 +5,8 @@
#ifndef CHROME_BROWSER_EXTENSIONS_API_WEBRTC_LOGGING_PRIVATE_WEBRTC_LOGGING_PRIVATE_API_H_
#define CHROME_BROWSER_EXTENSIONS_API_WEBRTC_LOGGING_PRIVATE_WEBRTC_LOGGING_PRIVATE_API_H_
+#include <string>
Henrik Grunell 2015/12/18 12:34:21 Needed?
Guido Urdaneta 2015/12/18 18:38:58 According to lint, we should have it.
+
#include "chrome/browser/extensions/chrome_extension_function.h"
#if defined(ENABLE_WEBRTC)
#include "chrome/browser/media/webrtc_logging_handler_host.h"
@@ -69,6 +71,20 @@ class WebrtcLoggingPrivateFunctionWithUploadCallback
#endif
};
+class WebrtcLoggingPrivateFunctionWithAecDumpCallback
+ : public WebrtcLoggingPrivateFunction {
+ protected:
+ ~WebrtcLoggingPrivateFunctionWithAecDumpCallback() override {}
+
+#if defined(ENABLE_WEBRTC)
+ // Must be called on UI thread.
+ void FireErrorCallback(const std::string& error_message);
+ void FireSuccessCallback(bool is_manual_stop,
Henrik Grunell 2015/12/18 12:34:21 Nit: arguments in same order as in the idl.
Guido Urdaneta 2015/12/18 18:38:58 Done.
+ const std::string& prefix_path,
+ bool did_stop);
+#endif
+};
+
class WebrtcLoggingPrivateSetMetaDataFunction
: public WebrtcLoggingPrivateFunctionWithGenericCallback {
public:
@@ -209,6 +225,34 @@ class WebrtcLoggingPrivateStopRtpDumpFunction
bool RunAsync() override;
};
+class WebrtcLoggingPrivateStartAecDumpFunction
+ : public WebrtcLoggingPrivateFunctionWithAecDumpCallback {
+ public:
+ DECLARE_EXTENSION_FUNCTION("webrtcLoggingPrivate.startAecDump",
+ WEBRTCLOGGINGPRIVATE_STARTAECDUMP)
+ WebrtcLoggingPrivateStartAecDumpFunction() {}
+
+ private:
+ ~WebrtcLoggingPrivateStartAecDumpFunction() override {}
+
+ // ExtensionFunction overrides.
+ bool RunAsync() override;
+};
+
+class WebrtcLoggingPrivateStopAecDumpFunction
+ : public WebrtcLoggingPrivateFunctionWithAecDumpCallback {
+ public:
+ DECLARE_EXTENSION_FUNCTION("webrtcLoggingPrivate.stopAecDump",
+ WEBRTCLOGGINGPRIVATE_STOPAECDUMP)
+ WebrtcLoggingPrivateStopAecDumpFunction() {}
+
+ private:
+ ~WebrtcLoggingPrivateStopAecDumpFunction() override {}
+
+ // ExtensionFunction overrides.
+ bool RunAsync() override;
+};
+
} // namespace extensions
#endif // CHROME_BROWSER_EXTENSIONS_API_WEBRTC_LOGGING_PRIVATE_WEBRTC_LOGGING_PRIVATE_API_H_

Powered by Google App Engine
This is Rietveld 408576698