Skip to content

Commit 6624bdd

Browse files
author
macintosh
committed
scripts update
1 parent 0ff3c5b commit 6624bdd

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

48 files changed

+4727
-565
lines changed

Gemfile

100644100755
File mode changed.

README.md

100644100755
File mode changed.

Rakefile

100644100755
File mode changed.

jquery-fileupload-rails.gemspec

100644100755
Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -8,8 +8,8 @@ Gem::Specification.new do |s|
88
s.authors = ["Tors Dalid"]
99
s.email = ["cletedalid@gmail.com"]
1010
s.homepage = "https://github.com/tors/jquery-fileupload-rails"
11-
s.summary = %q{jQuery File Upload for Rails 3.1 Asset Pipeline}
12-
s.description = %q{jQuery File Upload by Sebastian Tschan integrated for Rails 3.1 Asset Pipeline}
11+
s.summary = %q{jQuery File Upload for Rails Asset Pipeline}
12+
s.description = %q{jQuery File Upload by Sebastian Tschan integrated for Rails Asset Pipeline}
1313

1414
s.rubyforge_project = "jquery-fileupload-rails"
1515

lib/jquery-fileupload-rails.rb

100644100755
File mode changed.

lib/jquery/fileupload/rails/engine.rb

100644100755
File mode changed.

lib/jquery/fileupload/rails/middleware.rb

100644100755
File mode changed.

lib/jquery/fileupload/rails/upload.rb

100644100755
File mode changed.

lib/jquery/fileupload/rails/version.rb

100644100755
Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
module JQuery
22
module FileUpload
33
module Rails
4-
VERSION = "0.4.1"
4+
VERSION = "1.0.0"
55
end
66
end
77
end

public/.DS_Store

6 KB
Binary file not shown.

public/cors/postmessage.html

Lines changed: 75 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,75 @@
1+
<!DOCTYPE HTML>
2+
<!--
3+
/*
4+
* jQuery File Upload Plugin postMessage API 1.2.1
5+
* https://github.com/blueimp/jQuery-File-Upload
6+
*
7+
* Copyright 2011, Sebastian Tschan
8+
* https://blueimp.net
9+
*
10+
* Licensed under the MIT license:
11+
* http://www.opensource.org/licenses/MIT
12+
*/
13+
-->
14+
<html lang="en">
15+
<head>
16+
<meta charset="utf-8">
17+
<title>jQuery File Upload Plugin postMessage API</title>
18+
<script src="//ajax.googleapis.com/ajax/libs/jquery/1.10.1/jquery.min.js"></script>
19+
</head>
20+
<body>
21+
<script>
22+
/*jslint unparam: true, regexp: true */
23+
/*global $, Blob, FormData, location */
24+
'use strict';
25+
var origin = /^http:\/\/example.org/,
26+
target = new RegExp('^(http(s)?:)?\\/\\/' + location.host + '\\/');
27+
$(window).on('message', function (e) {
28+
e = e.originalEvent;
29+
var s = e.data,
30+
xhr = $.ajaxSettings.xhr(),
31+
f;
32+
if (!origin.test(e.origin)) {
33+
throw new Error('Origin "' + e.origin + '" does not match ' + origin);
34+
}
35+
if (!target.test(e.data.url)) {
36+
throw new Error('Target "' + e.data.url + '" does not match ' + target);
37+
}
38+
$(xhr.upload).on('progress', function (ev) {
39+
ev = ev.originalEvent;
40+
e.source.postMessage({
41+
id: s.id,
42+
type: ev.type,
43+
timeStamp: ev.timeStamp,
44+
lengthComputable: ev.lengthComputable,
45+
loaded: ev.loaded,
46+
total: ev.total
47+
}, e.origin);
48+
});
49+
s.xhr = function () {
50+
return xhr;
51+
};
52+
if (!(s.data instanceof Blob)) {
53+
f = new FormData();
54+
$.each(s.data, function (i, v) {
55+
f.append(v.name, v.value);
56+
});
57+
s.data = f;
58+
}
59+
$.ajax(s).always(function (result, statusText, jqXHR) {
60+
if (!jqXHR.done) {
61+
jqXHR = result;
62+
result = null;
63+
}
64+
e.source.postMessage({
65+
id: s.id,
66+
status: jqXHR.status,
67+
statusText: statusText,
68+
result: result,
69+
headers: jqXHR.getAllResponseHeaders()
70+
}, e.origin);
71+
});
72+
});
73+
</script>
74+
</body>
75+
</html>

