Changeset 197259 in webkit


Ignore:
Timestamp:
Feb 27, 2016 1:05:24 PM (8 years ago)
Author:
commit-queue@webkit.org
Message:

Unreviewed, rolling out r197204, r197207, r197211, r197217,
r197218, and r197219.
https://bugs.webkit.org/show_bug.cgi?id=154780

Caused crashes in WebVideoFullscreenManagerProxy (Requested by
ap on #webkit).

Reverted changesets:

"Add support for playbackControlsManager"
https://bugs.webkit.org/show_bug.cgi?id=154742
http://trac.webkit.org/changeset/197204

"Attempted build fix."
http://trac.webkit.org/changeset/197207

"Attempted build fix."
http://trac.webkit.org/changeset/197211

"Attempted 32-bit build fix."
http://trac.webkit.org/changeset/197217

"Another 32-bit build fix."
http://trac.webkit.org/changeset/197218

"32-bit!!!"
http://trac.webkit.org/changeset/197219

Location:
trunk/Source
Files:
24 edited

Legend:

Unmodified
Added
Removed
  • trunk/Source/WebCore/ChangeLog

    r197255 r197259  
     12016-02-27  Commit Queue  <commit-queue@webkit.org>
     2
     3        Unreviewed, rolling out r197204, r197207, r197211, r197217,
     4        r197218, and r197219.
     5        https://bugs.webkit.org/show_bug.cgi?id=154780
     6
     7        Caused crashes in WebVideoFullscreenManagerProxy (Requested by
     8        ap on #webkit).
     9
     10        Reverted changesets:
     11
     12        "Add support for playbackControlsManager"
     13        https://bugs.webkit.org/show_bug.cgi?id=154742
     14        http://trac.webkit.org/changeset/197204
     15
     16        "Attempted build fix."
     17        http://trac.webkit.org/changeset/197207
     18
     19        "Attempted build fix."
     20        http://trac.webkit.org/changeset/197211
     21
     22        "Attempted 32-bit build fix."
     23        http://trac.webkit.org/changeset/197217
     24
     25        "Another 32-bit build fix."
     26        http://trac.webkit.org/changeset/197218
     27
     28        "32-bit!!!"
     29        http://trac.webkit.org/changeset/197219
     30
    1312016-02-27  Chris Dumez  <cdumez@apple.com>
    232
  • trunk/Source/WebCore/WebCore.xcodeproj/project.pbxproj

    r197204 r197259  
    330330                07EE76EF1BEA619800F89133 /* MockRealtimeVideoSourceMac.h in Headers */ = {isa = PBXBuildFile; fileRef = 07EE76ED1BEA619800F89133 /* MockRealtimeVideoSourceMac.h */; };
    331331                07EE76F01BEA619800F89133 /* MockRealtimeVideoSourceMac.mm in Sources */ = {isa = PBXBuildFile; fileRef = 07EE76EE1BEA619800F89133 /* MockRealtimeVideoSourceMac.mm */; };
    332                 07F0B97A1AC5DB3300E535D9 /* AVKitSPI.h in Headers */ = {isa = PBXBuildFile; fileRef = 07F0B9791AC5DB3300E535D9 /* AVKitSPI.h */; settings = {ATTRIBUTES = (Private, ); }; };
     332                07F0B97A1AC5DB3300E535D9 /* AVKitSPI.h in Headers */ = {isa = PBXBuildFile; fileRef = 07F0B9791AC5DB3300E535D9 /* AVKitSPI.h */; };
    333333                07F0B97C1AC5DB4600E535D9 /* AVFoundationSPI.h in Headers */ = {isa = PBXBuildFile; fileRef = 07F0B97B1AC5DB4600E535D9 /* AVFoundationSPI.h */; settings = {ATTRIBUTES = (Private, ); }; };
    334334                07F876841AD580F900905849 /* MediaPlaybackTargetContext.h in Headers */ = {isa = PBXBuildFile; fileRef = 07F876831AD4A94500905849 /* MediaPlaybackTargetContext.h */; settings = {ATTRIBUTES = (Private, ); }; };
  • trunk/Source/WebCore/html/HTMLMediaElement.cpp

    r197204 r197259  
    29562956    }
    29572957
    2958     // FIXME: rdar://problem/23833752 We need to be more strategic about when we set up the video controls manager.
    2959     // It's really something that should be handled by the PlatformMediaSessionManager since we only want a controls
    2960     // manager for the currentSession.
    2961     if (document().page() && is<HTMLVideoElement>(*this)) {
    2962         HTMLVideoElement& asVideo = downcast<HTMLVideoElement>(*this);
    2963         document().page()->chrome().client().setUpVideoControlsManager(asVideo);
    2964     }
    2965 
    29662958    // 4.8.10.9. Playing the media resource
    29672959    if (!m_player || m_networkState == NETWORK_EMPTY)
  • trunk/Source/WebCore/page/ChromeClient.h

    r197204 r197259  
    342342#if ENABLE(VIDEO)
    343343    virtual void enterVideoFullscreenForVideoElement(HTMLVideoElement&, HTMLMediaElementEnums::VideoFullscreenMode) { }
    344     virtual void setUpVideoControlsManager(HTMLVideoElement&) { }
    345344#endif
    346345    virtual void exitVideoFullscreenForVideoElement(WebCore::HTMLVideoElement&) { }
  • trunk/Source/WebCore/platform/cf/CoreMediaSoftLink.cpp

    r197204 r197259  
    4444SOFT_LINK_FUNCTION_FOR_SOURCE(WebCore, CoreMedia, CMTimeMakeWithSeconds, CMTime, (Float64 seconds, int32_t preferredTimeScale), (seconds, preferredTimeScale))
    4545SOFT_LINK_FUNCTION_FOR_SOURCE(WebCore, CoreMedia, CMTimeRangeGetEnd, CMTime, (CMTimeRange range), (range))
    46 SOFT_LINK_FUNCTION_FOR_SOURCE(WebCore, CoreMedia, CMTimeRangeMake, CMTimeRange, (CMTime start, CMTime duration), (start, duration))
    4746
    4847SOFT_LINK_CONSTANT_FOR_SOURCE(WebCore, CoreMedia, kCMFormatDescriptionExtension_SampleDescriptionExtensionAtoms, CFStringRef)
     
    113112SOFT_LINK_FUNCTION_FOR_SOURCE(WebCore, CoreMedia, CMTimeMinimum, CMTime, (CMTime time1, CMTime time2), (time1, time2))
    114113SOFT_LINK_FUNCTION_FOR_SOURCE(WebCore, CoreMedia, CMTimeRangeContainsTime, Boolean, (CMTimeRange range, CMTime time), (range, time))
     114SOFT_LINK_FUNCTION_FOR_SOURCE(WebCore, CoreMedia, CMTimeRangeMake, CMTimeRange, (CMTime start, CMTime duration), (start, duration))
    115115SOFT_LINK_FUNCTION_FOR_SOURCE(WebCore, CoreMedia, CMTimeSubtract, CMTime, (CMTime minuend, CMTime subtrahend), (minuend, subtrahend))
    116116
  • trunk/Source/WebCore/platform/cf/CoreMediaSoftLink.h

    r197204 r197259  
    5656SOFT_LINK_FUNCTION_FOR_HEADER(WebCore, CoreMedia, CMTimeRangeGetEnd, CMTime, (CMTimeRange range), (range))
    5757#define CMTimeRangeGetEnd softLink_CoreMedia_CMTimeRangeGetEnd
    58 SOFT_LINK_FUNCTION_FOR_HEADER(WebCore, CoreMedia, CMTimeRangeMake, CMTimeRange, (CMTime start, CMTime duration), (start, duration))
    59 #define CMTimeRangeMake softLink_CoreMedia_CMTimeRangeMake
    6058
    6159SOFT_LINK_CONSTANT_FOR_HEADER(WebCore, CoreMedia, kCMFormatDescriptionExtension_SampleDescriptionExtensionAtoms, CFStringRef)
     
    190188SOFT_LINK_FUNCTION_FOR_HEADER(WebCore, CoreMedia, CMTimeRangeContainsTime, Boolean, (CMTimeRange range, CMTime time), (range, time))
    191189#define CMTimeRangeContainsTime softLink_CoreMedia_CMTimeRangeContainsTime
     190SOFT_LINK_FUNCTION_FOR_HEADER(WebCore, CoreMedia, CMTimeRangeMake, CMTimeRange, (CMTime start, CMTime duration), (start, duration))
     191#define CMTimeRangeMake softLink_CoreMedia_CMTimeRangeMake
    192192SOFT_LINK_FUNCTION_FOR_HEADER(WebCore, CoreMedia, CMTimeSubtract, CMTime, (CMTime minuend, CMTime subtrahend), (minuend, subtrahend))
    193193#define CMTimeSubtract softLink_CoreMedia_CMTimeSubtract
  • trunk/Source/WebCore/platform/mac/WebVideoFullscreenInterfaceMac.h

    r197204 r197259  
    3636
    3737OBJC_CLASS NSWindow;
    38 OBJC_CLASS WebPlaybackControlsManager;
    3938
    4039#if USE(APPLE_INTERNAL_SDK)
     
    6362
    6463    WEBCORE_EXPORT void resetMediaState() override { }
    65     WEBCORE_EXPORT void setDuration(double) override;
    66     WEBCORE_EXPORT void setCurrentTime(double /*currentTime*/, double /*anchorTime*/) override;
     64    WEBCORE_EXPORT void setDuration(double) override { }
     65    WEBCORE_EXPORT void setCurrentTime(double /*currentTime*/, double /*anchorTime*/) override { }
    6766    WEBCORE_EXPORT void setBufferedTime(double) override { }
    68     WEBCORE_EXPORT void setRate(bool /*isPlaying*/, float /*playbackRate*/) override;
     67    WEBCORE_EXPORT void setRate(bool /*isPlaying*/, float /*playbackRate*/) override { }
    6968    WEBCORE_EXPORT void setVideoDimensions(bool /*hasVideo*/, float /*width*/, float /*height*/) override { }
    70     WEBCORE_EXPORT void setSeekableRanges(const TimeRanges&) override;
     69    WEBCORE_EXPORT void setSeekableRanges(const TimeRanges&) override { }
    7170    WEBCORE_EXPORT void setCanPlayFastReverse(bool) override { }
    7271    WEBCORE_EXPORT void setAudioMediaSelectionOptions(const Vector<WTF::String>& /*options*/, uint64_t /*selectedIndex*/) override { }
     
    8281    WEBCORE_EXPORT void requestHideAndExitFullscreen() { }
    8382    WEBCORE_EXPORT void preparedToReturnToInline(bool visible, const IntRect& inlineRect, NSWindow *parentWindow);
    84     WEBCORE_EXPORT void ensureControlsManager();
    8583
    8684    HTMLMediaElementEnums::VideoFullscreenMode mode() const { return m_mode; }
     
    9391    void applicationDidBecomeActive() { }
    9492
    95     WEBCORE_EXPORT WebPlaybackControlsManager *playBackControlsManager();
    96 
    9793private:
    9894    WebVideoFullscreenModel* m_videoFullscreenModel { nullptr };
     
    10399    RetainPtr<WebVideoFullscreenInterfaceMacObjC> m_webVideoFullscreenInterfaceObjC;
    104100#endif
    105     RetainPtr<WebPlaybackControlsManager> m_playbackControlsManager;
    106101};
    107102
  • trunk/Source/WebCore/platform/mac/WebVideoFullscreenInterfaceMac.mm

    r197219 r197259  
    2929#if PLATFORM(MAC) && ENABLE(VIDEO_PRESENTATION_MODE)
    3030
    31 #import "AVKitSPI.h"
    32 #import "CoreMediaSoftLink.h"
    3331#import "IntRect.h"
    34 #import "MediaTimeAVFoundation.h"
    35 #import "TimeRanges.h"
    3632#import "WebVideoFullscreenChangeObserver.h"
    3733#import "WebVideoFullscreenModel.h"
    38 #import <AVFoundation/AVTime.h>
    39 
    40 #import "SoftLinking.h"
    41 
    42 SOFT_LINK_FRAMEWORK(AVKit)
    43 SOFT_LINK_CLASS(AVKit, AVValueTiming)
    4434
    4535#if USE(APPLE_INTERNAL_SDK)
    4636#include <WebKitAdditions/WebVideoFullscreenInterfaceMacAdditions.mm>
    4737#endif
    48 
    49 using namespace WebCore;
    50 
    51 @interface WebPlaybackControlsManager : NSObject {
    52     NSTimeInterval _contentDuration;
    53     AVValueTiming *_timing;
    54     NSTimeInterval _seekToTime;
    55     NSArray *_seekableTimeRanges;
    56     BOOL _hasEnabledAudio;
    57     BOOL _hasEnabledVideo;
    58     float _rate;
    59 
    60 @private
    61     WebCore::WebVideoFullscreenInterfaceMac* _webVideoFullscreenInterfaceMac;
    62 }
    63 
    64 @property (readwrite) NSTimeInterval contentDuration;
    65 @property (nonatomic, retain, readwrite) AVValueTiming *timing;
    66 @property NSTimeInterval seekToTime;
    67 @property (nonatomic, retain, readwrite) NSArray *seekableTimeRanges;
    68 @property (readwrite) BOOL hasEnabledAudio;
    69 @property (readwrite) BOOL hasEnabledVideo;
    70 
    71 @property (nonatomic) float rate;
    72 
    73 - (instancetype)initWithWebVideoFullscreenInterfaceMac:(WebCore::WebVideoFullscreenInterfaceMac*)webVideoFullscreenInterfaceMac;
    74 
    75 @end
    76 
    77 #if USE(APPLE_INTERNAL_SDK)
    78 #import <WebKitAdditions/WebPlaybackControlsControllerAdditions.mm>
    79 #endif
    80 
    81 @implementation WebPlaybackControlsManager
    82 
    83 @synthesize contentDuration = _contentDuration;
    84 @synthesize timing = _timing;
    85 @synthesize seekToTime = _seekToTime;
    86 @synthesize seekableTimeRanges = _seekableTimeRanges;
    87 @synthesize hasEnabledAudio = _hasEnabledAudio;
    88 @synthesize hasEnabledVideo = _hasEnabledVideo;
    89 @synthesize rate = _rate;
    90 
    91 - (instancetype)initWithWebVideoFullscreenInterfaceMac:(WebCore::WebVideoFullscreenInterfaceMac*)webVideoFullscreenInterfaceMac
    92 {
    93     if (!(self = [super init]))
    94         return nil;
    95 
    96     _webVideoFullscreenInterfaceMac = webVideoFullscreenInterfaceMac;
    97 
    98     return self;
    99 }
    100 
    101 - (BOOL)isSeeking
    102 {
    103     return NO;
    104 }
    105 
    106 - (void)seekToTime:(NSTimeInterval)time toleranceBefore:(NSTimeInterval)toleranceBefore toleranceAfter:(NSTimeInterval)toleranceAfter
    107 {
    108     UNUSED_PARAM(toleranceBefore);
    109     UNUSED_PARAM(toleranceAfter);
    110     _webVideoFullscreenInterfaceMac->webVideoFullscreenModel()->seekToTime(time);
    111 }
    112 
    113 - (NSArray *)audioMediaSelectionOptions
    114 {
    115     return @[];
    116 }
    117 
    118 - (AVMediaSelectionOption *)currentAudioMediaSelectionOption
    119 {
    120     return nil;
    121 }
    122 
    123 - (void)setCurrentAudioMediaSelectionOption:(AVMediaSelectionOption *)audioMediaSelectionOption
    124 {
    125     UNUSED_PARAM(audioMediaSelectionOption);
    126 }
    127 
    128 - (NSArray *)legibleMediaSelectionOptions
    129 {
    130     return @[];
    131 }
    132 
    133 - (AVMediaSelectionOption *)currentLegibleMediaSelectionOption
    134 {
    135     return nil;
    136 }
    137 
    138 - (void)setCurrentLegibleMediaSelectionOption:(AVMediaSelectionOption *)legibleMediaSelectionOption
    139 {
    140     UNUSED_PARAM(legibleMediaSelectionOption);
    141 }
    142 
    143 - (void)cancelThumbnailAndAudioAmplitudeSampleGeneration
    144 {
    145 }
    146 
    147 #if USE(APPLE_INTERNAL_SDK)
    148 #import <WebKitAdditions/WebPlaybackControlsControllerThumbnailAdditions.mm>
    149 #endif
    150 
    151 @end
    15238
    15339namespace WebCore {
     
    18975}
    19076
    191 void WebVideoFullscreenInterfaceMac::setDuration(double duration)
    192 {
    193     WebPlaybackControlsManager* controlsManager = playBackControlsManager();
    194 
    195     controlsManager.contentDuration = duration;
    196 
    197     // FIXME: We take this as an indication that playback is ready, but that is not necessarily true.
    198     controlsManager.hasEnabledAudio = YES;
    199     controlsManager.hasEnabledVideo = YES;
    200 }
    201 
    202 void WebVideoFullscreenInterfaceMac::setCurrentTime(double currentTime, double anchorTime)
    203 {
    204     WebPlaybackControlsManager* controlsManager = playBackControlsManager();
    205 
    206     NSTimeInterval anchorTimeStamp = ![controlsManager rate] ? NAN : anchorTime;
    207     AVValueTiming *timing = [getAVValueTimingClass() valueTimingWithAnchorValue:currentTime
    208         anchorTimeStamp:anchorTimeStamp rate:0];
    209    
    210     [controlsManager setTiming:timing];
    211 }
    212 
    213 void WebVideoFullscreenInterfaceMac::setRate(bool isPlaying, float playbackRate)
    214 {
    215     WebPlaybackControlsManager* controlsManager = playBackControlsManager();
    216 
    217     [controlsManager setRate:isPlaying ? playbackRate : 0.];
    218 }
    219 
    220 void WebVideoFullscreenInterfaceMac::setSeekableRanges(const TimeRanges& timeRanges)
    221 {
    222     WebPlaybackControlsManager* controlsManager = playBackControlsManager();
    223 
    224     RetainPtr<NSMutableArray> seekableRanges = adoptNS([[NSMutableArray alloc] init]);
    225 
    226     for (unsigned i = 0; i < timeRanges.length(); i++) {
    227         const PlatformTimeRanges& ranges = timeRanges.ranges();
    228         CMTimeRange range = CMTimeRangeMake(toCMTime(ranges.start(i)), toCMTime(ranges.end(i)));
    229         [seekableRanges addObject:[NSValue valueWithCMTimeRange:range]];
    230     }
    231    
    232     [controlsManager setSeekableTimeRanges:seekableRanges.get()];
    233 }
    234 
    235 void WebVideoFullscreenInterfaceMac::ensureControlsManager()
    236 {
    237     playBackControlsManager();
    238 }
    239 
    240 WebPlaybackControlsManager *WebVideoFullscreenInterfaceMac::playBackControlsManager()
    241 {
    242 #if __MAC_OS_X_VERSION_MIN_REQUIRED >= 101200
    243     if (!m_playbackControlsManager)
    244         m_playbackControlsManager = adoptNS([[WebPlaybackControlsManager alloc] initWithWebVideoFullscreenInterfaceMac:this]);
    245     return m_playbackControlsManager.get();
    246 #else
    247     return nil;
    248 #endif
    249 }
    250 
    25177#if !USE(APPLE_INTERNAL_SDK)
    25278void WebVideoFullscreenInterfaceMac::setupFullscreen(NSView&, const IntRect&, NSWindow *, HTMLMediaElementEnums::VideoFullscreenMode, bool)
  • trunk/Source/WebCore/platform/spi/cocoa/AVKitSPI.h

    r197218 r197259  
    102102
    103103#endif // USE(APPLE_INTERNAL_SDK)
     104
     105@interface AVValueTiming : NSObject <NSCoding, NSCopying, NSMutableCopying>
     106@end
     107
     108@interface AVValueTiming ()
     109+ (AVValueTiming *)valueTimingWithAnchorValue:(double)anchorValue anchorTimeStamp:(NSTimeInterval)timeStamp rate:(double)rate;
     110@property (NS_NONATOMIC_IOSONLY, readonly) double currentValue;
     111@end
     112
    104113#endif // PLATFORM(IOS)
    105114
     
    132141
    133142#endif
    134 
    135 @interface AVValueTiming : NSObject <NSCoding, NSCopying, NSMutableCopying>
    136 @end
    137 
    138 @interface AVValueTiming ()
    139 + (AVValueTiming *)valueTimingWithAnchorValue:(double)anchorValue anchorTimeStamp:(NSTimeInterval)timeStamp rate:(double)rate;
    140 @property (NS_NONATOMIC_IOSONLY, readonly) double currentValue;
    141 @end
  • trunk/Source/WebKit2/ChangeLog

    r197246 r197259  
     12016-02-27  Commit Queue  <commit-queue@webkit.org>
     2
     3        Unreviewed, rolling out r197204, r197207, r197211, r197217,
     4        r197218, and r197219.
     5        https://bugs.webkit.org/show_bug.cgi?id=154780
     6
     7        Caused crashes in WebVideoFullscreenManagerProxy (Requested by
     8        ap on #webkit).
     9
     10        Reverted changesets:
     11
     12        "Add support for playbackControlsManager"
     13        https://bugs.webkit.org/show_bug.cgi?id=154742
     14        http://trac.webkit.org/changeset/197204
     15
     16        "Attempted build fix."
     17        http://trac.webkit.org/changeset/197207
     18
     19        "Attempted build fix."
     20        http://trac.webkit.org/changeset/197211
     21
     22        "Attempted 32-bit build fix."
     23        http://trac.webkit.org/changeset/197217
     24
     25        "Another 32-bit build fix."
     26        http://trac.webkit.org/changeset/197218
     27
     28        "32-bit!!!"
     29        http://trac.webkit.org/changeset/197219
     30
    1312016-02-26  Carlos Garcia Campos  <cgarcia@igalia.com>
    232
  • trunk/Source/WebKit2/UIProcess/Cocoa/WebVideoFullscreenManagerProxy.h

    r197204 r197259  
    120120    bool isVisible() const;
    121121
    122     PlatformWebVideoFullscreenInterface& controlsManagerInterface();
    123 
    124122private:
    125123    friend class WebVideoFullscreenModelContext;
     
    136134    // Messages from WebVideoFullscreenManager
    137135    void setupFullscreenWithID(uint64_t contextId, uint32_t videoLayerID, const WebCore::IntRect& initialRect, float hostingScaleFactor, WebCore::HTMLMediaElementEnums::VideoFullscreenMode, bool allowsPictureInPicture);
    138     void setUpVideoControlsManagerWithID(uint64_t contextId);
    139136    void resetMediaState(uint64_t contextId);
    140137    void setCurrentTime(uint64_t contextId, double currentTime, double hostTime);
     
    179176    WebPageProxy* m_page;
    180177    HashMap<uint64_t, ModelInterfaceTuple> m_contextMap;
    181     uint64_t m_controlsManagerContextId { 0 };
    182178
    183179};
  • trunk/Source/WebKit2/UIProcess/Cocoa/WebVideoFullscreenManagerProxy.messages.in

    r197204 r197259  
    4040    CleanupFullscreen(uint64_t contextId)
    4141    PreparedToReturnToInline(uint64_t contextId, bool visible, WebCore::IntRect inlineRect)
    42     SetUpVideoControlsManagerWithID(uint64_t contextId)
    4342}
    4443#endif
  • trunk/Source/WebKit2/UIProcess/Cocoa/WebVideoFullscreenManagerProxy.mm

    r197207 r197259  
    375375}
    376376
    377 void WebVideoFullscreenManagerProxy::setUpVideoControlsManagerWithID(uint64_t contextId)
    378 {
    379 #if PLATFORM(MAC)
    380     RefPtr<WebVideoFullscreenModelContext> model;
    381     RefPtr<PlatformWebVideoFullscreenInterface> interface;
    382 
    383     std::tie(model, interface) = ensureModelAndInterface(contextId);
    384     m_controlsManagerContextId = contextId;
    385     interface->ensureControlsManager();
    386 #else
    387     UNUSED_PARAM(contextId);
    388 #endif
    389 }
    390 
    391377void WebVideoFullscreenManagerProxy::resetMediaState(uint64_t contextId)
    392378{
     
    630616}
    631617
    632 PlatformWebVideoFullscreenInterface& WebVideoFullscreenManagerProxy::controlsManagerInterface()
    633 {
    634     return ensureInterface(m_controlsManagerContextId);
    635 }
    636 
    637618void WebVideoFullscreenManagerProxy::fullscreenMayReturnToInline(uint64_t contextId)
    638619{
  • trunk/Source/WebKit2/UIProcess/Cocoa/WebViewImpl.h

    r197204 r197259  
    325325    void didChangeContentSize(CGSize);
    326326    void didHandleAcceptedCandidate();
    327     void isPlayingMediaDidChange();
    328327
    329328    void setIgnoresNonWheelEvents(bool);
  • trunk/Source/WebKit2/UIProcess/Cocoa/WebViewImpl.mm

    r197204 r197259  
    23722372}
    23732373
    2374 void WebViewImpl::isPlayingMediaDidChange()
    2375 {
    2376 #if __MAC_OS_X_VERSION_MIN_REQUIRED >= 101200
    2377     updateWebViewImplAdditions();
    2378 #endif
    2379 }
    2380 
    23812374void WebViewImpl::setIgnoresNonWheelEvents(bool ignoresNonWheelEvents)
    23822375{
  • trunk/Source/WebKit2/UIProcess/PageClient.h

    r197204 r197259  
    351351
    352352    virtual void didHandleAcceptedCandidate() = 0;
    353 
    354     virtual void isPlayingMediaDidChange() = 0;
    355353#endif
    356354
  • trunk/Source/WebKit2/UIProcess/WebPageProxy.cpp

    r197213 r197259  
    59965996        return;
    59975997
    5998 #if PLATFORM(MAC)
    5999     m_pageClient.isPlayingMediaDidChange();
    6000 #endif
    60015998    m_uiClient->isPlayingAudioDidChange(*this);
    6002 }
    6003 
    6004 bool WebPageProxy::isPlayingVideoWithAudio() const
    6005 {
    6006     return m_mediaState & MediaProducer::IsPlayingAudio && m_mediaState & MediaProducer::IsPlayingVideo;
    60075999}
    60086000
  • trunk/Source/WebKit2/UIProcess/WebPageProxy.h

    r197213 r197259  
    10151015    void isPlayingMediaDidChange(WebCore::MediaProducer::MediaStateFlags, uint64_t);
    10161016
    1017     bool isPlayingVideoWithAudio() const;
    1018 
    10191017#if ENABLE(MEDIA_SESSION)
    10201018    void hasMediaSessionWithActiveMediaElementsDidChange(bool);
  • trunk/Source/WebKit2/UIProcess/mac/PageClientImpl.h

    r197204 r197259  
    215215    virtual void didHandleAcceptedCandidate() override;
    216216
    217     void isPlayingMediaDidChange() override;
    218 
    219217    virtual void showPlatformContextMenu(NSMenu *, WebCore::IntPoint) override;
    220218
  • trunk/Source/WebKit2/UIProcess/mac/PageClientImpl.mm

    r197204 r197259  
    795795}
    796796
    797 void PageClientImpl::isPlayingMediaDidChange()
    798 {
    799     m_impl->isPlayingMediaDidChange();
    800 }
    801 
    802797void PageClientImpl::showPlatformContextMenu(NSMenu *menu, IntPoint location)
    803798{
  • trunk/Source/WebKit2/WebProcess/WebCoreSupport/WebChromeClient.cpp

    r197204 r197259  
    856856}
    857857
    858 void WebChromeClient::setUpVideoControlsManager(WebCore::HTMLVideoElement& videoElement)
    859 {
    860     m_page->videoFullscreenManager()->setUpVideoControlsManager(videoElement);
    861 }
    862 
    863858void WebChromeClient::enterVideoFullscreenForVideoElement(WebCore::HTMLVideoElement& videoElement, WebCore::HTMLMediaElementEnums::VideoFullscreenMode mode)
    864859{
  • trunk/Source/WebKit2/WebProcess/WebCoreSupport/WebChromeClient.h

    r197204 r197259  
    245245#if PLATFORM(IOS) || (PLATFORM(MAC) && ENABLE(VIDEO_PRESENTATION_MODE))
    246246    virtual bool supportsVideoFullscreen(WebCore::HTMLMediaElementEnums::VideoFullscreenMode) override;
    247     virtual void setUpVideoControlsManager(WebCore::HTMLVideoElement&) override;
    248247    virtual void enterVideoFullscreenForVideoElement(WebCore::HTMLVideoElement&, WebCore::HTMLMediaElementEnums::VideoFullscreenMode) override;
    249248    virtual void exitVideoFullscreenForVideoElement(WebCore::HTMLVideoElement&) override;
  • trunk/Source/WebKit2/WebProcess/cocoa/WebVideoFullscreenManager.h

    r197204 r197259  
    117117    void enterVideoFullscreenForVideoElement(WebCore::HTMLVideoElement&, WebCore::HTMLMediaElementEnums::VideoFullscreenMode);
    118118    void exitVideoFullscreenForVideoElement(WebCore::HTMLVideoElement&);
    119     void setUpVideoControlsManager(WebCore::HTMLVideoElement&);
    120119   
    121120protected:
  • trunk/Source/WebKit2/WebProcess/cocoa/WebVideoFullscreenManager.mm

    r197204 r197259  
    280280}
    281281
    282 void WebVideoFullscreenManager::setUpVideoControlsManager(WebCore::HTMLVideoElement& videoElement)
    283 {
    284     auto addResult = m_videoElements.ensure(&videoElement, [&] { return nextContextId(); });
    285     auto contextId = addResult.iterator->value;
    286 
    287     RefPtr<WebVideoFullscreenModelVideoElement> model;
    288     RefPtr<WebVideoFullscreenInterfaceContext> interface;
    289     std::tie(model, interface) = ensureModelAndInterface(contextId);
    290     model->setVideoElement(&videoElement);
    291    
    292     m_page->send(Messages::WebVideoFullscreenManagerProxy::SetUpVideoControlsManagerWithID(contextId), m_page->pageID());
    293 }
    294 
    295282#pragma mark Interface to WebVideoFullscreenInterfaceContext:
    296283
Note: See TracChangeset for help on using the changeset viewer.