comparison src/com/five_ten_sg/connectbot/service/TerminalMonitor.java @ 100:9204fe526e65

finish setField()
author Carl Byington <carl@five-ten-sg.com>
date Tue, 17 Jun 2014 15:57:18 -0700
parents 01d939969b10
children f0ec55006f31
comparison
equal deleted inserted replaced
99:eda03b809f48 100:9204fe526e65
359 screenChanged(l, l, c, c); 359 screenChanged(l, l, c, c);
360 } 360 }
361 361
362 public synchronized void setField(int l, int c, char[] data, int offset) { 362 public synchronized void setField(int l, int c, char[] data, int offset) {
363 Log.i(TAG, "setField()"); 363 Log.i(TAG, "setField()");
364 byte[] b = new byte[data.length - offset]; 364 char[] da = new byte[data.length - offset];
365 int i; 365 int i;
366 for (i=0; i<b.length; i++) { 366 for (i=0; i<da.length; i++) {
367 b[i] = (byte)(data[i+offset] & 0x00ff); 367 da[i] = data[i+offset];
368 } 368 }
369 buffer.write(b); 369 buffer.setField(l, c, da);
370 } 370 }
371 371
372 public synchronized void getField(int l, int c, int len) { 372 public synchronized void getField(int l, int c, int len) {
373 Log.i(TAG, "getField()"); 373 Log.i(TAG, "getField()");
374 char[] arg2 = new char[4 + len]; 374 char[] arg2 = new char[4 + len];