소스 검색

reapply styles specified in dropdownCss option when dropdown is opened to ensure they do not get removed. fixes #305

Igor Vaynberg 13 년 전
부모
커밋
e7dee23c08
1개의 변경된 파일1개의 추가작업 그리고 1개의 파일을 삭제
  1. 1 1
      select2.js

+ 1 - 1
select2.js

@@ -497,7 +497,6 @@
             this.container.data("select2", this);
 
             this.dropdown = this.container.find(".select2-drop");
-            this.dropdown.css(evaluate(opts.dropdownCss));
             this.dropdown.addClass(evaluate(opts.dropdownCssClass));
             this.dropdown.data("select2", this);
 
@@ -886,6 +885,7 @@
 
             if (this.search.val() === " ") { this.search.val(""); }
 
+            this.dropdown.css(evaluate(this.opts.dropdownCss));
             this.dropdown.addClass("select2-drop-active");
             this.container.addClass("select2-dropdown-open").addClass("select2-container-active");