drag modal dialogs by the header only

without this, it is not possible to select any text using the mouse in
the contents of the modal. For example: editing the notebook metadata
JSON you end up just moving the whole box around instead of being able
to select a portion of the JSON using the mouse.
pull/2076/head
Paul Ivanov 9 years ago
parent 3d7f0f2aca
commit 74ac1c04e6

@ -56,7 +56,7 @@ define(function(require) {
$("<div/>")
.addClass("modal-header")
.mousedown(function() {
$(".modal").draggable();
$(".modal").draggable({handle: '.modal-header'});
})
.append($("<button>")
.attr("type", "button")
@ -72,9 +72,6 @@ define(function(require) {
).append(
$("<div/>")
.addClass("modal-body")
.mousedown(function() {
$(".modal").draggable();
})
.append(
options.body || $("<p/>")
)

Loading…
Cancel
Save