Add a sample plugin to demonstrate the mute plugin API.
authoradachan@apple.com <adachan@apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Thu, 4 Dec 2014 06:42:38 +0000 (06:42 +0000)
committeradachan@apple.com <adachan@apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Thu, 4 Dec 2014 06:42:38 +0000 (06:42 +0000)
commit48fd8746a336724c2a567f16062543013f6dfa5d
tree73dc4e462c013891eca2fd6eea5e98d26108770b
parentf73507216853d4ab14f0038efccafdf740930c0f
Add a sample plugin to demonstrate the mute plugin API.
https://bugs.webkit.org/show_bug.cgi?id=139231

Reviewed by Anders Carlsson.

* NetscapeMuteAPIPlugin/AudioPlayer.h: Added.
* NetscapeMuteAPIPlugin/AudioPlayer.mm: Added.
(-[AudioPlayer initWithURL:]):
(-[AudioPlayer dealloc]):
(-[AudioPlayer isReadyToPlay]):
(-[AudioPlayer isPlaying]):
(-[AudioPlayer setPlaying:]):
(-[AudioPlayer isMuted]):
(-[AudioPlayer setMuted:]):
(-[AudioPlayer observeValueForKeyPath:ofObject:change:context:]):
* NetscapeMuteAPIPlugin/English.lproj/InfoPlist.strings: Added.
* NetscapeMuteAPIPlugin/Info.plist: Added.
* NetscapeMuteAPIPlugin/MenuHandler.h: Added.
* NetscapeMuteAPIPlugin/MenuHandler.m: Added.
(-[MenuHandler _play:]):
(-[MenuHandler _pause:]):
(-[MenuHandler validateUserInterfaceItem:]):
(-[MenuHandler initWithAudioPlayer:]):
(-[MenuHandler dealloc]):
(-[MenuHandler menu]):
* NetscapeMuteAPIPlugin/NetscapeMuteAPIPlugin.xcodeproj/project.pbxproj: Added.
* NetscapeMuteAPIPlugin/main.m: Added.
(-[PluginObject initWithNPP:audioURL:]):
(-[PluginObject dealloc]):
(-[PluginObject menuHandler]):
(-[PluginObject isPlayingAudio]):
(-[PluginObject isMuted]):
(-[PluginObject setMuted:]):
(-[PluginObject readyStateDidChangeForAudioPlayer:]):
(-[PluginObject mutedStateDidChangeForAudioPlayer:]):
(-[PluginObject playStateDidChangeForAudioPlayer:]):
(-[PluginObject _invalidateDisplayString]):
(NP_Initialize):
(NP_GetEntryPoints):
(NP_Shutdown):
(NPP_New):
(NPP_Destroy):
(NPP_SetWindow):
(NPP_NewStream):
(NPP_DestroyStream):
(NPP_WriteReady):
(NPP_Write):
(NPP_StreamAsFile):
(NPP_Print):
(handleDraw):
(invalidatePlugin):
(handleMouseEvent):
(NPP_HandleEvent):
(NPP_URLNotify):
(NPP_GetValue):
(NPP_SetValue):
* NetscapeMuteAPIPlugin/test.html: Added.

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@176785 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Examples/ChangeLog
Examples/NetscapeMuteAPIPlugin/AudioPlayer.h [new file with mode: 0644]
Examples/NetscapeMuteAPIPlugin/AudioPlayer.mm [new file with mode: 0644]
Examples/NetscapeMuteAPIPlugin/English.lproj/InfoPlist.strings [new file with mode: 0644]
Examples/NetscapeMuteAPIPlugin/Info.plist [new file with mode: 0644]
Examples/NetscapeMuteAPIPlugin/MenuHandler.h [new file with mode: 0644]
Examples/NetscapeMuteAPIPlugin/MenuHandler.m [new file with mode: 0644]
Examples/NetscapeMuteAPIPlugin/NetscapeMuteAPIPlugin.xcodeproj/project.pbxproj [new file with mode: 0644]
Examples/NetscapeMuteAPIPlugin/main.m [new file with mode: 0644]
Examples/NetscapeMuteAPIPlugin/test.html [new file with mode: 0644]