constructor-core 0.3.0 → 0.3.1
Sign up to get free protection for your applications and to get access to all the features.
@@ -25,15 +25,20 @@
|
|
25
25
|
var existing_onload = context.onload || new Function;
|
26
26
|
|
27
27
|
context.onload = function() {
|
28
|
-
|
29
|
-
for (i = 0; i < images.length; i++) {
|
30
|
-
image = images[i];
|
31
|
-
retinaImages.push(new RetinaImage(image));
|
32
|
-
}
|
28
|
+
Retina.update();
|
33
29
|
existing_onload();
|
34
30
|
}
|
35
31
|
};
|
36
32
|
|
33
|
+
Retina.update = function() {
|
34
|
+
var images = document.getElementsByTagName("img"), retinaImages = [], i, image;
|
35
|
+
for (i = 0; i < images.length; i++) {
|
36
|
+
image = images[i];
|
37
|
+
retinaImages.push(new RetinaImage(image));
|
38
|
+
}
|
39
|
+
};
|
40
|
+
|
41
|
+
|
37
42
|
Retina.isRetina = function(){
|
38
43
|
var mediaQuery = "(-webkit-min-device-pixel-ratio: 1.5),\
|
39
44
|
(min--moz-device-pixel-ratio: 1.5),\
|
@@ -114,6 +119,7 @@
|
|
114
119
|
});
|
115
120
|
}
|
116
121
|
|
122
|
+
|
117
123
|
root.RetinaImage = RetinaImage;
|
118
124
|
|
119
125
|
RetinaImage.prototype.swap = function(path) {
|
data/constructor-core.gemspec
CHANGED
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: constructor-core
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.3.
|
4
|
+
version: 0.3.1
|
5
5
|
prerelease:
|
6
6
|
platform: ruby
|
7
7
|
authors:
|
@@ -9,7 +9,7 @@ authors:
|
|
9
9
|
autorequire:
|
10
10
|
bindir: bin
|
11
11
|
cert_chain: []
|
12
|
-
date: 2013-
|
12
|
+
date: 2013-06-02 00:00:00.000000000 Z
|
13
13
|
dependencies:
|
14
14
|
- !ruby/object:Gem::Dependency
|
15
15
|
name: devise
|