Index: chrome/browser/media/chrome_webrtc_internals.h |
diff --git a/content/browser/media/webrtc_internals.h b/chrome/browser/media/chrome_webrtc_internals.h |
similarity index 50% |
rename from content/browser/media/webrtc_internals.h |
rename to chrome/browser/media/chrome_webrtc_internals.h |
index 50db3dae6219aa564f8ac9687e43eb7295b5d45e..fbfa8a07e8fc9312a1b602de98a481615e45285d 100644 |
--- a/content/browser/media/webrtc_internals.h |
+++ b/chrome/browser/media/chrome_webrtc_internals.h |
@@ -2,51 +2,51 @@ |
// Use of this source code is governed by a BSD-style license that can be |
// found in the LICENSE file. |
-#ifndef CONTENT_BROWSER_MEDIA_WEBRTC_INTERNALS_H_ |
-#define CONTENT_BROWSER_MEDIA_WEBRTC_INTERNALS_H_ |
+#ifndef CHROME_BROWSER_MEDIA_CHROME_WEBRTC_INTERNALS_H_ |
+#define CHROME_BROWSER_MEDIA_CHROME_WEBRTC_INTERNALS_H_ |
#include "base/memory/singleton.h" |
#include "base/observer_list.h" |
#include "base/process.h" |
#include "base/values.h" |
-#include "content/common/content_export.h" |
- |
-struct PeerConnectionInfo; |
- |
-namespace content { |
+#include "content/public/browser/webrtc_internals.h" |
+namespace media { |
jam
2013/01/18 18:27:33
code in chrome doesn't need to be in a namespace.
jiayl
2013/01/18 19:20:00
Done.
|
class WebRTCInternalsUIObserver; |
// This is a singleton class running in the browser process. |
// It collects peer connection infomation from the renderers, |
// forwards the data to WebRTCInternalsUIObserver and |
// sends data collecting commands to the renderers. |
-class CONTENT_EXPORT WebRTCInternals { |
+class ChromeWebRTCInternals : public content::WebRTCInternals { |
public: |
- static WebRTCInternals* GetInstance(); |
+ static ChromeWebRTCInternals* GetInstance(); |
- // Methods called when peer connection status changes. |
- void AddPeerConnection(base::ProcessId pid, const PeerConnectionInfo& info); |
- void RemovePeerConnection(base::ProcessId pid, int lid); |
+ // WebRTCInternals overrides. |
+ virtual void AddPeerConnection(base::ProcessId pid, |
+ int lid, |
+ const std::string& url, |
+ const std::string& servers, |
+ const std::string& constraints) OVERRIDE; |
+ virtual void RemovePeerConnection(base::ProcessId pid, int lid) OVERRIDE; |
// Methods for adding or removing WebRTCInternalsUIObserver. |
void AddObserver(WebRTCInternalsUIObserver *observer); |
void RemoveObserver(WebRTCInternalsUIObserver *observer); |
private: |
- friend struct DefaultSingletonTraits<WebRTCInternals>; |
+ friend struct DefaultSingletonTraits<ChromeWebRTCInternals>; |
- WebRTCInternals(); |
- virtual ~WebRTCInternals(); |
+ ChromeWebRTCInternals(); |
+ virtual ~ChromeWebRTCInternals(); |
// Send updates to observers on UI thread. |
void SendUpdate(const std::string& command, base::Value* value); |
- // Only the IO thread should access these fields. |
+ // Only the UI thread should access these fields. |
ObserverList<WebRTCInternalsUIObserver> observers_; |
base::ListValue peer_connection_data_; |
}; |
-} // namespace content |
- |
-#endif // CONTENT_BROWSER_MEDIA_WEBRTC_INTERNALS_H_ |
+} // namespace media |
+#endif // CHROME_BROWSER_MEDIA_CHROME_WEBRTC_INTERNALS_H_ |