Mercurial > hg > Members > nobuyasu > tightVNCProxy
changeset 76:347c153f74c7
merge
author | Yu Taninari <e085734@ie.u-ryukyu.ac.jp> |
---|---|
date | Thu, 28 Jul 2011 17:59:39 +0900 |
parents | 6e703f1000e7 (current diff) bf5ac06df675 (diff) |
children | fe5925bb9a7e |
files | bin/myVncProxy/acceptClient.class bin/myVncProxy/acceptThread.class bin/myVncProxy/sock.class src/myVncProxy/AcceptThread.java src/myVncProxy/MyRfbProto.java src/myVncProxy/VncProxyService.java |
diffstat | 5 files changed, 22 insertions(+), 23 deletions(-) [+] |
line wrap: on
line diff
--- a/src/myVncProxy/AcceptThread.java Thu Jul 28 17:52:48 2011 +0900 +++ b/src/myVncProxy/AcceptThread.java Thu Jul 28 17:59:39 2011 +0900 @@ -1,31 +1,30 @@ package myVncProxy; -import java.net.ServerSocket; import java.net.Socket; import java.io.IOException; import java.io.InputStream; import java.io.OutputStream; public class AcceptThread implements Runnable { - MyRfbProto rfb; - byte[] imageBytes; + MyRfbProto rfb; + byte[] imageBytes; + + AcceptThread(MyRfbProto _rfb) { + rfb = _rfb; + } - AcceptThread(MyRfbProto _rfb ) { - rfb = _rfb; - } - public void run() { - rfb.selectPort(); - while (true) { - try { - Socket newCli = rfb.accept(); - - OutputStream os = newCli.getOutputStream(); - InputStream is = newCli.getInputStream(); - rfb.newClient(this, newCli, os, is); - } catch (IOException e) { - e.printStackTrace(); - System.out.println(e); - } - } - } + public void run() { + rfb.selectPort(); + while (true) { + try { + Socket newCli = rfb.accept(); + + OutputStream os = newCli.getOutputStream(); + InputStream is = newCli.getInputStream(); + rfb.newClient(this, newCli, os, is); + } catch (IOException e) { + e.printStackTrace(); + System.out.println(e); + } + } + } } -
--- a/src/myVncProxy/RfbProto.java Thu Jul 28 17:52:48 2011 +0900 +++ b/src/myVncProxy/RfbProto.java Thu Jul 28 17:59:39 2011 +0900 @@ -78,7 +78,7 @@ // Supported encodings and pseudo-encodings final static int EncodingRaw = 0, EncodingCopyRect = 1, EncodingRRE = 2, - EncodingCoRRE = 4, EncodingHextile = 5, EncodingZlib = 6, + EncodingCoRRE = 4, EncodingHextile = 5, EncodingZlib = 6, EncodingTight = 7, EncodingZRLE = 16, EncodingCompressLevel0 = 0xFFFFFF00, EncodingQualityLevel0 = 0xFFFFFFE0, EncodingXCursor = 0xFFFFFF10,