public/cors/result.html

Lines changed: 24 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,24 @@
1+
<!DOCTYPE HTML>
2+
<!--
3+
/*
4+
* jQuery Iframe Transport Plugin Redirect Page 2.0.1
5+
* https://github.com/blueimp/jQuery-File-Upload
6+
*
7+
* Copyright 2010, Sebastian Tschan
8+
* https://blueimp.net
9+
*
10+
* Licensed under the MIT license:
11+
* http://www.opensource.org/licenses/MIT
12+
*/
13+
-->
14+
<html lang="en">
15+
<head>
16+
<meta charset="utf-8">
17+
<title>jQuery Iframe Transport Plugin Redirect Page</title>
18+
</head>
19+
<body>
20+
<script>
21+
document.body.innerText=document.body.textContent=decodeURIComponent(window.location.search.slice(1));
22+
</script>
23+
</body>
24+
</html>

vendor/.DS_Store

6 KB
Binary file not shown.

vendor/assets/.DS_Store

6 KB
Binary file not shown.

vendor/assets/images/.DS_Store

6 KB
Binary file not shown.

vendor/assets/javascripts/.DS_Store

6 KB
Binary file not shown.
Binary file not shown.

vendor/assets/javascripts/jquery-fileupload/basic.js

100644100755
File mode changed.

vendor/assets/javascripts/jquery-fileupload/cors/jquery.postmessage-transport.js

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/*
2-
* jQuery postMessage Transport Plugin 1.1
2+
* jQuery postMessage Transport Plugin 1.1.1
33
* https://github.com/blueimp/jQuery-File-Upload
44
*
55
* Copyright 2011, Sebastian Tschan
@@ -64,8 +64,9 @@
6464
xhrUpload = options.xhr().upload;
6565
return {
6666
send: function (_, completeCallback) {
67+
counter += 1;
6768
var message = {
68-
id: 'postmessage-transport-' + (counter += 1)
69+
id: 'postmessage-transport-' + counter
6970
},
7071
eventName = 'message.' + message.id;
7172
iframe = $(

vendor/assets/javascripts/jquery-fileupload/index.js

100644100755
Lines changed: 11 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,18 @@
11
//=require jquery-fileupload/vendor/jquery.ui.widget
2+
//=require jquery-fileupload/vendor/tmpl
23
//=require jquery-fileupload/vendor/load-image
4+
//=require jquery-fileupload/vendor/load-image-ios
5+
//=require jquery-fileupload/vendor/load-image-orientation
6+
//=require jquery-fileupload/vendor/load-image-meta
7+
//=require jquery-fileupload/vendor/load-image-exif
8+
//=require jquery-fileupload/vendor/load-image-exif-map
39
//=require jquery-fileupload/vendor/canvas-to-blob
4-
//=require jquery-fileupload/vendor/tmpl
510
//=require jquery-fileupload/jquery.iframe-transport
611
//=require jquery-fileupload/jquery.fileupload
7-
//=require jquery-fileupload/jquery.fileupload-fp
12+
//=require jquery-fileupload/jquery.fileupload-image
13+
//=require jquery-fileupload/jquery.fileupload-process
14+
//=require jquery-fileupload/jquery.fileupload-audio
15+
//=require jquery-fileupload/jquery.fileupload-video
16+
//=require jquery-fileupload/jquery.fileupload-validate
817
//=require jquery-fileupload/jquery.fileupload-ui
918
//=require jquery-fileupload/locale

0 commit comments

Comments
 (0)