Title: [248747] trunk/Source/WebCore
- Revision
- 248747
- Author
- jer.no...@apple.com
- Date
- 2019-08-15 14:39:32 -0700 (Thu, 15 Aug 2019)
Log Message
[Cocoa] Adopt -preventDisplaySleepForVideoPlayback
https://bugs.webkit.org/show_bug.cgi?id=200774
Reviewed by Eric Carlson.
* platform/graphics/avfoundation/objc/MediaPlayerPrivateMediaSourceAVFObjC.mm:
(WebCore::MediaPlayerPrivateMediaSourceAVFObjC::ensureLayer):
Modified Paths
Diff
Modified: trunk/Source/WebCore/ChangeLog (248746 => 248747)
--- trunk/Source/WebCore/ChangeLog 2019-08-15 21:18:11 UTC (rev 248746)
+++ trunk/Source/WebCore/ChangeLog 2019-08-15 21:39:32 UTC (rev 248747)
@@ -1,3 +1,13 @@
+2019-08-15 Jer Noble <jer.no...@apple.com>
+
+ [Cocoa] Adopt -preventDisplaySleepForVideoPlayback
+ https://bugs.webkit.org/show_bug.cgi?id=200774
+
+ Reviewed by Eric Carlson.
+
+ * platform/graphics/avfoundation/objc/MediaPlayerPrivateMediaSourceAVFObjC.mm:
+ (WebCore::MediaPlayerPrivateMediaSourceAVFObjC::ensureLayer):
+
2019-08-15 Robin Morisset <rmoris...@apple.com>
[WHLSL] Don't accept operator&& or operator|| in the Lexer
Modified: trunk/Source/WebCore/platform/graphics/avfoundation/objc/MediaPlayerPrivateMediaSourceAVFObjC.mm (248746 => 248747)
--- trunk/Source/WebCore/platform/graphics/avfoundation/objc/MediaPlayerPrivateMediaSourceAVFObjC.mm 2019-08-15 21:18:11 UTC (rev 248746)
+++ trunk/Source/WebCore/platform/graphics/avfoundation/objc/MediaPlayerPrivateMediaSourceAVFObjC.mm 2019-08-15 21:39:32 UTC (rev 248747)
@@ -65,6 +65,10 @@
- (instancetype)initWithStorageDirectoryAtURL:(NSURL *)storageDirectory;
@end
+@interface AVSampleBufferDisplayLayer (WebCorePrivate)
+@property (assign, nonatomic) BOOL preventDisplaySleepForVideoPlayback;
+@end
+
namespace WebCore {
using namespace PAL;
@@ -758,6 +762,9 @@
return;
}
+ if ([m_sampleBufferDisplayLayer respondsToSelector:@selector(setPreventDisplaySleepForVideoPlayback:)])
+ m_sampleBufferDisplayLayer.get().preventDisplaySleepForVideoPlayback = NO;
+
[m_synchronizer addRenderer:m_sampleBufferDisplayLayer.get()];
if (m_mediaSourcePrivate)
m_mediaSourcePrivate->setVideoLayer(m_sampleBufferDisplayLayer.get());
_______________________________________________
webkit-changes mailing list
webkit-changes@lists.webkit.org
https://lists.webkit.org/mailman/listinfo/webkit-changes