commit
ee17e4ec27
@ -244,7 +244,7 @@ the specific language governing permissions and limitations under the Apache Lic
|
|||||||
function measureTextWidth(e) {
|
function measureTextWidth(e) {
|
||||||
if (!sizer){
|
if (!sizer){
|
||||||
var style = e[0].currentStyle || window.getComputedStyle(e[0], null);
|
var style = e[0].currentStyle || window.getComputedStyle(e[0], null);
|
||||||
sizer = $("<div></div>").css({
|
sizer = $(document.createElement("div")).css({
|
||||||
position: "absolute",
|
position: "absolute",
|
||||||
left: "-10000px",
|
left: "-10000px",
|
||||||
top: "-10000px",
|
top: "-10000px",
|
||||||
@ -725,7 +725,7 @@ the specific language governing permissions and limitations under the Apache Lic
|
|||||||
if (compound) { node.addClass("select2-result-with-children"); }
|
if (compound) { node.addClass("select2-result-with-children"); }
|
||||||
node.addClass(self.opts.formatResultCssClass(result));
|
node.addClass(self.opts.formatResultCssClass(result));
|
||||||
|
|
||||||
label=$("<div></div>");
|
label=$(document.createElement("div"));
|
||||||
label.addClass("select2-result-label");
|
label.addClass("select2-result-label");
|
||||||
|
|
||||||
formatted=opts.formatResult(result, label, query);
|
formatted=opts.formatResult(result, label, query);
|
||||||
@ -1432,7 +1432,7 @@ the specific language governing permissions and limitations under the Apache Lic
|
|||||||
// single
|
// single
|
||||||
|
|
||||||
createContainer: function () {
|
createContainer: function () {
|
||||||
var container = $("<div></div>", {
|
var container = $(document.createElement("div").attr({
|
||||||
"class": "select2-container"
|
"class": "select2-container"
|
||||||
}).html([
|
}).html([
|
||||||
" <a href='javascript:void(0)' onclick='return false;' class='select2-choice'>",
|
" <a href='javascript:void(0)' onclick='return false;' class='select2-choice'>",
|
||||||
@ -1830,7 +1830,7 @@ the specific language governing permissions and limitations under the Apache Lic
|
|||||||
|
|
||||||
// multi
|
// multi
|
||||||
createContainer: function () {
|
createContainer: function () {
|
||||||
var container = $("<div></div>", {
|
var container = $(document.createElement("div").attr({
|
||||||
"class": "select2-container select2-container-multi"
|
"class": "select2-container select2-container-multi"
|
||||||
}).html([
|
}).html([
|
||||||
" <ul class='select2-choices'>",
|
" <ul class='select2-choices'>",
|
||||||
|
Loading…
Reference in New Issue
Block a user