diff options
author | Jeffrey Sharkey <jsharkey@jsharkey.org> | 2008-10-27 15:58:43 +0000 |
---|---|---|
committer | Jeffrey Sharkey <jsharkey@jsharkey.org> | 2008-10-27 15:58:43 +0000 |
commit | c394e79b95caaa2b0eb21241dacf5b7373cef887 (patch) | |
tree | 7af6489d0f0cf628038127d8a86f24be3134e643 /src/de/mud/terminal | |
parent | cb8a0cf9827bcec452fd49023a2a940bdd334f62 (diff) | |
download | connectbot-c394e79b95caaa2b0eb21241dacf5b7373cef887.tar.gz connectbot-c394e79b95caaa2b0eb21241dacf5b7373cef887.tar.bz2 connectbot-c394e79b95caaa2b0eb21241dacf5b7373cef887.zip |
* finished implementing copy functionality
* added right or left alt- or shift- helping keys (/ and tab), disableable from settings
* fixed a few random bugs
Diffstat (limited to 'src/de/mud/terminal')
-rw-r--r-- | src/de/mud/terminal/VDUBuffer.java | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/src/de/mud/terminal/VDUBuffer.java b/src/de/mud/terminal/VDUBuffer.java index 120f093..60e7abf 100644 --- a/src/de/mud/terminal/VDUBuffer.java +++ b/src/de/mud/terminal/VDUBuffer.java @@ -33,7 +33,7 @@ import android.util.Log; * all methods to manipulate the buffer that stores characters and their * attributes as well as the regions displayed. * - * @author Matthias L. Jugel, Marcus Mei§ner + * @author Matthias L. Jugel, Marcus Meiner * @version $Id: VDUBuffer.java 503 2005-10-24 07:34:13Z marcus $ */ public class VDUBuffer { @@ -343,8 +343,10 @@ public class VDUBuffer { if (scrollDown) { if (n > (bottom - top)) n = (bottom - top); - cbuf = new char[bottom - l - (n - 1)][width]; - abuf = new int[bottom - l - (n - 1)][width]; + int size = bottom - l - (n - 1); + if(size < 0) size = 0; + cbuf = new char[size][width]; + abuf = new int[size][width]; System.arraycopy(charArray, oldBase + l, cbuf, 0, bottom - l - (n - 1)); System.arraycopy(charAttributes, oldBase + l, |