Skip to content

Commit

Permalink
Release v3.3.1 stable
Browse files Browse the repository at this point in the history
  • Loading branch information
pupunzi committed Jan 12, 2020
1 parent eb303bd commit 5d03402
Show file tree
Hide file tree
Showing 7 changed files with 43 additions and 19 deletions.
4 changes: 2 additions & 2 deletions bower.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "jquery.mb.ytplayer",
"version": "3.2.11",
"version": "3.3.1",
"homepage": "http://pupunzi.open-lab.com/mb-jquery-components/jquery-mb-ytplayer",
"authors": [
"pupunzi <matbicoc@gmail.com>"
Expand All @@ -22,5 +22,5 @@
"test",
"tests"
],
"buildnum": "7449"
"buildnum": "7468"
}
8 changes: 4 additions & 4 deletions dist/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -3,8 +3,8 @@
file: index.tmpl
last modified: 10/25/18 8:00 PM
Version: 3.2.11
Build: 7449
Version: 3.3.0
Build: 7468
Open Lab s.r.l., Florence - Italy
email: matteo@open-lab.com
Expand All @@ -27,9 +27,9 @@
<meta charset="UTF-8">
<title>youtube Chromeless Player - mb.YTPlayer</title>
<link href='//fonts.googleapis.com/css?family=Lekton|Lobster' rel='stylesheet' type='text/css'>
<link href="css/jquery.mb.YTPlayer.min.css?_bn=7449" media="all" rel="stylesheet" type="text/css">
<link href="css/jquery.mb.YTPlayer.min.css?_bn=7468" media="all" rel="stylesheet" type="text/css">
<script src="https://ajax.googleapis.com/ajax/libs/jquery/3.2.1/jquery.min.js"></script>
<script src="jquery.mb.YTPlayer.js?_bn=7449"></script>
<script src="jquery.mb.YTPlayer.js?_bn=7468"></script>
<script src="../examples/assets/apikey.js"></script>
<style>
*:focus {
Expand Down
22 changes: 16 additions & 6 deletions dist/jquery.mb.YTPlayer.js
Original file line number Diff line number Diff line change
Expand Up @@ -3,8 +3,8 @@
file: jquery.mb.YTPlayer.src.js
last modified: 11/2/18 7:23 PM
Version: 3.2.11
Build: 7449
Version: 3.3.0
Build: 7468
Open Lab s.r.l., Florence - Italy
email: matteo@open-lab.com
Expand Down Expand Up @@ -61,8 +61,8 @@ function iOSversion() {

jQuery.mbYTPlayer = {
name : 'jquery.mb.YTPlayer',
version: '3.2.11',
build : '7449',
version: '3.3.0',
build : '7468',
author : 'Matteo Bicocchi (pupunzi)',
apiKey : '',

Expand Down Expand Up @@ -812,6 +812,8 @@ function iOSversion() {
if (typeof YTPlayer.opt.onError == 'function')
YTPlayer.opt.onError($YTPlayer, err)

console.debug("error:", err)

switch (err.data) {
case 2:
console.error('video ID:: ' + YTPlayer.videoID + ': The request contains an invalid parameter value. For example, this error occurs if you specify a video ID that does not have 11 characters, or if the video ID contains invalid characters, such as exclamation points or asterisks.')
Expand All @@ -824,7 +826,7 @@ function iOSversion() {
break
case 101:
case 150:
console.error('video ID:: ' + YTPlayer.videoID + ': The owner of the requested video does not allow it to be played in embedded players.')
console.error('video ID:: ' + YTPlayer.videoID + ': The video doesn\'t exist or The owner does not allow it to be played in embedded players.')
break
}

Expand Down Expand Up @@ -908,6 +910,9 @@ function iOSversion() {
YTPChanged.time = YTPlayer.currentTime
YTPChanged.videoId = YTPlayer.videoID
YTPChanged.opt = YTPlayer.opt

//console.debug("videoData:",YTPlayer.videoData)

jQuery(YTPlayer).trigger(YTPChanged)

let YTPData = jQuery.Event('YTPData')
Expand Down Expand Up @@ -1210,9 +1215,14 @@ function iOSversion() {
// endSeconds: YTPlayer.opt.stopAt,
suggestedQuality: YTPlayer.opt.quality
})

$YTPlayer.YTPPause()
$YTPlayer.optimizeDisplay()

if (YTPlayer.checkForStartAt) {
clearInterval(YTPlayer.checkForStartAt)
clearInterval(YTPlayer.getState)
}
$YTPlayer.YTPCheckForState()
})

Expand Down Expand Up @@ -1960,7 +1970,7 @@ function iOSversion() {

} else if (typeof YTPlayer.opt.mask == 'object') {

console.debug(YTPlayer.opt.mask)
//console.debug(YTPlayer.opt.mask)

for (let time in YTPlayer.opt.mask) {

Expand Down
6 changes: 3 additions & 3 deletions dist/jquery.mb.YTPlayer.min.js

Large diffs are not rendered by default.

4 changes: 4 additions & 0 deletions examples/demo.html
Original file line number Diff line number Diff line change
Expand Up @@ -319,6 +319,10 @@

// EVENT: YTPData
myPlayer.on("YTPData", function (e) {

if(!e.prop.title)
return;

$(".dida").html(e.prop.title + "<br>@" + e.prop.channelTitle);
$("#videoData").show();

Expand Down
4 changes: 2 additions & 2 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@
"player",
"custom"
],
"version": "3.2.11",
"version": "3.3.1",
"author": "Pupunzi <matbicoc@gmail.com> (Matteo Bicocchi)",
"maintainers": [
"Pupunzi <matbicoc@gmail.com> (Matteo Bicocchi)"
Expand Down Expand Up @@ -55,5 +55,5 @@
"directories": {
"example": "examples"
},
"buildnum": "7449"
"buildnum": "7468"
}
14 changes: 12 additions & 2 deletions src/jquery.mb.YTPlayer.src.js
Original file line number Diff line number Diff line change
Expand Up @@ -815,6 +815,8 @@ function iOSversion() {
if (typeof YTPlayer.opt.onError == 'function')
YTPlayer.opt.onError($YTPlayer, err)

console.debug("error:", err)

switch (err.data) {
case 2:
console.error('video ID:: ' + YTPlayer.videoID + ': The request contains an invalid parameter value. For example, this error occurs if you specify a video ID that does not have 11 characters, or if the video ID contains invalid characters, such as exclamation points or asterisks.')
Expand All @@ -827,7 +829,7 @@ function iOSversion() {
break
case 101:
case 150:
console.error('video ID:: ' + YTPlayer.videoID + ': The owner of the requested video does not allow it to be played in embedded players.')
console.error('video ID:: ' + YTPlayer.videoID + ': The video doesn\'t exist or The owner does not allow it to be played in embedded players.')
break
}

Expand Down Expand Up @@ -911,6 +913,9 @@ function iOSversion() {
YTPChanged.time = YTPlayer.currentTime
YTPChanged.videoId = YTPlayer.videoID
YTPChanged.opt = YTPlayer.opt

//console.debug("videoData:",YTPlayer.videoData)

jQuery(YTPlayer).trigger(YTPChanged)

let YTPData = jQuery.Event('YTPData')
Expand Down Expand Up @@ -1213,9 +1218,14 @@ function iOSversion() {
// endSeconds: YTPlayer.opt.stopAt,
suggestedQuality: YTPlayer.opt.quality
})

$YTPlayer.YTPPause()
$YTPlayer.optimizeDisplay()

if (YTPlayer.checkForStartAt) {
clearInterval(YTPlayer.checkForStartAt)
clearInterval(YTPlayer.getState)
}
$YTPlayer.YTPCheckForState()
})

Expand Down Expand Up @@ -1963,7 +1973,7 @@ function iOSversion() {

} else if (typeof YTPlayer.opt.mask == 'object') {

console.debug(YTPlayer.opt.mask)
//console.debug(YTPlayer.opt.mask)

for (let time in YTPlayer.opt.mask) {

Expand Down

0 comments on commit 5d03402

Please sign in to comment.