Commit 839b0c89 authored by fat's avatar fat

shiiiit

parent 0992a859
......@@ -148,7 +148,7 @@
}
, removeBackdrop: function () {
this.$backdrop.remove()
this.$backdrop && this.$backdrop.remove()
this.$backdrop = null
}
......
......@@ -946,7 +946,7 @@
}
, removeBackdrop: function () {
this.$backdrop.remove()
this.$backdrop && this.$backdrop.remove()
this.$backdrop = null
}
......
This diff is collapsed.
......@@ -148,7 +148,7 @@
}
, removeBackdrop: function () {
this.$backdrop.remove()
this.$backdrop && this.$backdrop.remove()
this.$backdrop = null
}
......
......@@ -117,4 +117,21 @@ $(function () {
})
.modal("toggle")
})
test("should allow modal close with 'backdrop:false'", function () {
stop()
$.support.transition = false
var div = $("<div>", { id: 'modal-test', "data-backdrop": false })
div
.bind("shown", function () {
ok($('#modal-test').is(":visible"), 'modal visible')
div.modal("hide")
})
.bind("hidden", function() {
ok(!$('#modal-test').is(":visible"), 'modal hidden')
div.remove()
start()
})
.modal("show")
})
})
\ No newline at end of file
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