Skip to content


"Open Terminal" button gets triggered by spacebar (in Firefox?) #49

risacher opened this Issue · 2 comments

2 participants


If I click the "Open Terminal" button it gets focus. Then the first time I hit the spacebar, the button is activated (again) and another terminal opens. This is quite annoying.

Calling 'blur()' on the open button fixes:

--- a/static/tty.js                                                             
+++ b/static/tty.js                                                             
@@ -75,6 +76,7 @@ = function() {                                       
   if (open) {                                                                  
     on(open, 'click', function() {                                             
       new Window;                                                              
+      open.blur();                                                             
@risacher risacher added a commit to risacher/tty.js that referenced this issue
@risacher risacher fix issue #49 in chjj's tree
calls blur() on the open terminal and light switch buttons after clicking them
which prevents them from being activated again by the spacebar in some browsers

Could not duplicate problem any longer with current Firefox Nightly on Win7, Firefox on Ubuntu or Firefox,Chrome, or Safari on OSX Mavericks. Apparently the browsers are fixed.

@risacher risacher closed this
@zodern zodern pushed a commit that referenced this issue
@chjj implement a redraw method. fixes #49. fd32c35

Just a note that this probably could have been fixed by sending focus to the terminal when it opened. That would be proper focus management!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Something went wrong with that request. Please try again.