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

Side by Side Diff: third_party/WebKit/Source/core/html/HTMLMediaElement.h

Issue 1827853002: [Android, RemotePlayback] Implement HTMLMediaElement.remote.connect(). (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@remote-playback-availability
Patch Set: Fixed timing for rejecting the promises Created 4 years, 8 months 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 unified diff | Download patch
OLDNEW
1 /* 1 /*
2 * Copyright (C) 2007, 2008, 2009, 2010, 2011, 2012, 2013 Apple Inc. All rights reserved. 2 * Copyright (C) 2007, 2008, 2009, 2010, 2011, 2012, 2013 Apple Inc. All rights reserved.
3 * 3 *
4 * Redistribution and use in source and binary forms, with or without 4 * Redistribution and use in source and binary forms, with or without
5 * modification, are permitted provided that the following conditions 5 * modification, are permitted provided that the following conditions
6 * are met: 6 * are met:
7 * 1. Redistributions of source code must retain the above copyright 7 * 1. Redistributions of source code must retain the above copyright
8 * notice, this list of conditions and the following disclaimer. 8 * notice, this list of conditions and the following disclaimer.
9 * 2. Redistributions in binary form must reproduce the above copyright 9 * 2. Redistributions in binary form must reproduce the above copyright
10 * notice, this list of conditions and the following disclaimer in the 10 * notice, this list of conditions and the following disclaimer in the
(...skipping 23 matching lines...) Expand all
34 #include "core/events/GenericEventQueue.h" 34 #include "core/events/GenericEventQueue.h"
35 #include "core/html/AutoplayExperimentHelper.h" 35 #include "core/html/AutoplayExperimentHelper.h"
36 #include "core/html/HTMLElement.h" 36 #include "core/html/HTMLElement.h"
37 #include "core/html/track/TextTrack.h" 37 #include "core/html/track/TextTrack.h"
38 #include "platform/Supplementable.h" 38 #include "platform/Supplementable.h"
39 #include "platform/audio/AudioSourceProvider.h" 39 #include "platform/audio/AudioSourceProvider.h"
40 #include "public/platform/WebAudioSourceProviderClient.h" 40 #include "public/platform/WebAudioSourceProviderClient.h"
41 #include "public/platform/WebMediaPlayerClient.h" 41 #include "public/platform/WebMediaPlayerClient.h"
42 #include "public/platform/WebMimeRegistry.h" 42 #include "public/platform/WebMimeRegistry.h"
43 43
44 #if !ENABLE(OILPAN)
45 #include "wtf/WeakPtr.h"
46 #endif
47
44 namespace blink { 48 namespace blink {
45 49
46 class AudioSourceProviderClient; 50 class AudioSourceProviderClient;
47 class AudioTrackList; 51 class AudioTrackList;
48 class ContentType; 52 class ContentType;
49 class CueTimeline; 53 class CueTimeline;
50 class Event; 54 class Event;
51 class ExceptionState; 55 class ExceptionState;
52 class HTMLSourceElement; 56 class HTMLSourceElement;
53 class HTMLTrackElement; 57 class HTMLTrackElement;
(...skipping 204 matching lines...) Expand 10 before | Expand all | Expand 10 after
258 virtual bool isHTMLAudioElement() const { return false; } 262 virtual bool isHTMLAudioElement() const { return false; }
259 virtual bool isHTMLVideoElement() const { return false; } 263 virtual bool isHTMLVideoElement() const { return false; }
260 264
261 // Temporary callback for crbug.com/487345,402044 265 // Temporary callback for crbug.com/487345,402044
262 void notifyPositionMayHaveChanged(const IntRect&); 266 void notifyPositionMayHaveChanged(const IntRect&);
263 void updatePositionNotificationRegistration(); 267 void updatePositionNotificationRegistration();
264 268
265 WebRemotePlaybackClient* remotePlaybackClient() { return m_remotePlaybackCli ent; } 269 WebRemotePlaybackClient* remotePlaybackClient() { return m_remotePlaybackCli ent; }
266 void setRemotePlaybackClient(WebRemotePlaybackClient*); 270 void setRemotePlaybackClient(WebRemotePlaybackClient*);
267 271
272 #if !ENABLE(OILPAN)
273 WeakPtr<HTMLMediaElement> createWeakPtr();
274 #endif
275
268 protected: 276 protected:
269 HTMLMediaElement(const QualifiedName&, Document&); 277 HTMLMediaElement(const QualifiedName&, Document&);
270 ~HTMLMediaElement() override; 278 ~HTMLMediaElement() override;
271 #if ENABLE(OILPAN) 279 #if ENABLE(OILPAN)
272 void dispose(); 280 void dispose();
273 #endif 281 #endif
274 282
275 void parseAttribute(const QualifiedName&, const AtomicString&, const AtomicS tring&) override; 283 void parseAttribute(const QualifiedName&, const AtomicString&, const AtomicS tring&) override;
276 void finishParsingChildren() final; 284 void finishParsingChildren() final;
277 bool isURLAttribute(const Attribute&) const override; 285 bool isURLAttribute(const Attribute&) const override;
(...skipping 356 matching lines...) Expand 10 before | Expand all | Expand 10 after
634 friend class Internals; 642 friend class Internals;
635 friend class TrackDisplayUpdateScope; 643 friend class TrackDisplayUpdateScope;
636 friend class AutoplayExperimentHelper; 644 friend class AutoplayExperimentHelper;
637 friend class MediaControlsTest; 645 friend class MediaControlsTest;
638 646
639 OwnPtrWillBeMember<AutoplayExperimentHelper::Client> m_autoplayHelperClient; 647 OwnPtrWillBeMember<AutoplayExperimentHelper::Client> m_autoplayHelperClient;
640 OwnPtrWillBeMember<AutoplayExperimentHelper> m_autoplayHelper; 648 OwnPtrWillBeMember<AutoplayExperimentHelper> m_autoplayHelper;
641 649
642 WebRemotePlaybackClient* m_remotePlaybackClient; 650 WebRemotePlaybackClient* m_remotePlaybackClient;
643 651
652 #if !ENABLE(OILPAN)
653 WeakPtrFactory<HTMLMediaElement> m_weakPtrFactory;
654 #endif
655
644 static URLRegistry* s_mediaStreamRegistry; 656 static URLRegistry* s_mediaStreamRegistry;
645 }; 657 };
646 658
647 inline bool isHTMLMediaElement(const HTMLElement& element) 659 inline bool isHTMLMediaElement(const HTMLElement& element)
648 { 660 {
649 return isHTMLAudioElement(element) || isHTMLVideoElement(element); 661 return isHTMLAudioElement(element) || isHTMLVideoElement(element);
650 } 662 }
651 663
652 DEFINE_HTMLELEMENT_TYPE_CASTS_WITH_FUNCTION(HTMLMediaElement); 664 DEFINE_HTMLELEMENT_TYPE_CASTS_WITH_FUNCTION(HTMLMediaElement);
653 665
654 } // namespace blink 666 } // namespace blink
655 667
656 #endif // HTMLMediaElement_h 668 #endif // HTMLMediaElement_h
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698