Project "Tuxbox-GIT: apps": The branch, master has been updated via 0b32b035b810f6d91b169ba77c1b6d1a34447ed6 (commit) from e65d843fbb0aaab70a8c51db840bb0198c8b22f5 (commit)
Those revisions listed above that are new to this repository have not appeared on any other notification email; so we list those revisions in full, below. - Log ----------------------------------------------------------------- commit 0b32b035b810f6d91b169ba77c1b6d1a34447ed6 Author: GetAway <get-a...@t-online.de> Date: Thu Apr 30 21:32:40 2015 +0200 yWeb: fix detection of VLC >= 2.1.0 tested from vlc-0.8.6 to vlc-3.0.0-git Signed-off-by: GetAway <get-a...@t-online.de> diff --git a/tuxbox/neutrino/daemons/nhttpd/web/Y_VLC.js b/tuxbox/neutrino/daemons/nhttpd/web/Y_VLC.js index 88bfd11..6f308dd 100644 --- a/tuxbox/neutrino/daemons/nhttpd/web/Y_VLC.js +++ b/tuxbox/neutrino/daemons/nhttpd/web/Y_VLC.js @@ -1,4 +1,4 @@ -/* VLC abstraction by yjo...@online.de +/* VLC abstraction by yjogol $Date: $ $Revision: $ */ @@ -50,49 +50,41 @@ CyVLC.prototype = { var words = vstr.split(" "); return words[0]; } - else - if (navigator.plugins && (navigator.plugins.length > 0)) { - var name = "VLC"; - for(var i=0;i<navigator.plugins.length;++i) - if (navigator.plugins[i].name.indexOf(name) != -1) - var plug = navigator.plugins[navigator.plugins[i].name]; - - if(typeof plug != 'undefined') { - var Suche = /(PLUGIN)/gi; - var Ergebnis = Suche.test(plug.description); - if (Ergebnis == true){ - var ex = /^.*[pP]lugin [\"]*([^ \"]*)[\"]*.*$/; - var ve = ex.exec(plug.description); - }else{ - var ex = /^.*[vV]ersion [\"]*([^ \"]*)[\"]*.*$/; - var ve = ex.exec(plug.description); + else if (navigator.plugins && (navigator.plugins.length > 0)) { + var numPlugins = navigator.plugins.length; + for(var i = 0; i < numPlugins; i++) { + var plugin = navigator.plugins[i]; + var numTypes = plugin.length; + for (var j = 0; j < numTypes; j++) + { + var mimetype = plugin[j]; + if (mimetype) { + if (mimetype.type.indexOf("application/x-vlc-plugin") != -1) { + return plugin.version; + } + } } } - var Suche = /([0-9])/g; - var Ergebnis = Suche.test(ve); - if (Ergebnis == true) - return ve[1]; - else - return "0.0.0"; - } - else return "0.0.0"; + } + else + return "0.0.0"; }, _generate_sub_versions : function() { - if(this.version_string == "") - return + if(this.version_string === "") + return; var ex = /([^\.]*)[\.]*([^\.]*)[\.]*([^\.-]*)[\.-]*([^\.]*).*$/; var ve = ex.exec(this.version_string); if(ve.length >1) this.version_level1 = ve[1]; if(ve.length >2) this.version_level2 = ve[2]; - if(ve.length >3 && ve[3] != "") this.version_level3 = ve[3]; - if(ve.length >4 && ve[4] != "") this.version_level4 = ve[4]; + if(ve.length >3 && ve[3] !== "") this.version_level3 = ve[3]; + if(ve.length >4 && ve[4] !== "") this.version_level4 = ve[4]; }, _determine_plugin_generation : function() { if(is_ie) this.plugin = "ie1"; else - if(this.version_level1 <= "0" && this.version_level2 <= "8" && this.version_level3 <= "5") + if(this.version_level1 <= 0 && this.version_level2 <= 8 && this.version_level3 <= 5) this.plugin = "moz1"; else this.plugin = "moz2"; ----------------------------------------------------------------------- Summary of changes: tuxbox/neutrino/daemons/nhttpd/web/Y_VLC.js | 52 +++++++++++--------------- 1 files changed, 22 insertions(+), 30 deletions(-) -- Tuxbox-GIT: apps ------------------------------------------------------------------------------ One dashboard for servers and applications across Physical-Virtual-Cloud Widest out-of-the-box monitoring support with 50+ applications Performance metrics, stats and reports that give you Actionable Insights Deep dive visibility with transaction tracing using APM Insight. http://ad.doubleclick.net/ddm/clk/290420510;117567292;y _______________________________________________ Tuxbox-cvs-commits mailing list Tuxbox-cvs-commits@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/tuxbox-cvs-commits