forked from videojs/video.js
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge branch 'hotfix/options-width-fix'
Conflicts: src/core.js
- Loading branch information
Showing
5 changed files
with
173 additions
and
49 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,4 @@ | ||
--- | ||
major: 3 | ||
patch: 0 | ||
minor: 2 | ||
major: 3 | ||
patch: 1 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,121 @@ | ||
// HTML5 Shiv. Must be in <head> to support older browsers. | ||
document.createElement("video");document.createElement("audio"); | ||
|
||
var VideoJS = function(id, addOptions, ready){ | ||
var tag; // Element of ID | ||
|
||
// Allow for element or ID to be passed in | ||
// String ID | ||
if (typeof id == "string") { | ||
|
||
// Adjust for jQuery ID syntax | ||
if (id.indexOf("#") === 0) { | ||
id = id.slice(1); | ||
} | ||
|
||
// If a player instance has already been created for this ID return it. | ||
if (_V_.players[id]) { | ||
return _V_.players[id]; | ||
|
||
// Otherwise get element for ID | ||
} else { | ||
tag = _V_.el(id) | ||
} | ||
|
||
// ID is a media element | ||
} else { | ||
tag = id; | ||
} | ||
|
||
// Check for a useable element | ||
if (!tag || !tag.nodeName) { // re: nodeName, could be a box div also | ||
throw new TypeError("The element or ID supplied is not valid. (VideoJS)"); // Returns | ||
} | ||
|
||
// Element may have a player attr referring to an already created player instance. | ||
// If not, set up a new player and return the instance. | ||
return tag.player || new _V_.Player(tag, addOptions, ready); | ||
}, | ||
|
||
// Shortcut | ||
_V_ = VideoJS, | ||
|
||
// CDN Version. Used to target right flash swf. | ||
CDN_VERSION = "GENERATED_CDN_VSN"; | ||
|
||
VideoJS.players = {}; | ||
|
||
VideoJS.options = { | ||
|
||
// Default order of fallback technology | ||
techOrder: ["html5","flash"], | ||
// techOrder: ["flash","html5"], | ||
|
||
html5: {}, | ||
flash: { swf: "http://vjs.zencdn.net/c/video-js.swf" }, | ||
|
||
// Default of web browser is 300x150. Should rely on source width/height. | ||
<<<<<<< HEAD | ||
width: "auto", | ||
height: "auto", | ||
======= | ||
width: 300, | ||
height: 150, | ||
>>>>>>> hotfix/options-width-fix | ||
|
||
// defaultVolume: 0.85, | ||
defaultVolume: 0.00, // The freakin seaguls are driving me crazy! | ||
|
||
// Included control sets | ||
components: { | ||
"posterImage": {}, | ||
"textTrackDisplay": {}, | ||
"loadingSpinner": {}, | ||
"bigPlayButton": {}, | ||
"controlBar": {} | ||
} | ||
|
||
// components: [ | ||
// "poster", | ||
// "loadingSpinner", | ||
// "bigPlayButton", | ||
// { name: "controlBar", options: { | ||
// components: [ | ||
// "playToggle", | ||
// "fullscreenToggle", | ||
// "currentTimeDisplay", | ||
// "timeDivider", | ||
// "durationDisplay", | ||
// "remainingTimeDisplay", | ||
// { name: "progressControl", options: { | ||
// components: [ | ||
// { name: "seekBar", options: { | ||
// components: [ | ||
// "loadProgressBar", | ||
// "playProgressBar", | ||
// "seekHandle" | ||
// ]} | ||
// } | ||
// ]} | ||
// }, | ||
// { name: "volumeControl", options: { | ||
// components: [ | ||
// { name: "volumeBar", options: { | ||
// components: [ | ||
// "volumeLevel", | ||
// "volumeHandle" | ||
// ]} | ||
// } | ||
// ]} | ||
// }, | ||
// "muteToggle" | ||
// ] | ||
// }}, | ||
// "subtitlesDisplay"/*, "replay"*/ | ||
// ] | ||
}; | ||
|
||
// Set CDN Version of swf | ||
if (CDN_VERSION != "GENERATED_CDN_VSN") { | ||
_V_.options.flash.swf = "http://vjs.zencdn.net/"+CDN_VERSION+"/video-js.swf" | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters