Commit c78cb0a8 authored by miripiruni's avatar miripiruni

Shower::_applyTransform: refactoring for transform, forEach instead of copy/paste

parent b8a1ccdf
......@@ -237,11 +237,15 @@ window.shower = window.shower || (function(window, document, undefined) {
* @returns {Boolean}
*/
shower._applyTransform = function(transform) {
body.style.WebkitTransform = transform;
body.style.MozTransform = transform;
body.style.msTransform = transform;
body.style.OTransform = transform;
body.style.transform = transform;
[
'WebkitTransform',
'MozTransform',
'msTransform',
'OTransform',
'transform',
].forEach(function(prop) {
body.style[prop] = transform;
});
return true;
};
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment