| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright (C) 2007, 2008, 2009, 2010, 2011, 2012, 2013 Apple Inc. All rights | 2 * Copyright (C) 2007, 2008, 2009, 2010, 2011, 2012, 2013 Apple Inc. All rights |
| 3 * reserved. | 3 * reserved. |
| 4 * | 4 * |
| 5 * Redistribution and use in source and binary forms, with or without | 5 * Redistribution and use in source and binary forms, with or without |
| 6 * modification, are permitted provided that the following conditions | 6 * modification, are permitted provided that the following conditions |
| 7 * are met: | 7 * are met: |
| 8 * 1. Redistributions of source code must retain the above copyright | 8 * 1. Redistributions of source code must retain the above copyright |
| 9 * notice, this list of conditions and the following disclaimer. | 9 * notice, this list of conditions and the following disclaimer. |
| 10 * 2. Redistributions in binary form must reproduce the above copyright | 10 * 2. Redistributions in binary form must reproduce the above copyright |
| (...skipping 326 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 337 InsertionNotificationRequest insertedInto(ContainerNode*) override; | 337 InsertionNotificationRequest insertedInto(ContainerNode*) override; |
| 338 void removedFrom(ContainerNode*) override; | 338 void removedFrom(ContainerNode*) override; |
| 339 | 339 |
| 340 void didMoveToNewDocument(Document& oldDocument) override; | 340 void didMoveToNewDocument(Document& oldDocument) override; |
| 341 virtual KURL posterImageURL() const { return KURL(); } | 341 virtual KURL posterImageURL() const { return KURL(); } |
| 342 | 342 |
| 343 enum DisplayMode { Unknown, Poster, Video }; | 343 enum DisplayMode { Unknown, Poster, Video }; |
| 344 DisplayMode getDisplayMode() const { return m_displayMode; } | 344 DisplayMode getDisplayMode() const { return m_displayMode; } |
| 345 virtual void setDisplayMode(DisplayMode mode) { m_displayMode = mode; } | 345 virtual void setDisplayMode(DisplayMode mode) { m_displayMode = mode; } |
| 346 | 346 |
| 347 // Assert the correct order of the children in shadow dom when DCHECK is on. |
| 348 static void assertShadowRootChildren(ShadowRoot&); |
| 349 |
| 347 private: | 350 private: |
| 348 // Friend class for testing. | 351 // Friend class for testing. |
| 349 friend class MediaElementFillingViewportTest; | 352 friend class MediaElementFillingViewportTest; |
| 350 | 353 |
| 351 void resetMediaPlayerAndMediaSource(); | 354 void resetMediaPlayerAndMediaSource(); |
| 352 | 355 |
| 353 bool alwaysCreateUserAgentShadowRoot() const final { return true; } | 356 bool alwaysCreateUserAgentShadowRoot() const final { return true; } |
| 354 bool areAuthorShadowsAllowed() const final { return false; } | 357 bool areAuthorShadowsAllowed() const final { return false; } |
| 355 | 358 |
| 356 bool supportsFocus() const final; | 359 bool supportsFocus() const final; |
| (...skipping 406 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 763 | 766 |
| 764 inline bool isHTMLMediaElement(const HTMLElement& element) { | 767 inline bool isHTMLMediaElement(const HTMLElement& element) { |
| 765 return isHTMLAudioElement(element) || isHTMLVideoElement(element); | 768 return isHTMLAudioElement(element) || isHTMLVideoElement(element); |
| 766 } | 769 } |
| 767 | 770 |
| 768 DEFINE_HTMLELEMENT_TYPE_CASTS_WITH_FUNCTION(HTMLMediaElement); | 771 DEFINE_HTMLELEMENT_TYPE_CASTS_WITH_FUNCTION(HTMLMediaElement); |
| 769 | 772 |
| 770 } // namespace blink | 773 } // namespace blink |
| 771 | 774 |
| 772 #endif // HTMLMediaElement_h | 775 #endif // HTMLMediaElement_h |
| OLD | NEW |