Use the moz selector hack only on Firefox.

This commit is contained in:
Nicolas Stepien 2011-11-27 19:23:19 +01:00
parent a2f1c83503
commit b7117afaeb
2 changed files with 2 additions and 2 deletions

View File

@ -2855,7 +2855,7 @@
img = $.el('img', {
src: a.href
});
if (a.parentNode.className !== 'op') {
if (engine === "Gecko" && a.parentNode.className !== 'op') {
filesize = $('.filesize', a.parentNode);
_ref = filesize.textContent.match(/(\d+)x/), _ = _ref[0], max = _ref[1];
img.style.maxWidth = "-moz-calc(" + max + "px)";

View File

@ -2188,7 +2188,7 @@ imgExpand =
a = thumb.parentNode
img = $.el 'img',
src: a.href
unless a.parentNode.className is 'op'
if engine is "Gecko" and a.parentNode.className isnt 'op'
filesize = $ '.filesize', a.parentNode
[_, max] = filesize.textContent.match /(\d+)x/
img.style.maxWidth = "-moz-calc(#{max}px)"