mirror of
https://github.com/nuintun/command-manager.git
synced 2025-12-15 15:20:06 +08:00
update files
This commit is contained in:
@@ -7,6 +7,7 @@
|
||||
module.exports = function (Terminal){
|
||||
Terminal.prototype.cursorBlink = function (){
|
||||
if (Terminal.focus !== this) return;
|
||||
|
||||
this.cursorState ^= 1;
|
||||
this.refresh(this.y, this.y);
|
||||
};
|
||||
@@ -15,24 +16,26 @@ module.exports = function (Terminal){
|
||||
if (!this.cursorState) {
|
||||
this.cursorState = 1;
|
||||
this.refresh(this.y, this.y);
|
||||
} else {
|
||||
// Temporarily disabled:
|
||||
// this.refreshBlink();
|
||||
}
|
||||
};
|
||||
|
||||
Terminal.prototype.startBlink = function (){
|
||||
if (!Terminal.cursorBlink) return;
|
||||
|
||||
var self = this;
|
||||
|
||||
this._blinker = function (){
|
||||
self.cursorBlink();
|
||||
};
|
||||
|
||||
this._blink = setInterval(this._blinker, 500);
|
||||
};
|
||||
|
||||
Terminal.prototype.refreshBlink = function (){
|
||||
if (!Terminal.cursorBlink) return;
|
||||
|
||||
clearInterval(this._blink);
|
||||
|
||||
this._blink = setInterval(this._blinker, 500);
|
||||
};
|
||||
};
|
||||
|
||||
Reference in New Issue
Block a user