mirror of
https://github.com/zhigang1992/DefinitelyTyped.git
synced 2026-05-18 04:24:30 +08:00
- Fixed MediaPlayer constructor
- Fixed project description - Added some tests to MediaPlayer
This commit is contained in:
24
playerframework/playerFramework-tests.ts
Normal file
24
playerframework/playerFramework-tests.ts
Normal file
@@ -0,0 +1,24 @@
|
||||
///<reference path="playerframework.d.ts" />
|
||||
|
||||
var el = document.createElement("div");
|
||||
var player = new PlayerFramework.MediaPlayer(el);
|
||||
player.decreasePlaybackRate();
|
||||
player.increasePlaybackRate();
|
||||
player.load();
|
||||
player.pause();
|
||||
player.play();
|
||||
player.playResume();
|
||||
player.replay();
|
||||
player.retry();
|
||||
player.stop();
|
||||
|
||||
player.volume = 50;
|
||||
|
||||
var duration = player.duration;
|
||||
var volume = player.volume;
|
||||
var audioAllowed = player.isAudioAllowed
|
||||
var audioEnabled = player.isAudioEnabled;
|
||||
var audioVisible = player.isAudioVisible;
|
||||
var captionsAllowed = player.isCaptionsAllowed
|
||||
var captionsEnabled = player.isCaptionsEnabled;
|
||||
var captionsVisible = player.isCaptionsVisible;
|
||||
3
playerframework/playerFramework.d.ts
vendored
3
playerframework/playerFramework.d.ts
vendored
@@ -1,5 +1,5 @@
|
||||
// Type definitions for Player Framework (MMPPF)
|
||||
// Project: https://github.com/ricardosabino/DefinitelyTyped
|
||||
// Project: https://playerframework.codeplex.com/
|
||||
// Definitions by: Ricardo Sabino <https://github.com/ricardosabino>
|
||||
// Definitions: https://github.com/borisyankov/DefinitelyTyped
|
||||
|
||||
@@ -1078,6 +1078,7 @@ declare module PlayerFramework {
|
||||
*
|
||||
**/
|
||||
class MediaPlayer {
|
||||
constructor(element: HTMLElement, options?: any);
|
||||
/**
|
||||
* Gets or sets the current advertising state of the player.
|
||||
**/
|
||||
|
||||
Reference in New Issue
Block a user