Permalink
Browse files

removing some extra console.logs and changing the FilterType to neare…

…st neighbor in IE
  • Loading branch information...
heygrady committed Oct 3, 2010
1 parent d93dde9 commit a0ebc90c9cf99f556fab312182fee23e05b57e23
Showing with 8 additions and 8 deletions.
  1. +8 −8 lib/jquery.transform.js
View
@@ -367,9 +367,12 @@
this.$elem.css(property, 'matrix(' + a + ', ' + b + ', ' + c + ', ' + d + ', ' + tx + ', ' + ty + ')');
} else if (jQuery.browser.msie) { // IE
// IE requires the special transform Filter
+ var filterType = ', filterType=\'nearest neighbor\''; //bilinear
var style = this.$elem[0].style;
- var matrixFilter = 'progid:DXImageTransform.Microsoft.Matrix(M11=' + a + ', M12=' + c + ', M21=' + b + ', M22=' + d + ', sizingMethod=\'auto expand\')';
- var filter = style.filter || jQuery.curCSS( this.$elem[0], "filter" ) || "";
+ var matrixFilter = 'progid:DXImageTransform.Microsoft.Matrix(' +
+ 'M11=' + a + ', M12=' + c + ', M21=' + b + ', M22=' + d +
+ ', sizingMethod=\'auto expand\'' + filterType + ')';
+ var filter = style.filter || jQuery.curCSS( this.$elem[0], "filter" ) || "";var filter = style.filter || jQuery.curCSS( this.$elem[0], "filter" ) || "";
style.filter = rmatrix.test(filter) ? filter.replace(rmatrix, matrixFilter) : filter ? filter + ' ' + matrixFilter : matrixFilter;
// Let's know that we're applying post matrix fixes and the height/width will be static for a bit
@@ -431,7 +434,6 @@
} else {
this.setAttr('origin', [x, y]);
}
- console.log(x, y);
return true;
},
@@ -500,7 +502,6 @@
// now we need to fix it!
var calc = new $.matrix.calc(matrix, this.safeOuterHeight(), this.safeOuterWidth()),
origin = this.getAttr('origin');
- console.log(origin);
// translate a 0, 0 origin to the current origin
var offset = calc.originOffset({
@@ -749,11 +750,11 @@
var transform = this.attr || this.$elem.attr(attr);
if (!transform) {
// We don't have any existing values, save it
- this.attr = value;
+ this.attr = func + '(' + value + ')';
this.$elem.attr(attr, this.attr);
} else if (transform.indexOf(func) > -1) {
// we don't have this function yet, save it
- this.attr = transform + ' ' + value;
+ this.attr = transform + ' ' + func + '(' + value + ')';
this.$elem.attr(attr, this.attr);
}
@@ -771,7 +772,7 @@
parts = rfuncvalue.exec(values[i]);
if (func == parts[1]) {
- values[i] = value;
+ values[i] = func + '(' + value + ')';
break;
}
}
@@ -823,7 +824,6 @@
}
var transform = this.attr || this.$elem.attr(attr);
- console.log(transform);
var rscalefunc = $.transform.rfunc.scale;
if (func != 'origin' && func != 'matrix' && (!transform || transform.indexOf(func) === -1)) {
// We don't have any existing values, return null

0 comments on commit a0ebc90

Please sign in to comment.