Skip to content

Commit 13b4be8

Browse files
committed
Merge pull request #75 from lifof/master
cell plugin & pdf compression with Deflate & javascript plugin
2 parents 631bfc2 + 4b72e88 commit 13b4be8

File tree

1 file changed

+7
-4
lines changed

1 file changed

+7
-4
lines changed

jspdf.js

Lines changed: 7 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -933,14 +933,17 @@ PubSub implementation
933933
@name output
934934
*/
935935
output = function (type, options) {
936-
var undef, isThisSafari, data, length, array, i, blob;
936+
var undef, data, length, array, i, blob;
937937
switch (type) {
938938
case undef:
939939
return buildDocument();
940940
case 'save':
941-
isThisSafari = navigator.vendor !== undefined ? navigator.vendor.split(' ')[0] : 'must be ie';
942-
if (window.opera !== undefined || isThisSafari === 'Apple') {
943-
return API.output('dataurlnewwindow');
941+
if (navigator.getUserMedia || Blob.prototype.slice === undefined) {
942+
if (window.URL === undefined) {
943+
return API.output('dataurlnewwindow');
944+
} else if (window.URL.createObjectURL === undefined) {
945+
return API.output('dataurlnewwindow');
946+
}
944947
}
945948
data = buildDocument();
946949

0 commit comments

Comments
 (0)