comparison src/com/five_ten_sg/connectbot/service/TerminalBridge.java @ 47:a3fd10a8c0de tn5250

start tn5250 integration
author Carl Byington <carl@five-ten-sg.com>
date Wed, 11 Jun 2014 10:03:40 -0700
parents 80dcebe51af2
children 79aaf30947e2
comparison
equal deleted inserted replaced
46:34ce32c4e807 47:a3fd10a8c0de
98 private final String emulation; 98 private final String emulation;
99 99
100 public Bitmap bitmap = null; 100 public Bitmap bitmap = null;
101 public vt320 buffer = null; 101 public vt320 buffer = null;
102 102
103 private TerminalView parent = null; 103 public TerminalView parent = null;
104 private final Canvas canvas = new Canvas(); 104 private final Canvas canvas = new Canvas();
105 105
106 private boolean disconnected = false; 106 private boolean disconnected = false;
107 private boolean awaitingClose = false; 107 private boolean awaitingClose = false;
108 108
451 defaultPaint.getTextWidths("X", widths); 451 defaultPaint.getTextWidths("X", widths);
452 charWidth = (int)FloatMath.ceil(widths[0]); 452 charWidth = (int)FloatMath.ceil(widths[0]);
453 charHeight = (int)FloatMath.ceil(fm.descent - fm.top); 453 charHeight = (int)FloatMath.ceil(fm.descent - fm.top);
454 454
455 // refresh any bitmap with new font size 455 // refresh any bitmap with new font size
456 if (parent != null) 456 if (parent != null) parentChanged(parent);
457 parentChanged(parent);
458 457
459 for (FontSizeChangedListener ofscl : fontSizeChangedListeners) 458 for (FontSizeChangedListener ofscl : fontSizeChangedListeners)
460 ofscl.onFontSizeChanged(size); 459 ofscl.onFontSizeChanged(size);
461 460
462 host.setFontSize((int) fontSize); 461 host.setFontSize((int) fontSize);
1386 if (keyListener.isSymKey(keyCode) || 1385 if (keyListener.isSymKey(keyCode) ||
1387 keyCode == KeyEvent.KEYCODE_BACK) { 1386 keyCode == KeyEvent.KEYCODE_BACK) {
1388 dismiss(); 1387 dismiss();
1389 return true; 1388 return true;
1390 } 1389 }
1391 1390 }
1392 // return keyListener.onKey(parent, event.getKeyCode(), event);
1393 }
1394
1395 return super.dispatchKeyEvent(event); 1391 return super.dispatchKeyEvent(event);
1396 } 1392 }
1397 }; 1393 };
1398 cpd.show(); 1394 cpd.show();
1399 return true; 1395 return true;