Skip to content

Commit

Permalink
Fix cursor focus, hide cursor when mouse move on it.
Browse files Browse the repository at this point in the history
  • Loading branch information
puritys committed Mar 12, 2018
1 parent a44bfd5 commit 53bbaa4
Showing 1 changed file with 5 additions and 2 deletions.
7 changes: 5 additions & 2 deletions js/nassh_deps.concat.js
Expand Up @@ -12681,7 +12681,6 @@ hterm.Terminal.prototype.onMouse_ = function(e) {
// with local text selection.
if (e.terminalRow - 1 == this.screen_.cursorPosition.row &&
e.terminalColumn - 1 == this.screen_.cursorPosition.column) {
if (false === this.enableInputMethod)
this.cursorNode_.style.display = 'none';
} else if (this.cursorNode_.style.display == 'none') {
this.cursorNode_.style.display = '';
Expand Down Expand Up @@ -12764,7 +12763,11 @@ hterm.Terminal.prototype.onMouse = function(e) { };
* React when focus changes.
*/
hterm.Terminal.prototype.onFocusChange_ = function(focused) {
this.cursorNode_.setAttribute('focus', focused);
if (true == this.enableInputMethod) {
this.cursorNode_.setAttribute('focus', !focused);
} else {
this.cursorNode_.setAttribute('focus', focused);
}
this.restyleCursor_();
if (focused === true) {
this.closeBellNotifications_();
Expand Down

0 comments on commit 53bbaa4

Please sign in to comment.