Re-added widget textbox blur fix FF

This commit is contained in:
Jonathan Frederic 2014-02-27 16:15:11 -08:00
parent bfc51c2a29
commit 0884716a7d

View File

@ -751,17 +751,17 @@ var IPython = (function (IPython) {
};
e.on('focusin', handle_focus);
e.on('focusout', handle_blur);
// // TODO: Very strange. The focusout event does not seem fire for the
// // bootstrap textboxes on FF25&26...
// e.find('input').blur(handle_blur);
// e.on('DOMNodeInserted', function (event) {
// var target = $(event.target);
// if (target.is('input')) {
// target.blur(handle_blur);
// } else {
// target.find('input').blur(handle_blur);
// }
// });
// TODO: Very strange. The focusout event does not seem fire for the
// bootstrap textboxes on FF25&26...
e.find('input').blur(handle_blur);
e.on('DOMNodeInserted', function (event) {
var target = $(event.target);
if (target.is('input')) {
target.blur(handle_blur);
} else {
target.find('input').blur(handle_blur);
}
});
// There are times (raw_input) where we remove the element from the DOM before
// focusout is called. In this case we bind to the remove event of jQueryUI,
// which gets triggered upon removal, iff it is focused at the time.