RESOLVED FIXED 137219
Figure out whether a plug-in is playing audio
https://bugs.webkit.org/show_bug.cgi?id=137219
Summary Figure out whether a plug-in is playing audio
Ada Chan
Reported 2014-09-29 11:20:05 PDT
This is similar to https://bugs.webkit.org/show_bug.cgi?id=137218, but for handling plug-ins. This is needed for https://bugs.webkit.org/show_bug.cgi?id=137048.
Attachments
Patch (17.99 KB, patch)
2014-11-05 15:13 PST, Ada Chan
no flags
Patch: fixed style check failure (17.99 KB, patch)
2014-11-05 15:19 PST, Ada Chan
andersca: review+
Ada Chan
Comment 1 2014-11-04 14:32:51 PST
We are proposing a new plugin API to accomplish this: When a plug-in starts or stops playing audio, the plug-in will call NPN_SetValue with the NPPVpluginIsPlayingAudio = 4000 NPPVariable. The value parameter should be TRUE if the audio started playing or FALSE if the audio stopped playing. The browser can query whether the plug-in is playing audio by calling NPP_GetValue with the NPPVpluginIsPlayingAudio NPPVariable.
Ada Chan
Comment 2 2014-11-05 15:13:47 PST
WebKit Commit Bot
Comment 3 2014-11-05 15:15:22 PST
Attachment 241059 [details] did not pass style-queue: ERROR: Source/WebCore/plugins/npapi.h:383: Weird number of spaces at line-start. Are you using a 4-space indent? [whitespace/indent] [3] Total errors found: 1 in 15 files If any of these errors are false positives, please file a bug against check-webkit-style.
Ada Chan
Comment 4 2014-11-05 15:19:14 PST
Created attachment 241061 [details] Patch: fixed style check failure
Anders Carlsson
Comment 5 2014-11-05 17:09:36 PST
Comment on attachment 241061 [details] Patch: fixed style check failure View in context: https://bugs.webkit.org/attachment.cgi?id=241061&action=review > Source/WebCore/plugins/npapi.h:383 > + , NPPVpluginIsPlayingAudio = 4000 Funny indentation here.
Ada Chan
Comment 6 2014-11-05 17:17:12 PST
(In reply to comment #5) > Comment on attachment 241061 [details] > Patch: fixed style check failure > > View in context: > https://bugs.webkit.org/attachment.cgi?id=241061&action=review > > > Source/WebCore/plugins/npapi.h:383 > > + , NPPVpluginIsPlayingAudio = 4000 > > Funny indentation here. I deliberately did that because the style checker was complaining that I had weird number of spaces at line start. I agree that consistency is more important. I'll fix the spacing to match the other lines. Thanks for the review!
Ada Chan
Comment 7 2014-11-05 23:51:12 PST
Note You need to log in before you can comment on or make changes to this bug.