From 3f917210e1d5181a309b7b99b200d9539a350e74 Mon Sep 17 00:00:00 2001 From: Rafael Oleza Date: Wed, 24 Apr 2019 13:19:25 +0200 Subject: [PATCH] Set the panel flag as focused when activate() is called --- src/pane.js | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/pane.js b/src/pane.js index 118393227..943a12589 100644 --- a/src/pane.js +++ b/src/pane.js @@ -393,7 +393,6 @@ class Pane { // Called by the view layer to indicate that the pane has gained focus. focus () { - this.focused = true return this.activate() } @@ -1011,6 +1010,8 @@ class Pane { // Public: Makes this pane the *active* pane, causing it to gain focus. activate () { if (this.isDestroyed()) throw new Error('Pane has been destroyed') + this.focused = true + if (this.container) this.container.didActivatePane(this) this.emitter.emit('did-activate') }