aboutsummaryrefslogtreecommitdiffstats
path: root/assets/js
diff options
context:
space:
mode:
Diffstat (limited to 'assets/js')
-rw-r--r--assets/js/simple-media.js15
1 files changed, 6 insertions, 9 deletions
diff --git a/assets/js/simple-media.js b/assets/js/simple-media.js
index ab1a5505..bc576b52 100644
--- a/assets/js/simple-media.js
+++ b/assets/js/simple-media.js
@@ -22,6 +22,7 @@
// Default config
var defaults = {
+ enabled: true, // /Android|webOS|iPhone|iPad|iPod|BlackBerry/i.test(navigator.userAgent)
debug: false,
seekInterval: 10,
volume: 5,
@@ -866,6 +867,11 @@
// Extend the default options with user specified
config = extend(defaults, options);
+ // If enabled carry on
+ if(!config.enabled) {
+ return false;
+ }
+
// Setup the fullscreen api
fullscreen = fullscreenApi();
@@ -888,15 +894,6 @@
return false;
}
- // If smartphone or tablet, stop customization as video (and captions in latest devices) are handled natively
- player.isSmartphoneOrTablet = /Android|webOS|iPhone|iPad|iPod|BlackBerry/i.test(navigator.userAgent);
- if (player.isSmartphoneOrTablet) {
- if(config.debug) {
- console.error("Browser not suppported.");
- }
- return false;
- }
-
// Set up aria-label for Play button with the title option
if (typeof(config.title) === "undefined" || !config.title.length) {
config.playAriaLabel = "Play";