MediaStream API: Rename the [add|remove]Track callbacks to [add|remove]RemoteTrack...
authortommyw@google.com <tommyw@google.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Tue, 15 Jan 2013 20:47:18 +0000 (20:47 +0000)
committertommyw@google.com <tommyw@google.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Tue, 15 Jan 2013 20:47:18 +0000 (20:47 +0000)
https://bugs.webkit.org/show_bug.cgi?id=106791

Reviewed by Adam Barth.

No tests needed.

* Modules/mediastream/MediaStream.cpp:
(WebCore::MediaStream::addRemoteTrack):
(WebCore::MediaStream::removeRemoteTrack):
* Modules/mediastream/MediaStream.h:
* platform/mediastream/MediaStreamCenter.cpp:
(WebCore::MediaStreamCenter::addMediaStreamTrack):
(WebCore::MediaStreamCenter::removeMediaStreamTrack):
* platform/mediastream/MediaStreamDescriptor.h:
(MediaStreamDescriptorClient):

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@139775 268f45cc-cd09-0410-ab3c-d52691b4dbfc

Source/WebCore/ChangeLog
Source/WebCore/Modules/mediastream/MediaStream.cpp
Source/WebCore/Modules/mediastream/MediaStream.h
Source/WebCore/platform/mediastream/MediaStreamCenter.cpp
Source/WebCore/platform/mediastream/MediaStreamDescriptor.h

index 629642d..d52bab8 100644 (file)
@@ -1,3 +1,22 @@
+2013-01-15  Tommy Widenflycht  <tommyw@google.com>
+
+        MediaStream API: Rename the [add|remove]Track callbacks to [add|remove]RemoteTrack for clarity
+        https://bugs.webkit.org/show_bug.cgi?id=106791
+
+        Reviewed by Adam Barth.
+
+        No tests needed.
+
+        * Modules/mediastream/MediaStream.cpp:
+        (WebCore::MediaStream::addRemoteTrack):
+        (WebCore::MediaStream::removeRemoteTrack):
+        * Modules/mediastream/MediaStream.h:
+        * platform/mediastream/MediaStreamCenter.cpp:
+        (WebCore::MediaStreamCenter::addMediaStreamTrack):
+        (WebCore::MediaStreamCenter::removeMediaStreamTrack):
+        * platform/mediastream/MediaStreamDescriptor.h:
+        (MediaStreamDescriptorClient):
+
 2013-01-15  Mark Pilgrim  <pilgrim@chromium.org>
 
         [Chromium] Move SocketStreamHandle and SocketStreamHandleInternal to WebCore/platform
index 7aff2bd..ca67669 100644 (file)
@@ -255,7 +255,7 @@ EventTargetData* MediaStream::ensureEventTargetData()
     return &m_eventTargetData;
 }
 
-void MediaStream::addTrack(MediaStreamComponent* component)
+void MediaStream::addRemoteTrack(MediaStreamComponent* component)
 {
     if (ended())
         return;
@@ -273,7 +273,7 @@ void MediaStream::addTrack(MediaStreamComponent* component)
     scheduleDispatchEvent(MediaStreamTrackEvent::create(eventNames().addtrackEvent, false, false, track));
 }
 
-void MediaStream::removeTrack(MediaStreamComponent* component)
+void MediaStream::removeRemoteTrack(MediaStreamComponent* component)
 {
     if (ended())
         return;
index f49b7f7..9e74fc0 100644 (file)
@@ -95,8 +95,8 @@ private:
     virtual void derefEventTarget() OVERRIDE { deref(); }
 
     // MediaStreamDescriptorClient
-    virtual void addTrack(MediaStreamComponent*) OVERRIDE;
-    virtual void removeTrack(MediaStreamComponent*) OVERRIDE;
+    virtual void addRemoteTrack(MediaStreamComponent*) OVERRIDE;
+    virtual void removeRemoteTrack(MediaStreamComponent*) OVERRIDE;
 
     void scheduleDispatchEvent(PassRefPtr<Event>);
     void scheduledEventTimerFired(Timer<MediaStream>*);
index dea2c47..c57fefa 100644 (file)
@@ -60,14 +60,14 @@ void MediaStreamCenter::addMediaStreamTrack(MediaStreamDescriptor* streamDescrip
 {
     MediaStreamDescriptorClient* client = streamDescriptor->client();
     if (client)
-        client->addTrack(component);
+        client->addRemoteTrack(component);
 }
 
 void MediaStreamCenter::removeMediaStreamTrack(MediaStreamDescriptor* streamDescriptor, MediaStreamComponent* component)
 {
     MediaStreamDescriptorClient* client = streamDescriptor->client();
     if (client)
-        client->removeTrack(component);
+        client->removeRemoteTrack(component);
 }
 
 } // namespace WebCore
index 143ff3f..e558b13 100644 (file)
@@ -45,8 +45,8 @@ public:
     virtual ~MediaStreamDescriptorClient() { }
 
     virtual void streamEnded() = 0;
-    virtual void addTrack(MediaStreamComponent*) = 0;
-    virtual void removeTrack(MediaStreamComponent*) = 0;
+    virtual void addRemoteTrack(MediaStreamComponent*) = 0;
+    virtual void removeRemoteTrack(MediaStreamComponent*) = 0;
 };
 
 class MediaStreamDescriptor : public RefCounted<MediaStreamDescriptor> {