Selaa lähdekoodia

style detection for search field sizer corrected

Signed-off-by: Igor Vaynberg <[email protected]>
creage 13 vuotta sitten
vanhempi
commit
9497693b64
1 muutettua tiedostoa jossa 1 lisäystä ja 1 poistoa
  1. 1 1
      select2.js

+ 1 - 1
select2.js

@@ -203,7 +203,7 @@
 
 
     function measureTextWidth(e) {        
     function measureTextWidth(e) {        
         if (!sizer){
         if (!sizer){
-        	var style = e.currentStyle || window.getComputedStyle(e, null);
+        	var style = e[0].currentStyle || window.getComputedStyle(e[0], null);
         	sizer = $("<div></div>").css({
         	sizer = $("<div></div>").css({
 	            position: "absolute",
 	            position: "absolute",
 	            left: "-1000px",
 	            left: "-1000px",