Permalink
Browse files

fixes

  • Loading branch information...
Mikhail Bezoyan
Mikhail Bezoyan committed Feb 3, 2014
1 parent 7378099 commit 98590cdc790ad5dc779aa14b3eaf49c693533ae9
View
@@ -173,6 +173,7 @@ module.exports = function (grunt) {
grunt.loadNpmTasks('grunt-contrib-uglify');
grunt.loadNpmTasks('grunt-contrib-watch');
grunt.loadNpmTasks('grunt-contrib-connect');
+ grunt.loadNpmTasks('grunt-contrib-compress');
grunt.loadNpmTasks('grunt-mxmlc');
grunt.loadNpmTasks('grunt-curl');
// Load custom QUnit task, based on grunt-contrib-qunit, but support "files" option.
@@ -36,4 +36,16 @@ module.exports = function (grunt) {
}
});
+ grunt.config.set('compress.main', {
+ options: {
+ archive: '<%= pkg.name %>-<%= pkg.version.replace(/\\./g,"-") %>.zip'
+ },
+ files: [
+ {cwd: 'dist/', expand: true, src: ['*'], dest: '<%= pkg.version.replace(/\\./g,"-") %>/'}
+ ]
+ });
+
+
+ grunt.registerTask('build-zip', ['build', 'compress']);
+
};
Binary file not shown.
Binary file not shown.
View
Binary file not shown.
View
@@ -1,4 +1,4 @@
-/*! FileAPI 2.0.3 - BSD | git://github.com/mailru/FileAPI.git
+/*! FileAPI 2.0.3b - BSD | git://github.com/mailru/FileAPI.git
* FileAPI — a set of javascript tools for working with files. Multiupload, drag'n'drop and chunked file upload. Images: crop, resize and auto orientation by EXIF.
*/
@@ -201,7 +201,7 @@
_elEvents[uid] = {};
}
- var isFileReader = FileReader !=null && el instanceof FileReader;
+ var isFileReader = (FileReader && el) && (el instanceof FileReader);
_each(type.split(/\s+/), function (type){
if( jQuery && !isFileReader){
jQuery.event.add(el, type, fn);
@@ -228,7 +228,7 @@
if( el ){
var uid = api.uid(el), events = _elEvents[uid] || {};
- var isFileReader = FileReader != null && el instanceof FileReader;
+ var isFileReader = (FileReader && el) && (el instanceof FileReader);
_each(type.split(/\s+/), function (type){
if( jQuery && !isFileReader){
jQuery.event.remove(el, type, fn);
@@ -278,7 +278,7 @@
* FileAPI (core object)
*/
api = {
- version: '2.0.3',
+ version: '2.0.3b',
cors: false,
html5: true,
@@ -2968,7 +2968,7 @@
xhr.send(slice);
}
- xhr.send(slice);
+// xhr.send(slice);
file = slice = null;
} else {
// single piece upload

Large diffs are not rendered by default.

Oops, something went wrong.
View
@@ -1,4 +1,4 @@
-/*! FileAPI 2.0.3 - BSD | git://github.com/mailru/FileAPI.git
+/*! FileAPI 2.0.3b - BSD | git://github.com/mailru/FileAPI.git
* FileAPI — a set of javascript tools for working with files. Multiupload, drag'n'drop and chunked file upload. Images: crop, resize and auto orientation by EXIF.
*/
@@ -201,7 +201,7 @@
_elEvents[uid] = {};
}
- var isFileReader = FileReader !=null && el instanceof FileReader;
+ var isFileReader = (FileReader && el) && (el instanceof FileReader);
_each(type.split(/\s+/), function (type){
if( jQuery && !isFileReader){
jQuery.event.add(el, type, fn);
@@ -228,7 +228,7 @@
if( el ){
var uid = api.uid(el), events = _elEvents[uid] || {};
- var isFileReader = FileReader != null && el instanceof FileReader;
+ var isFileReader = (FileReader && el) && (el instanceof FileReader);
_each(type.split(/\s+/), function (type){
if( jQuery && !isFileReader){
jQuery.event.remove(el, type, fn);
@@ -278,7 +278,7 @@
* FileAPI (core object)
*/
api = {
- version: '2.0.3',
+ version: '2.0.3b',
cors: false,
html5: true,
@@ -2968,7 +2968,7 @@
xhr.send(slice);
}
- xhr.send(slice);
+// xhr.send(slice);
file = slice = null;
} else {
// single piece upload
@@ -3859,7 +3859,7 @@
return this.parent.apply(this, arguments);
}
else {
- api.log('FlashAPI.XHR._send: '+ flashId +' -> '+ fileId, JSON.stringify(files));
+ api.log('FlashAPI.XHR._send: '+ flashId +' -> '+ fileId);
}
_this.xhr = {
@@ -3878,7 +3878,7 @@
, callback: _wrap(function upload(evt){
var type = evt.type, result = evt.result;
- api.log('FlashAPI.upload.'+type+':' + JSON.stringify(evt));
+ api.log('FlashAPI.upload.'+type);
if( type == 'progress' ){
evt.loaded = Math.min(evt.loaded, evt.total); // @todo fixme
View

Large diffs are not rendered by default.

Oops, something went wrong.
View
@@ -565,7 +565,7 @@
return this.parent.apply(this, arguments);
}
else {
- api.log('FlashAPI.XHR._send: '+ flashId +' -> '+ fileId, JSON.stringify(files));
+ api.log('FlashAPI.XHR._send: '+ flashId +' -> '+ fileId);
}
_this.xhr = {
@@ -584,7 +584,7 @@
, callback: _wrap(function upload(evt){
var type = evt.type, result = evt.result;
- api.log('FlashAPI.upload.'+type+':' + JSON.stringify(evt));
+ api.log('FlashAPI.upload.'+type);
if( type == 'progress' ){
evt.loaded = Math.min(evt.loaded, evt.total); // @todo fixme
View
@@ -312,7 +312,6 @@
xhr.send(slice);
}
- xhr.send(slice);
file = slice = null;
} else {
// single piece upload
View
@@ -107,7 +107,7 @@
_elEvents[uid] = {};
}
- var isFileReader = FileReader !=null && el instanceof FileReader;
+ var isFileReader = (FileReader && el) && (el instanceof FileReader);
_each(type.split(/\s+/), function (type){
if( jQuery && !isFileReader){
jQuery.event.add(el, type, fn);
@@ -134,7 +134,7 @@
if( el ){
var uid = api.uid(el), events = _elEvents[uid] || {};
- var isFileReader = FileReader != null && el instanceof FileReader;
+ var isFileReader = (FileReader && el) && (el instanceof FileReader);
_each(type.split(/\s+/), function (type){
if( jQuery && !isFileReader){
jQuery.event.remove(el, type, fn);
@@ -184,7 +184,7 @@
* FileAPI (core object)
*/
api = {
- version: '2.0.3',
+ version: '2.0.3b',
cors: false,
html5: true,
View
@@ -14,7 +14,9 @@
"semver": "~1.0.14",
"temporary": "~0.0.4",
"phantomjs": "~1.9.2-4",
- "grunt-mxmlc": "~0.2.0"
+ "grunt-curl": "~1.4.0",
+ "grunt-mxmlc": "~0.2.0",
+ "grunt-contrib-compress": "~0.6.0"
},
"description": "FileAPI — a set of javascript tools for working with files. Multiupload, drag'n'drop and chunked file upload. Images: crop, resize and auto orientation by EXIF.",
"main": "dist/FileAPI.js",
@@ -35,7 +37,8 @@
"author": "Konstantin Lebedev <ibnRubaXa@gmail.com>",
"contributors": [
"Vladimir Demidov <v.demidov@corp.mail.ru>",
- "Ilya Lebedev <ilya@lebedev.net>"
+ "Ilya Lebedev <ilya@lebedev.net>",
+ "Mikhail Bezoyan <mbezoyan@gmail.com>"
],
"license": "BSD"
}

0 comments on commit 98590cd

Please sign in to comment.