Browse Source

Use Array indexOf method for browsers that don't have TypedArray indexOf method.

tags/2.2.0
Matthew Petroff 8 years ago
parent
commit
9b4050552f
1 changed files with 5 additions and 0 deletions
  1. +5
    -0
      src/js/pannellum.js

+ 5
- 0
src/js/pannellum.js View File

@@ -388,6 +388,11 @@ function parseGPanoXMP(image) {
var reader = new FileReader();
reader.addEventListener('loadend', function() {
var img = new Uint8Array(reader.result);
if (Uint8Array.prototype.indexOf === undefined) {
// Use Array.prototype.indexOf method for browsers that don't
// support ECMAScript 6's TypedArray.prototype.indexOf
Uint8Array.prototype.indexOf = Array.prototype.indexOf;
}

// This awful browser specific test exists because iOS 8 does not work
// with non-progressive encoded JPEGs.


Loading…
Cancel
Save