applicious_utils 0.1.36 → 0.1.37
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Binary file
|
@@ -21,7 +21,6 @@ module AppliciousUtils
|
|
21
21
|
# max_filesize 2.megabytes
|
22
22
|
|
23
23
|
def s3_uploader(options = {})
|
24
|
-
#config = YAML.load(options[:s3_keys])[Rails.env].symbolize_keys
|
25
24
|
options[:s3_config_filename] ||= Rails.root.join('config', 'amazon_s3.yml')
|
26
25
|
config = YAML.load_file(options[:s3_config_filename])[Rails.env].symbolize_keys
|
27
26
|
bucket = config[:bucket_name]
|
@@ -67,28 +66,14 @@ module AppliciousUtils
|
|
67
66
|
// image uploader via plupload
|
68
67
|
var uploader = new plupload.Uploader({
|
69
68
|
runtimes : 'html5,flash,silverlight',
|
70
|
-
browse_button : '
|
69
|
+
browse_button : 'applicious_uploader',
|
71
70
|
max_file_size : '500mb',
|
72
71
|
url : 'http://#{bucket}.s3.amazonaws.com/',
|
73
|
-
flash_swf_url: 'applicious/plupload/plupload.flash.swf',
|
72
|
+
flash_swf_url: '/applicious/plupload/plupload.flash.swf',
|
74
73
|
silverlight_xap_url: '/applicious/plupload/plupload.silverlight.xap',
|
75
|
-
|
76
|
-
|
77
|
-
|
78
|
-
if (up.files.length > 1) {
|
79
|
-
up.removeFile(file);
|
80
|
-
}
|
81
|
-
});
|
82
|
-
if (up.files.length >= 1) {
|
83
|
-
$('#pickfiles').fadeOut('slow');
|
84
|
-
}
|
85
|
-
},
|
86
|
-
FilesRemoved: function(up, files) {
|
87
|
-
if (up.files.length < 1) {
|
88
|
-
$('#pickfiles').fadeIn('slow');
|
89
|
-
}
|
90
|
-
}
|
91
|
-
},
|
74
|
+
|
75
|
+
//resize : {width : 320, height : 240, quality : 90},
|
76
|
+
|
92
77
|
multi_selection: false,
|
93
78
|
multipart: true,
|
94
79
|
multipart_params: {
|
@@ -107,42 +92,25 @@ module AppliciousUtils
|
|
107
92
|
file_data_name: 'file'
|
108
93
|
});
|
109
94
|
|
110
|
-
|
111
|
-
|
112
|
-
|
113
|
-
|
114
|
-
uploader.bind('FilesAdded', function(up, files) {
|
115
|
-
$('#progress_bar .ui-progress').css('width', '5%');
|
116
|
-
$('span.ui-label').show();
|
117
|
-
|
118
|
-
// start the uploader after the progress bar shows
|
119
|
-
$('#progress_bar').show(function () {
|
120
|
-
uploader.start();
|
121
|
-
});
|
122
|
-
});
|
95
|
+
uploader.bind('FilesAdded', function(up, files) {
|
96
|
+
AP.log( up, file );
|
97
|
+
up.refresh(); // Reposition Flash/Silverlight
|
98
|
+
});
|
123
99
|
|
124
|
-
|
125
|
-
|
126
|
-
|
127
|
-
$('#progress_bar .ui-progress').css('width', file.percent+'%');
|
128
|
-
}
|
129
|
-
else {
|
130
|
-
$('#progress_bar .ui-progress').css('width', '100%');
|
131
|
-
$('span.ui-label').text('Complete');
|
132
|
-
}
|
133
|
-
});
|
100
|
+
uploader.bind('UploadProgress', function(up, file) {
|
101
|
+
AP.log( up, file );
|
102
|
+
});
|
134
103
|
|
135
|
-
|
136
|
-
|
137
|
-
|
138
|
-
|
139
|
-
|
140
|
-
|
141
|
-
|
142
|
-
|
143
|
-
|
144
|
-
|
145
|
-
});
|
104
|
+
uploader.bind('Error', function(up, err) {
|
105
|
+
AP.log( up, err );
|
106
|
+
up.refresh(); // Reposition Flash/Silverlight
|
107
|
+
});
|
108
|
+
|
109
|
+
uploader.bind('FileUploaded', function(up, file) {
|
110
|
+
AP.log( up, file );
|
111
|
+
});
|
112
|
+
|
113
|
+
uploader.init();
|
146
114
|
|
147
115
|
});")
|
148
116
|
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: applicious_utils
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.1.
|
4
|
+
version: 0.1.37
|
5
5
|
prerelease:
|
6
6
|
platform: ruby
|
7
7
|
authors:
|
@@ -74,6 +74,7 @@ files:
|
|
74
74
|
- app/assets/stylesheets/applicious_utils/FbMultiFriendSelector/jquery.facebook.multifriend.select.min.js
|
75
75
|
- app/assets/stylesheets/applicious_utils/FbMultiFriendSelector/README.md
|
76
76
|
- app/assets/stylesheets/applicious_utils/index.css
|
77
|
+
- applicious_utils-0.1.36.gem
|
77
78
|
- applicious_utils.gemspec
|
78
79
|
- Gemfile
|
79
80
|
- lib/applicious_utils/engine.rb
|