Chromium Code Reviews| Index: Source/core/platform/mediastream/MediaStreamTrackSourcesRequest.h |
| diff --git a/Source/modules/mediastream/SourceInfo.h b/Source/core/platform/mediastream/MediaStreamTrackSourcesRequest.h |
| similarity index 62% |
| copy from Source/modules/mediastream/SourceInfo.h |
| copy to Source/core/platform/mediastream/MediaStreamTrackSourcesRequest.h |
| index 94bce294a41f8335cdf683c392388a576fcb6af8..da70666f9444e9c5c1fa9971c49142d883e648d3 100644 |
| --- a/Source/modules/mediastream/SourceInfo.h |
| +++ b/Source/core/platform/mediastream/MediaStreamTrackSourcesRequest.h |
| @@ -23,34 +23,44 @@ |
| * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. |
| */ |
| -#ifndef SourceInfo_h |
| -#define SourceInfo_h |
| +#ifndef MediaStreamTrackSourcesRequest_h |
| +#define MediaStreamTrackSourcesRequest_h |
| -#include "bindings/v8/ScriptWrappable.h" |
| -#include "public/platform/WebSourceInfo.h" |
| +#include "public/platform/WebVector.h" |
| #include "wtf/PassRefPtr.h" |
| #include "wtf/RefCounted.h" |
| -#include "wtf/Vector.h" |
| +#include "wtf/RefPtr.h" |
| +#include "wtf/text/WTFString.h" |
| + |
| +namespace WebKit { |
| +class WebSourceInfo; |
| +} |
| namespace WebCore { |
| -class SourceInfo : public RefCounted<SourceInfo>, public ScriptWrappable { |
| +class MediaStreamTrackSourcesRequest : public RefCounted<MediaStreamTrackSourcesRequest> { |
| public: |
| - static PassRefPtr<SourceInfo> create(const WebKit::WebSourceInfo&); |
| + class ExtraData : public RefCounted<ExtraData> { |
| + public: |
| + virtual ~ExtraData() { } |
| + }; |
| - String id() const; |
| - String kind() const; |
| - String label() const; |
| - String facing() const; |
| + virtual ~MediaStreamTrackSourcesRequest() { } |
| -private: |
| - explicit SourceInfo(const WebKit::WebSourceInfo&); |
| + virtual String url() = 0; |
|
abarth-chromium
2013/06/11 23:50:44
Why do we need this class? We can probably skip i
Tommy Widenflycht
2013/06/12 12:29:34
So is the concept of core/platform deprecated then
|
| - WebKit::WebSourceInfo m_webSourceInfo; |
| -}; |
| + virtual void requestSucceeded(const WebKit::WebVector<WebKit::WebSourceInfo>&) = 0; |
| + |
| + PassRefPtr<ExtraData> extraData() const { return m_extraData; } |
| + void setExtraData(PassRefPtr<ExtraData> extraData) { m_extraData = extraData; } |
| -typedef Vector<RefPtr<SourceInfo> > SourceInfoVector; |
| +protected: |
| + MediaStreamTrackSourcesRequest() { } |
| + |
| +private: |
| + RefPtr<ExtraData> m_extraData; |
| +}; |
| } // namespace WebCore |
| -#endif // SourceInfo_h |
| +#endif // MediaStreamTrackSourcesRequest_h |