Chromium Code Reviews| OLD | NEW |
|---|---|
| 1 /* | 1 /* |
| 2 * Copyright (C) 2011, 2012 Apple Inc. All rights reserved. | 2 * Copyright (C) 2011, 2012 Apple Inc. All rights reserved. |
| 3 * Copyright (C) 2011, 2012 Google Inc. All rights reserved. | 3 * Copyright (C) 2011, 2012 Google Inc. All rights 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 69 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 80 void onDisableRemotePlaybackAttributeChanged() override { | 80 void onDisableRemotePlaybackAttributeChanged() override { |
| 81 refreshCastButtonVisibility(); | 81 refreshCastButtonVisibility(); |
| 82 } | 82 } |
| 83 // Notify us that the media element's network state has changed. | 83 // Notify us that the media element's network state has changed. |
| 84 void networkStateChanged() override; | 84 void networkStateChanged() override; |
| 85 LayoutObject* panelLayoutObject() override; | 85 LayoutObject* panelLayoutObject() override; |
| 86 LayoutObject* containerLayoutObject() override; | 86 LayoutObject* containerLayoutObject() override; |
| 87 // Return the internal elements, which is used by registering clicking | 87 // Return the internal elements, which is used by registering clicking |
| 88 // EventHandlers from MediaControlsWindowEventListener. | 88 // EventHandlers from MediaControlsWindowEventListener. |
| 89 MediaControlPanelElement* panelElement() override { return m_panel; } | 89 MediaControlPanelElement* panelElement() override { return m_panel; } |
| 90 MediaControlTimelineElement* timelineElement() override { return m_timeline; } | |
| 91 MediaControlCastButtonElement* castButtonElement() override { | |
| 92 return m_castButton; | |
| 93 } | |
| 94 MediaControlVolumeSliderElement* volumeSliderElement() override { | |
| 95 return m_volumeSlider; | |
| 96 } | |
| 97 void beginScrubbing() override; | 90 void beginScrubbing() override; |
| 98 void endScrubbing() override; | 91 void endScrubbing() override; |
| 99 void updateCurrentTimeDisplay() override; | 92 void updateCurrentTimeDisplay() override; |
| 100 void toggleTextTrackList() override; | 93 void toggleTextTrackList() override; |
| 101 void showTextTrackAtIndex(unsigned indexToEnable) override; | 94 void showTextTrackAtIndex(unsigned indexToEnable) override; |
| 102 void disableShowingTextTracks() override; | 95 void disableShowingTextTracks() override; |
| 103 // Called by the fullscreen buttons to toggle fulllscreen on/off. | 96 // Called by the fullscreen buttons to toggle fulllscreen on/off. |
| 104 void enterFullscreen() override; | 97 void enterFullscreen() override; |
| 105 void exitFullscreen() override; | 98 void exitFullscreen() override; |
| 106 void showOverlayCastButtonIfNeeded() override; | 99 void showOverlayCastButtonIfNeeded() override; |
| (...skipping 16 matching lines...) Expand all Loading... | |
| 123 void onTextTracksChanged() override; | 116 void onTextTracksChanged() override; |
| 124 void onError() override; | 117 void onError() override; |
| 125 void onLoadedMetadata() override; | 118 void onLoadedMetadata() override; |
| 126 void onEnteredFullscreen() override; | 119 void onEnteredFullscreen() override; |
| 127 void onExitedFullscreen() override; | 120 void onExitedFullscreen() override; |
| 128 Document& ownerDocument() { return document(); } | 121 Document& ownerDocument() { return document(); } |
| 129 | 122 |
| 130 DECLARE_VIRTUAL_TRACE(); | 123 DECLARE_VIRTUAL_TRACE(); |
| 131 | 124 |
| 132 private: | 125 private: |
| 126 // For composition. | |
|
whywhat
2017/04/07 20:13:59
nit: what does composition mean here? As in "compo
mlamouri (slow - plz ping)
2017/04/09 15:36:41
I gave more details.
| |
| 133 friend class MediaControlsMediaEventListener; | 127 friend class MediaControlsMediaEventListener; |
| 128 friend class MediaControlsWindowEventListener; | |
| 129 | |
| 130 // For tests. | |
| 134 friend class MediaControlsOrientationLockDelegateTest; | 131 friend class MediaControlsOrientationLockDelegateTest; |
| 135 friend class MediaControlsImplTest; | 132 friend class MediaControlsImplTest; |
| 136 | 133 |
| 137 // Need to be members of MediaControls for private member access. | 134 // Need to be members of MediaControls for private member access. |
| 138 class BatchedControlUpdate; | 135 class BatchedControlUpdate; |
| 139 class MediaControlsResizeObserverCallback; | 136 class MediaControlsResizeObserverCallback; |
| 140 | 137 |
| 141 static MediaControlsImpl* create(HTMLMediaElement&, ShadowRoot&); | 138 static MediaControlsImpl* create(HTMLMediaElement&, ShadowRoot&); |
| 142 | 139 |
| 143 void invalidate(Element*); | 140 void invalidate(Element*); |
| (...skipping 85 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 229 IntSize m_size; | 226 IntSize m_size; |
| 230 | 227 |
| 231 bool m_keepShowingUntilTimerFires : 1; | 228 bool m_keepShowingUntilTimerFires : 1; |
| 232 }; | 229 }; |
| 233 | 230 |
| 234 DEFINE_ELEMENT_TYPE_CASTS(MediaControlsImpl, isMediaControls()); | 231 DEFINE_ELEMENT_TYPE_CASTS(MediaControlsImpl, isMediaControls()); |
| 235 | 232 |
| 236 } // namespace blink | 233 } // namespace blink |
| 237 | 234 |
| 238 #endif | 235 #endif |
| OLD | NEW |