diff options
author | Devine Lu Linvega <[email protected]> | 2019-04-15 14:23:06 +0900 |
---|---|---|
committer | Devine Lu Linvega <[email protected]> | 2019-04-15 14:23:06 +0900 |
commit | 0e3cff87dcc7e346490666cb395229020b1a1684 (patch) | |
tree | 3e4388813524d1da9455b2d9475b3ee5097843db | |
parent | d1b1ec92f02e3c02850b8015ec5b13407ab84aa2 (diff) | |
download | Orca-0e3cff87dcc7e346490666cb395229020b1a1684.tar.gz Orca-0e3cff87dcc7e346490666cb395229020b1a1684.zip |
Disable insert mode on drag
-rw-r--r-- | desktop/sources/scripts/cursor.js | 1 | ||||
-rw-r--r-- | desktop/sources/scripts/terminal.js | 6 |
2 files changed, 4 insertions, 3 deletions
diff --git a/desktop/sources/scripts/cursor.js b/desktop/sources/scripts/cursor.js index 95a886b..004df49 100644 --- a/desktop/sources/scripts/cursor.js +++ b/desktop/sources/scripts/cursor.js @@ -29,6 +29,7 @@ function Cursor (terminal) { } this.drag = function (x, y) { + this.mode = 0 this.cut() this.move(x, y) this.paste() diff --git a/desktop/sources/scripts/terminal.js b/desktop/sources/scripts/terminal.js index 74268e5..76493fd 100644 --- a/desktop/sources/scripts/terminal.js +++ b/desktop/sources/scripts/terminal.js @@ -166,7 +166,7 @@ function Terminal () { this.drawInterface = function () { const col = this.grid.w // Cursor - this.write(`${this.cursor.x},${this.cursor.y}${this.cursor.mode === 2 ? '^' : this.cursor.mode === 1 ? '+' : ''}`, col * 0, 1, this.grid.w) + this.write(`${this.cursor.x},${this.cursor.y}${this.cursor.mode === 1 ? '+' : ''}`, col * 0, 1, this.grid.w, this.cursor.mode === 1 ? 1 : 2) this.write(`${this.cursor.w}:${this.cursor.h}`, col * 1, 1, this.grid.w) this.write(`${this.cursor.inspect()}`, col * 2, 1, this.grid.w) this.write(`${this.orca.f}f${this.isPaused ? '*' : ''}`, col * 3, 1, this.grid.w) @@ -176,7 +176,7 @@ function Terminal () { this.write(`${this.orca.w}x${this.orca.h}`, col * 0, 0, this.grid.w) this.write(`${this.grid.w}/${this.grid.h}`, col * 1, 0, this.grid.w) this.write(`${this.source}`, col * 2, 0, this.grid.w) - this.write(`${this.clock}`, col * 3, 0, this.grid.w, this.io.midi.inputIndex > -1 ? 6 : 2) + this.write(`${this.clock}`, col * 3, 0, this.grid.w, this.io.midi.inputIndex > -1 ? 1 : 2) this.write(`${this.io.inspect(this.grid.w)}`, col * 4, 0, this.grid.w) if (this.orca.f < 25) { @@ -184,7 +184,7 @@ function Terminal () { } if (this.commander.isActive === true) { - this.write(`${this.commander.query}${this.orca.f % 2 === 0 ? '_' : ''}`, col * 5, 1, this.grid.w * 2, 6) + this.write(`${this.commander.query}${this.orca.f % 2 === 0 ? '_' : ''}`, col * 5, 1, this.grid.w * 2, 1) } } |