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

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

Issue 1254613003: Let the WebMediaPlayer decide whether to use overlay video. (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Address Xianzhu's Comments Created 5 years, 4 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
« no previous file with comments | « no previous file | Source/core/html/HTMLMediaElement.cpp » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
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 196 matching lines...) Expand 10 before | Expand all | Expand 10 after
207 // causes an ambiguity error at compile time. This class's constructor 207 // causes an ambiguity error at compile time. This class's constructor
208 // ensures that both implementations return document, so return the result 208 // ensures that both implementations return document, so return the result
209 // of one of them here. 209 // of one of them here.
210 using HTMLElement::executionContext; 210 using HTMLElement::executionContext;
211 211
212 bool hasSingleSecurityOrigin() const { return webMediaPlayer() && webMediaPl ayer()->hasSingleSecurityOrigin(); } 212 bool hasSingleSecurityOrigin() const { return webMediaPlayer() && webMediaPl ayer()->hasSingleSecurityOrigin(); }
213 213
214 bool isFullscreen() const; 214 bool isFullscreen() const;
215 void enterFullscreen(); 215 void enterFullscreen();
216 void exitFullscreen(); 216 void exitFullscreen();
217 virtual bool usesOverlayFullscreenVideo() const { return false; }
217 218
218 bool hasClosedCaptions() const; 219 bool hasClosedCaptions() const;
219 bool closedCaptionsVisible() const; 220 bool closedCaptionsVisible() const;
220 void setClosedCaptionsVisible(bool); 221 void setClosedCaptionsVisible(bool);
221 222
222 static void setTextTrackKindUserPreferenceForAllMediaElements(Document*); 223 static void setTextTrackKindUserPreferenceForAllMediaElements(Document*);
223 void automaticTrackSelectionForUpdatedUserPreference(); 224 void automaticTrackSelectionForUpdatedUserPreference();
224 225
225 // Returns the MediaControls, or null if they have not been added yet. 226 // Returns the MediaControls, or null if they have not been added yet.
226 // Note that this can be non-null even if there is no controls attribute. 227 // Note that this can be non-null even if there is no controls attribute.
(...skipping 314 matching lines...) Expand 10 before | Expand all | Expand 10 after
541 bool m_delayingLoadForPreloadNone : 1; 542 bool m_delayingLoadForPreloadNone : 1;
542 543
543 bool m_tracksAreReady : 1; 544 bool m_tracksAreReady : 1;
544 bool m_haveVisibleTextTrack : 1; 545 bool m_haveVisibleTextTrack : 1;
545 bool m_processingPreferenceChange : 1; 546 bool m_processingPreferenceChange : 1;
546 bool m_remoteRoutesAvailable : 1; 547 bool m_remoteRoutesAvailable : 1;
547 bool m_playingRemotely : 1; 548 bool m_playingRemotely : 1;
548 bool m_isFinalizing : 1; 549 bool m_isFinalizing : 1;
549 bool m_initialPlayWithoutUserGestures : 1; 550 bool m_initialPlayWithoutUserGestures : 1;
550 bool m_autoplayMediaCounted : 1; 551 bool m_autoplayMediaCounted : 1;
552 // Whether this element is in overlay fullscreen mode.
553 bool m_inOverlayFullscreenVideo : 1;
551 554
552 PersistentWillBeMember<AudioTrackList> m_audioTracks; 555 PersistentWillBeMember<AudioTrackList> m_audioTracks;
553 PersistentWillBeMember<VideoTrackList> m_videoTracks; 556 PersistentWillBeMember<VideoTrackList> m_videoTracks;
554 PersistentWillBeMember<TextTrackList> m_textTracks; 557 PersistentWillBeMember<TextTrackList> m_textTracks;
555 PersistentHeapVectorWillBeHeapVector<Member<TextTrack>> m_textTracksWhenReso urceSelectionBegan; 558 PersistentHeapVectorWillBeHeapVector<Member<TextTrack>> m_textTracksWhenReso urceSelectionBegan;
556 559
557 OwnPtrWillBeMember<CueTimeline> m_cueTimeline; 560 OwnPtrWillBeMember<CueTimeline> m_cueTimeline;
558 561
559 #if ENABLE(WEB_AUDIO) 562 #if ENABLE(WEB_AUDIO)
560 // This is a weak reference, since m_audioSourceNode holds a reference to us . 563 // This is a weak reference, since m_audioSourceNode holds a reference to us .
(...skipping 63 matching lines...) Expand 10 before | Expand all | Expand 10 after
624 inline bool isHTMLMediaElement(const HTMLElement& element) 627 inline bool isHTMLMediaElement(const HTMLElement& element)
625 { 628 {
626 return isHTMLAudioElement(element) || isHTMLVideoElement(element); 629 return isHTMLAudioElement(element) || isHTMLVideoElement(element);
627 } 630 }
628 631
629 DEFINE_HTMLELEMENT_TYPE_CASTS_WITH_FUNCTION(HTMLMediaElement); 632 DEFINE_HTMLELEMENT_TYPE_CASTS_WITH_FUNCTION(HTMLMediaElement);
630 633
631 } // namespace blink 634 } // namespace blink
632 635
633 #endif // HTMLMediaElement_h 636 #endif // HTMLMediaElement_h
OLDNEW
« no previous file with comments | « no previous file | Source/core/html/HTMLMediaElement.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698