Mercurial > hg > Members > you > TreeVNC
diff src/treeVnc/MyRfbProtoClient.java @ 51:a14076dac503
add DataInputStream2.java
author | one |
---|---|
date | Sun, 06 May 2012 20:35:51 +0900 |
parents | 0809b3005687 |
children | d8f8123dcefc |
line wrap: on
line diff
--- a/src/treeVnc/MyRfbProtoClient.java Sun May 06 15:07:46 2012 +0900 +++ b/src/treeVnc/MyRfbProtoClient.java Sun May 06 20:35:51 2012 +0900 @@ -14,6 +14,9 @@ import java.io.InputStream; import java.io.InputStreamReader; import java.net.BindException; +import java.net.DatagramPacket; +import java.net.InetAddress; +import java.net.MulticastSocket; import java.net.ServerSocket; import java.net.Socket; import java.nio.ByteBuffer; @@ -91,7 +94,7 @@ } MyRfbProtoClient(String h, int p, MyVncClient v) throws IOException { - super(h, p); + super(h, p, v); this.viewer = v; cliList = new LinkedList<Socket>(); cliListTmp = new LinkedList<Socket>(); @@ -102,6 +105,17 @@ // executor = Executors.newSingleThreadExecutor(); } + MyRfbProtoClient(String h, int p, boolean b) throws IOException { + super(h, p, b); + cliList = new LinkedList<Socket>(); + cliListTmp = new LinkedList<Socket>(); + createBimgFlag = false; + proxyFlag = false; + // sendThreads = new LinkedList<Thread>(); + // executor = Executors.newCachedThreadPool(); + // executor = Executors.newSingleThreadExecutor(); + } + MyRfbProtoClient(String h, int p, CuiMyVncClient v) throws IOException { super(h, p); this.viewer = v; @@ -161,8 +175,7 @@ port = p; sock = new Socket(host, port); - is = new DataInputStream1(new BufferedInputStream(sock.getInputStream(), - 16384)); + is = new DataInputStream1(sock); os = sock.getOutputStream(); timing = false; @@ -402,8 +415,7 @@ void printNumBytesRead() { System.out.println("numBytesRead=" + numBytesRead); } - - + void regiFramebufferUpdate() throws IOException { is.mark(20);