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

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

Issue 2767823002: Media Remoting: Add interstitial elements to media element shadow dom. (Closed)
Patch Set: Remove cast text message element. Not assuming remoting interstitial is media control. Created 3 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 Apple Inc. All rights reserved. 2 * Copyright (C) 2007, 2008, 2009, 2010 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 25 matching lines...) Expand all
36 namespace gpu { 36 namespace gpu {
37 namespace gles2 { 37 namespace gles2 {
38 class GLES2Interface; 38 class GLES2Interface;
39 } 39 }
40 } 40 }
41 41
42 namespace blink { 42 namespace blink {
43 class ExceptionState; 43 class ExceptionState;
44 class ImageBitmapOptions; 44 class ImageBitmapOptions;
45 class MediaCustomControlsFullscreenDetector; 45 class MediaCustomControlsFullscreenDetector;
46 class MediaRemotingInterstitial;
46 47
47 class CORE_EXPORT HTMLVideoElement final : public HTMLMediaElement, 48 class CORE_EXPORT HTMLVideoElement final : public HTMLMediaElement,
48 public CanvasImageSource, 49 public CanvasImageSource,
49 public ImageBitmapSource { 50 public ImageBitmapSource {
50 DEFINE_WRAPPERTYPEINFO(); 51 DEFINE_WRAPPERTYPEINFO();
51 52
52 public: 53 public:
53 static HTMLVideoElement* create(Document&); 54 static HTMLVideoElement* create(Document&);
54 DECLARE_VIRTUAL_TRACE(); 55 DECLARE_VIRTUAL_TRACE();
55 56
(...skipping 67 matching lines...) Expand 10 before | Expand all | Expand 10 after
123 EventTarget&, 124 EventTarget&,
124 Optional<IntRect> cropRect, 125 Optional<IntRect> cropRect,
125 const ImageBitmapOptions&, 126 const ImageBitmapOptions&,
126 ExceptionState&) override; 127 ExceptionState&) override;
127 128
128 // WebMediaPlayerClient implementation. 129 // WebMediaPlayerClient implementation.
129 void onBecamePersistentVideo(bool) final; 130 void onBecamePersistentVideo(bool) final;
130 131
131 bool isPersistent() const; 132 bool isPersistent() const;
132 133
134 bool isMediaRemotingStarted() const override {
135 return m_mediaRemotingStarted;
136 }
137 void disableMediaRemoting();
138
133 private: 139 private:
134 friend class MediaCustomControlsFullscreenDetectorTest; 140 friend class MediaCustomControlsFullscreenDetectorTest;
135 friend class HTMLMediaElementEventListenersTest; 141 friend class HTMLMediaElementEventListenersTest;
136 friend class HTMLVideoElementPersistentTest; 142 friend class HTMLVideoElementPersistentTest;
137 143
138 HTMLVideoElement(Document&); 144 HTMLVideoElement(Document&);
139 145
140 // SuspendableObject functions. 146 // SuspendableObject functions.
141 void contextDestroyed(ExecutionContext*) final; 147 void contextDestroyed(ExecutionContext*) final;
142 148
143 bool layoutObjectIsNeeded(const ComputedStyle&) override; 149 bool layoutObjectIsNeeded(const ComputedStyle&) override;
144 LayoutObject* createLayoutObject(const ComputedStyle&) override; 150 LayoutObject* createLayoutObject(const ComputedStyle&) override;
145 void attachLayoutTree(const AttachContext& = AttachContext()) override; 151 void attachLayoutTree(const AttachContext& = AttachContext()) override;
146 void parseAttribute(const AttributeModificationParams&) override; 152 void parseAttribute(const AttributeModificationParams&) override;
147 bool isPresentationAttribute(const QualifiedName&) const override; 153 bool isPresentationAttribute(const QualifiedName&) const override;
148 void collectStyleForPresentationAttribute(const QualifiedName&, 154 void collectStyleForPresentationAttribute(const QualifiedName&,
149 const AtomicString&, 155 const AtomicString&,
150 MutableStylePropertySet*) override; 156 MutableStylePropertySet*) override;
151 bool isURLAttribute(const Attribute&) const override; 157 bool isURLAttribute(const Attribute&) const override;
152 const AtomicString imageSourceURL() const override; 158 const AtomicString imageSourceURL() const override;
153 159
154 void updateDisplayState() override; 160 void updateDisplayState() override;
155 void didMoveToNewDocument(Document& oldDocument) override; 161 void didMoveToNewDocument(Document& oldDocument) override;
156 void setDisplayMode(DisplayMode) override; 162 void setDisplayMode(DisplayMode) override;
157 163
164 void mediaRemotingStarted() final;
165 void mediaRemotingStopped() final;
166
167 bool isMediaRemotingDisabled() const override {
168 return m_mediaRemotingDisabled;
169 }
170
171 bool m_mediaRemotingDisabled : 1;
172 bool m_mediaRemotingStarted : 1;
mlamouri (slow - plz ping) 2017/04/07 13:18:33 Could a `m_mediaRemotingStatus` be used with Disab
xjz 2017/04/07 23:07:01 Good suggestion. Done. Thanks! :)
173
158 Member<HTMLImageLoader> m_imageLoader; 174 Member<HTMLImageLoader> m_imageLoader;
159 Member<MediaCustomControlsFullscreenDetector> 175 Member<MediaCustomControlsFullscreenDetector>
160 m_customControlsFullscreenDetector; 176 m_customControlsFullscreenDetector;
177 Member<MediaRemotingInterstitial> m_remotingInterstitial;
161 178
162 AtomicString m_defaultPosterURL; 179 AtomicString m_defaultPosterURL;
163 180
164 bool m_isPersistent = false; 181 bool m_isPersistent = false;
165 }; 182 };
166 183
167 } // namespace blink 184 } // namespace blink
168 185
169 #endif // HTMLVideoElement_h 186 #endif // HTMLVideoElement_h
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698