allow focusing of detached children still.

This commit is contained in:
Christopher Jeffrey 2015-07-30 17:58:30 -07:00
parent 22469380e2
commit fe1f470995
1 changed files with 1 additions and 3 deletions

View File

@ -1623,11 +1623,9 @@ Screen.prototype._focus = function(self, old) {
if (el.scrollable) break; if (el.scrollable) break;
} }
if (el && el.detached) return;
// If we're in a scrollable element, // If we're in a scrollable element,
// automatically scroll to the focused element. // automatically scroll to the focused element.
if (el) { if (el && !el.detached) {
// NOTE: This is different from the other "visible" values - it needs the // NOTE: This is different from the other "visible" values - it needs the
// visible height of the scrolling element itself, not the element within // visible height of the scrolling element itself, not the element within
// it. // it.